I'm stuck in a situation where I'm being forced to park www.parking.com at www.lot.com. As much as I wish I could do a 301 redirect, it's just not possible.

How do I make sure that lot.com isn't negatively impacted SEO wise?

My initial thought was to run $_SERVER (it's a php site) at the top of each page, and echo "index" if that returns lot.com or "noindex" if it returns parking.com.

Is this enough to keep me safe? Would this even work? A friend of mine told me that $_SERVER will return lot.com no matter which domain I go to. Is that true?

Thanks so much for the help.

Dani AI

Generated

Short answer: a robots "noindex" on the parked pages will keep those pages out of Google’s search results once Google crawls and sees the directive, so it protects lot.com from those duplicates showing up. (developers.google.com) However, a noindex is a removal instruction — it prevents the page from being indexed and generally prevents that page from forwarding ranking signals. If you want to preserve link equity, a server-side 301 is the strongest option; if a 301 truly isn’t possible, rel="canonical" from the parked page to the lot.com URL is the recommended fallback. (developers.google.com)

Don’t mix signals. Using a noindex on the source pages while also canonicalizing them to lot.com can confuse Google; Google has warned against combining contradictory signals and recommends ensuring canonical targets are crawlable and indexable. (developers.google.com)

Technical cautions and tools: make sure the parked pages are crawlable (don’t block them with robots.txt) because crawlers must be able to fetch the page to see the noindex or canonical directive. Use the X‑Robots‑Tag header for server-level or non‑HTML resources if needed. If you need a fast temporary hide while you implement a permanent solution, use Search Console’s Removals tool (you must own the property to do that). (developers.google.com)

Given your constraints (two separate domains and no 301), pick the outcome you want: hide the parked domain from search (noindex + ensure crawlable) if you don’t need its links, or canonicalize/redirect to lot.com if you want to consolidate rankings. was right that server-side host detection will let you output the correct header/meta for each domain — just confirm the directive is present in the HTTP response when crawlers fetch the URL, then monitor Search Console to verify how Google treats those pages. (developers.google.com)

Recommended Answers

All 3 Replies

Right, your friend is right since the $_SERVER[] would only return the current domain visitors are on. I think a 301 redirection via your CPanel or other hosting interface would be OK for this purpose.

have a nice day,

Right, your friend is right since the $_SERVER[] would only return the current domain visitors are on. I think a 301 redirection via your CPanel or other hosting interface would be OK for this purpose.

have a nice day,

Thanks, but like I said above I am unable to use a 301 redirect. For business reasons, the two domains must be kept separate.

For what it's worth, $_SERVER DOES give me what I need.

At the top of each page for the site that isn't mine I have <meta name="robots" content="noindex,follow" />

Is that enough to prevent me from duplicate content penalties?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.