2

I've build a sitemap_index pointing to different sitemaps "sitemap1.xml" If they are uncompressed, they are successfully validated and accepted (Google Webmaster).

However, when compressed, they are not accepted.

sitemap - unsopported format

I simply compressed them using gzip:

gzip sitemap1.xml

My server nginx is enabled to send compressed files.

This time I have not found useful the link in "Sitemap guidelines": Which could be a possible error and how to check for it?

1

I simply compressed them using gzip: gzip sitemap1.xml

My server nginx is enabled to send compressed files.

It looks like you're trying to send a double-compressed file and a compressed file.

When you gzip a file and host it on a server that is set up to compress and send files, then you basically compressed the same file twice and when one level of decoding is done, what google sees instead of the xml contents is a bunch of garbage which really is the compressed file that you made using the gzip utility.

I would suggest disabling the compression mechanism in nginx for gz files, and compress the xml files as gz files then when google requests them, they're compressed properly. On my site, I have the sitemap index file as just a plain old XML file and then the sitemap files within it are compressed manually and without the server running the compression module.

0

If you try to download your own sitemap files, e.g. example.xml.gz, most web browsers will correctly prompt you to download the compressed sitemap file.

However, if your webserver is not sending correct MIME headers for .gz files, some browsers may instead try open the sitemap file. This will fail as the internet browser has not correctly recognized the file format.

  • Which correct MIME type for .gz ? In case of normal xml, opened correctly, I checked MIME and see: Resource interpreted as Document but transferred with MIME type application/xml: "http://example.com/sitemap1.xml". – user305883 Apr 10 '16 at 14:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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