Mobile app version of vmapp.org
Login or Join
Murphy175

: How to tell google that domain no longer exists but still make redirects from that domain I have two domains: example.com and dev.example.net. example.com is the active one and dev.example.net

@Murphy175

Posted in: #301Redirect #Domains #Htaccess #Redirects #RobotsTxt

I have two domains: example.com and dev.example.net. example.com is the active one and dev.example.net should be invisible to Google.

dev.example.net has 301 redirects to example.com and it has its own robots.txt that doesn't allow Google to index pages.

Still I got dev.example.net results showing in Google. How can I convince Google that it shouldn't show any results from dev.example.net?

10.02% popularity Vote Up Vote Down


Login to follow query

More posts by @Murphy175

2 Comments

Sorted by latest first Latest Oldest Best

 

@Pierce454

First, you should check that you've properly set up 301 redirects from your old domain to corresponding pages on the new one, as you say you've done. You can use your browser's developer tools (e.g. like this on Chrome or like this on Firefox) to check that your redirects are working properly, and are really using the status code 301 and not 302.

You also need to allow Google to access all pages in the robots.txt file on your old domain. Otherwise Google cannot tell that the pages have been redirected, and will continue to show them in search results.

Once you've done both of these things, the problem should eventually resolve itself over time, as Google recrawls your old domain and finds the redirects. However, to speed up the process, you can use the change of address tool on Google's Search Console. (Of course, you'll also need to verify your ownership of both domains with Google first.) If you want, you can also do the same thing with other search engines such as Bing.



The process described above should be sufficient to get your new domain indexed and your old domain dropped from Google's index promptly, and it will preserve any "link juice" your old domain may have acquired.

If you have some pages on your old domain that you can't (or don't want to) meaningfully redirect to the new domain, e.g. because no corresponding page exists there any more, you should configure your webserver to return a 410 "Gone" status code for them. You can also use Google's URL removal tool to speed up the process, just like with redirects and the change of address tool.

Finally, this should almost go without saying, but you should also make sure that none of the pages on the new domain still link to URLs on the old domain, or (worse!) have the old domain still included in their canonical URL.

10% popularity Vote Up Vote Down


 

@Correia994

I would suggest that you follow Google webmaster guidelines for permanent URL removal.

To remove content or a URL from Google search permanently you must take one or more of the following additional actions:


Remove or update the actual content from your site (images, pages, directories) and make sure that your web server returns either a 404 (Not Found) or 410 (Gone) HTTP status code. Non-HTML files (like PDFs) should be completely removed from your server.
Block access to the content, for example by requiring a password.
Indicate that the page should not to be indexed using the noindex meta tag. This is less secure than the other methods.


You can read more about it here: support.google.com/webmasters/answer/1663419?hl=en

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme