Skip to content
All articles

What is an image sitemap, and how does it help image SEO?

guide // , 6 min read, by Darthwares

An image sitemap is a file that tells search engines about the images on your website, particularly those they might not easily find otherwise. By providing this structured information, you help search engines discover and understand your images, which can improve their visibility in image search results. Google states that this process is based on generic sitemaps, ensuring that general sitemap best practices also apply to image sitemaps.

A diagram showing a website with multiple pages, each containing images. Arrows point from the website to a sitemap file, and then from the sitemap file to a search engine crawler
On this page // 7 sections
  1. 01What is an image sitemap?
  2. 02How does an image sitemap help image SEO?
  3. 03How do you create an image sitemap?
  4. 04How do you submit an image sitemap?
  5. 05What other image optimization practices are important?
  6. 06What are the size limits for image sitemaps?
  7. 07Common questions

The short version

  • Google states that image sitemaps help Google find images that might be hidden, such as those loaded by JavaScript.
  • For Google, you can create a dedicated image sitemap or add image tags to an existing sitemap.
  • Image sitemaps follow the XML Sitemap protocol, with specific tags for image details.
  • Properly submitting your image sitemap to search engines is crucial for discovery.
  • Beyond sitemaps, using descriptive alt text and contextual page content helps search engines understand images.

What is an image sitemap?

An image sitemap is a specialized file that informs search engines like Google about the images present on your website. Google states that image sitemaps are a way of telling Google about images on your site, especially those that Google might not otherwise find, such as images your site reaches with JavaScript code. Google documents that you can either create a separate image sitemap or integrate image sitemap tags directly into your existing sitemap, as both methods are equally effective for Google.

Google states that image sitemaps are built upon the generic sitemap protocol, meaning that general sitemap best practices also apply to them. The Sitemap protocol itself describes an XML schema, and its format consists of XML tags. Google supports the sitemap formats defined by this protocol, noting that XML sitemaps are the most versatile format. Google also states that XML sitemaps are extensible and can provide additional data not only about images, but also about video, news content, and localized page versions. Google describes a sitemap as a file that contains all the URLs on your site that you care about.

How does an image sitemap help image SEO?

An image sitemap primarily helps image SEO by improving the discoverability of your images by Google. Google states that image sitemaps are a way to tell Google about images they might not otherwise find, especially those that rely on JavaScript for their display. This ensures that a broader range of your site's visual content is considered for indexing.

Google notes that many people search visually, and images can serve as an initial point of contact for users discovering your website. Google advises that by making your images discoverable through a sitemap, you help both people and search engines find and understand them. This increased visibility in image search results can lead to more traffic to your site.

How do you create an image sitemap?

To create an image sitemap, Google states you can either build a standalone file or embed image sitemap tags within your existing sitemap. Google also states that each `<url>` tag within your sitemap can contain up to 1,000 `<image:image>` tags, allowing you to list many images associated with a single page. All data values within a sitemap must be entity-escaped. The Sitemap protocol specifies that all URLs in a sitemap must be from a single host, such as www.example.com. However, Google notes that it is acceptable for an image URL referenced within the sitemap to be on a different domain than your main site, provided you verify both domains in Search Console.

Additionally, you must ensure that your `robots.txt` file doesn't disallow the crawling of any content you want indexed. Each sitemap file you provide must not exceed 50,000 URLs and must be no larger than 50MB when uncompressed. If your sitemap is larger or contains more URLs, you must divide it into multiple sitemap files. You may compress your sitemap files using gzip to reduce bandwidth, but the uncompressed file size limit of 50MB still applies.

How do you submit an image sitemap?

Once you have created your image sitemap file and placed it on your web server, you need to inform the search engines that support this protocol of its location. For Google, you submit a sitemap in Search Console using the Sitemaps report. If you encounter any issues with your sitemap, you can investigate the errors with Google Search Console.

What other image optimization practices are important?

Beyond sitemaps, other practices are crucial to help search engines understand your images. Google advises that it is important to ensure that both people and search engines can find and understand your images. The text surrounding images on your page can help Google better understand what the image is about and its meaning within the page's context.

Alt text, or alternative text, is a short, descriptive piece of text that explains the relationship between an image and your content. Google states that writing good alt text is important because it helps search engines understand what your image depicts and how it relates to your page. This contextual information, combined with sitemap discovery, contributes to comprehensive image optimization.

What are the size limits for image sitemaps?

Each sitemap file, including those for images, has specific size and URL limits. According to the Sitemap protocol, each file must contain no more than 50,000 URLs and must not exceed 50MB (52,428,800 bytes) in size. Google also confirms these limits for all sitemap formats, stating a maximum of 50MB uncompressed or 50,000 URLs per single sitemap.

If your website has more URLs or a larger file size than these limits allow, you must divide your sitemap into multiple sitemap files. You can compress your sitemap files using gzip to reduce bandwidth requirements, but the uncompressed file size must still adhere to the 50MB maximum.

Common questions

Can an image sitemap include images from different domains?

While the Sitemap protocol specifies that the sitemap file itself must originate from a single host, Google notes that it is acceptable for an image URL referenced within a sitemap to be on a different domain than your main site, as long as you verify both domains in Google Search Console.

What is the maximum number of images I can list per page in an image sitemap?

Google documents that each `<url>` tag within your sitemap can contain up to 1,000 `<image:image>` tags. This allows you to specify a large number of images associated with a single page.

Do general sitemap best practices apply to image sitemaps?

Yes, Google states that image sitemaps are based on generic sitemaps, so the general sitemap best practices also apply to them.

How does alt text relate to image sitemaps?

While image sitemaps help search engines discover your images, alt text helps them understand what the image is about. Google states that alt text is a descriptive piece of text that explains the image's content and its relationship to your page, which is important for both search engines and users.

What should I do if my image sitemap is too large?

If your sitemap file exceeds 50MB (uncompressed) or contains more than 50,000 URLs, you must break it into multiple sitemaps. You can also compress your sitemap files using gzip to reduce bandwidth, but the uncompressed size must still be within the 50MB limit.

Primary sources and further reading

This article was researched and written by an AI model and published automatically. It was written from sentences that were checked to appear on the pages below, but a person has not reviewed the text. If something is wrong, tell us at chibivikramathithan@darthwares.com and we will correct it.