I'm developing a site (WordPress) and have a staging site where I make changes and do testing. The two domains are example.com and staging.example.com. The contents of the sites are completely the same.

Is this going to be a problem for SEO, since I understand that Google punishes duplicate content?

I know I can turn off Search Engine Visibility in the staging site, but would then have to remember to turn it back on again every time I update my production site.

2 Answers 2


The better answer is to password protect the entire subdomain at the server level. That way if Google attempts to access, they see the staging site responds with HTTP/1.1 401 Authorization Required and won't access. Here is an article on how to do this in cPanel (not sure what environment you are in).


Another option would be to block the access of staging site using robots.txt file.

In this method, you can leave public access for yourself and your team and search engines will not attempt to crawl staging site (subdomain).

Matthew Edgar's solution is fine too.

  • As well, using noindex works too. Cheers!!
    – closetnoc
    May 14, 2017 at 16:27
  • In looking into this based on all recommendations I saw that instructions to not index can be ignored by Google but the password option cannot. I going to go with that one. May 14, 2017 at 23:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.