One SEO professional asked John Mueller in a recent hangout about sitemaps.
They have a huge page with millions of URLs – right now they are currently renovating the sitemaps on the site. Their IT team is thinking about storing the new sitemap files in their cloud service.
This means for example: example.com/sitemaps will be moved to cloud.com/sitemaps.
And they were wondering: is this a problem if they store the sitemaps in the cloud?
Should they also create a permanent redirect for the old URL for this example.com/sitemap, or how should they plan the move?
John explained that absolutely, it’s possible to host a sitemap file somewhere else. There are two ways that you can do this.
The first one is if you have both of those domains verified in Search Console, then this works.
The other way is if you submit it with the robots.txt file, where you specify sitemap: then the URL of the sitemap, that can also go to a different domain.
If you have a separate server where you’re creating sitemap files, or if you have some type of a staging setup, where it crawls and checks the files and then creates a sitemap file somewhere else, this would work.
John says redirecting the old sitemap file to the new location, just to be clean, also works.
But, even if you just delete the old sitemap URL, you want to make sure that you submit the new one properly in Google Search Console.
This happens at approximately the 46:15 mark in the video.
John Mueller Hangout Transcript
SEO Professional 6 46:15
Yes, that’s correct. Hi, John. Hi, everybody. I have a question about the sitemaps. We have a really huge page with millions of URLs. And right now we are currently- the sitemaps are being currently renovated.
And our IT team is considering storing the new files, as in the new sitemap files, in our cloud service. That means, from example.com/sitemaps to cloud.com/sitemaps. And we are wondering, is that a problem?
If we store the sitemaps in the cloud? And if that’s not a problem, shall we also create a permanent redirect for the old URL for this example.com/sitemap, or how should we plan the move?
John 47:12
Yeah, so it’s definitely possible to host a sitemap file somewhere else. There are two ways that you can do that. One is if you have both of those domains verified in Search Console, then that works. The other way is if you submit it with the robots.txt file, where you specify sitemap colon and then the URL of the sitemap.
That can also go to a different domain. So that’s something where if you have a separate server where you’re creating sitemap files, or if you have kind of like a staging setup, where it crawls and checks the files and then creates a sitemap file somewhere else, that would all work.
I would also redirect the old sitemap file to the new location just to be clean. But probably even if you just delete the old sitemap URL, and make sure to submit the new one properly, then that should just work.
John 48:09
What might be a little bit tricky is I don’t know how Search Console would show that directly in the UI. In particular, if the sitemap file is in a different location, if Search Console would show the sitemap information in the indexing report, for example.
But that’s a reporting problem. That’s not something that kind of relies on the functionality of the sitemap file. It’s really just Search Console doesn’t show it properly. I–nd again, maybe it does. I’m just not 100% sure.
SEO Professional 6 48:50
Okay, but we can survive with this problem. But with the main problems that mean, it’s not a problem if we have the sitemap–also as on not in the right–in the main domain.
John 49:03
Yeah, it’s perfectly fine. In the beginning, when sitemaps first came out, there were some services that would crawl your website and create a sitemap file for you. And they did exactly that. And that’s a perfectly valid setup.
SEO Professional 6 49:17
Okay, great. Thank you.