Video and Image Sitemaps

How video and image sitemaps work, when to use them, required and optional tags, complete XML examples, and how they help with Google rich results.

Standard sitemaps list URLs. Video and image sitemaps go further -- they describe the media content on those pages so search engines can surface your videos in video search results and your images in image search. If your site relies on visual content, media sitemaps are how you tell Google exactly what you have and where to find it.

Why Media Sitemaps Exist

Google's regular crawler can follow links and parse HTML, but it has limitations when it comes to media:

  • Videos embedded via JavaScript (React players, lazy-loaded iframes) may not be discovered during a standard crawl
  • Image galleries loaded dynamically or behind click events can be missed entirely
  • Metadata like video duration, thumbnail URL, or image caption isn't always in the page HTML in a format Google can parse
  • Media hosted on CDNs or third-party platforms may not be obviously connected to your domain

A media sitemap explicitly tells search engines: "This page has this video/image, here's its metadata, and here's where to find the actual file." It removes the guesswork from media discovery.

Image Sitemaps

How They Work

Image sitemap entries are extensions added to your regular sitemap. You don't create a separate sitemap file -- you add image:image elements inside your existing <url> entries.

Required Namespace

Add the image namespace to your <urlset> declaration:

<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
        xmlns:image="http://www.google.com/schemas/sitemap-image/1.1">

Image Sitemap Tags

TagRequiredDescription
image:imageYesContainer element for each image
image:locYesURL of the image file
image:captionNoCaption / description of the image
image:geo_locationNoGeographic location (e.g., 'New York, NY')
image:titleNoTitle of the image
image:licenseNoURL to the image's license

Complete Image Sitemap Example

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
        xmlns:image="http://www.google.com/schemas/sitemap-image/1.1">
  <url>
    <loc>https://example.com/products/leather-bag</loc>
    <image:image>
      <image:loc>https://cdn.example.com/images/leather-bag-front.jpg</image:loc>
      <image:caption>Brown leather messenger bag, front view</image:caption>
      <image:title>Leather Messenger Bag - Front</image:title>
    </image:image>
    <image:image>
      <image:loc>https://cdn.example.com/images/leather-bag-side.jpg</image:loc>
      <image:caption>Brown leather messenger bag, side view with strap detail</image:caption>
      <image:title>Leather Messenger Bag - Side</image:title>
    </image:image>
  </url>
  <url>
    <loc>https://example.com/gallery/sunset-collection</loc>
    <image:image>
      <image:loc>https://cdn.example.com/photos/sunset-malibu.jpg</image:loc>
      <image:caption>Sunset over Malibu Beach, California</image:caption>
      <image:geo_location>Malibu, CA</image:geo_location>
      <image:license>https://example.com/license</image:license>
    </image:image>
  </url>
</urlset>

You can include up to 1,000 images per <url> entry. Each image is a separate image:image block.

Image URLs can be on a different domain

Unlike regular sitemap URLs, image URLs don't have to be on the same domain as the page. You can reference images on your CDN (cdn.example.com) from pages on your main domain (example.com). This is common and fully supported.

Video Sitemaps

How They Work

Like image sitemaps, video entries are extensions to your regular sitemap. You add video:video elements inside <url> entries to describe video content on each page.

Required Namespace

<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
        xmlns:video="http://www.google.com/schemas/sitemap-video/1.1">

Video Sitemap Tags

TagRequiredDescription
video:videoYesContainer element for each video
video:thumbnail_locYesURL to a thumbnail image for the video
video:titleYesTitle of the video
video:descriptionYesDescription of the video (max 2048 characters)
video:content_locRecommendedDirect URL to the video file (.mp4, .flv, etc.)
video:player_locRecommendedURL to the embeddable player (if no content_loc)
video:durationRecommendedDuration in seconds
video:expiration_dateNoWhen the video is no longer available
video:ratingNoRating between 0.0 and 5.0
video:view_countNoNumber of views
video:publication_dateNoDate the video was first published
video:family_friendlyNo'yes' or 'no'
video:restrictionNoCountry-based access restrictions
video:platformNoPlatform restrictions (web, mobile, tv)
video:liveNo'yes' if the video is a live stream

You must provide either video:content_loc or video:player_loc (or both). Google needs at least one way to access the video.

Complete Video Sitemap Example

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
        xmlns:video="http://www.google.com/schemas/sitemap-video/1.1">
  <url>
    <loc>https://example.com/tutorials/getting-started</loc>
    <video:video>
      <video:thumbnail_loc>https://cdn.example.com/thumbs/getting-started.jpg</video:thumbnail_loc>
      <video:title>Getting Started with Our Platform</video:title>
      <video:description>A 5-minute walkthrough of how to set up your account, configure your first project, and run your initial analysis.</video:description>
      <video:content_loc>https://cdn.example.com/videos/getting-started.mp4</video:content_loc>
      <video:player_loc>https://www.youtube.com/embed/abc123</video:player_loc>
      <video:duration>312</video:duration>
      <video:publication_date>2026-01-15T08:00:00+00:00</video:publication_date>
      <video:family_friendly>yes</video:family_friendly>
    </video:video>
  </url>
  <url>
    <loc>https://example.com/tutorials/advanced-features</loc>
    <video:video>
      <video:thumbnail_loc>https://cdn.example.com/thumbs/advanced.jpg</video:thumbnail_loc>
      <video:title>Advanced Features Deep Dive</video:title>
      <video:description>Learn how to use custom filters, export reports, and set up automated workflows.</video:description>
      <video:content_loc>https://cdn.example.com/videos/advanced.mp4</video:content_loc>
      <video:duration>847</video:duration>
      <video:view_count>15420</video:view_count>
      <video:publication_date>2026-02-01T10:00:00+00:00</video:publication_date>
      <video:family_friendly>yes</video:family_friendly>
    </video:video>
  </url>
</urlset>

Validate your media sitemap

Check your video and image sitemap for missing required tags, broken URLs, and structural errors.

Combining Image and Video in One Sitemap

You can include both image and video extensions in the same sitemap file. Just declare both namespaces:

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
        xmlns:image="http://www.google.com/schemas/sitemap-image/1.1"
        xmlns:video="http://www.google.com/schemas/sitemap-video/1.1">
  <url>
    <loc>https://example.com/recipes/chocolate-cake</loc>
    <image:image>
      <image:loc>https://cdn.example.com/recipes/chocolate-cake.jpg</image:loc>
      <image:caption>Finished chocolate cake with ganache topping</image:caption>
    </image:image>
    <video:video>
      <video:thumbnail_loc>https://cdn.example.com/thumbs/chocolate-cake.jpg</video:thumbnail_loc>
      <video:title>How to Make Chocolate Cake</video:title>
      <video:description>Step-by-step video recipe for rich chocolate cake with ganache.</video:description>
      <video:content_loc>https://cdn.example.com/videos/chocolate-cake.mp4</video:content_loc>
      <video:duration>480</video:duration>
    </video:video>
  </url>
</urlset>

When to Use Media Sitemaps

Media sitemaps aren't necessary for every site. Here's when they provide real value:

E-commerce with product images

If you have hundreds or thousands of product images, an image sitemap helps Google index them for image search. This drives traffic from Google Images, which accounts for a significant share of search traffic.

Video tutorial or course sites

Sites with original video content benefit the most from video sitemaps. Google can display your videos in video search results and as rich snippets in regular search results -- both of which increase click-through rates.

Photography and portfolio sites

Photographers, designers, and artists whose primary content is visual should use image sitemaps. Discoverability in Google Images is essential for these sites.

Recipe and how-to sites

Sites with recipe videos or instructional content benefit from video sitemaps combined with structured data. The video rich results in search are eye-catching and drive engagement.

News and media publishers

News sites with video reports or photo galleries should use media sitemaps to ensure timely indexing of visual content alongside articles.

When You Probably Don't Need Them

  • Blog with occasional stock photos -- If images are decorative rather than the core content, an image sitemap won't add much value.
  • Embedded YouTube videos you don't own -- If you're just embedding other people's YouTube videos, a video sitemap won't help. Google already indexes YouTube content directly.
  • Small sites with few images -- If Google can find your images through normal crawling, an image sitemap is redundant.

Structured Data as an Alternative (or Complement)

Google also discovers media content through structured data (Schema.org markup) on the page itself. For videos, VideoObject schema serves a similar purpose to a video sitemap:

<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "VideoObject",
  "name": "Getting Started Tutorial",
  "description": "A 5-minute walkthrough of the platform.",
  "thumbnailUrl": "https://cdn.example.com/thumbs/getting-started.jpg",
  "uploadDate": "2026-01-15",
  "duration": "PT5M12S",
  "contentUrl": "https://cdn.example.com/videos/getting-started.mp4"
}
</script>

Which should you use? Both, if possible. Google's documentation recommends using structured data on the page and a video sitemap together. The sitemap helps with discovery, and the structured data provides rich result eligibility. They complement each other rather than being alternatives.

For images, there's no equivalent structured data approach -- the image sitemap is the primary method for surfacing images to Google beyond what's discoverable through standard crawling.

Benefits for Rich Results

The main SEO payoff of media sitemaps is eligibility for rich results:

  • Video thumbnails in search results -- Pages with properly described videos can show a video thumbnail alongside the regular search snippet, dramatically increasing click-through rates.
  • Video carousel -- Google sometimes shows a carousel of videos for relevant queries. Video sitemaps help your content appear here.
  • Google Images traffic -- Image sitemaps ensure your images appear in Google Images for relevant queries, which can be a significant traffic source for visual content.
  • Video tab in search -- Google's video search tab surfaces content described in video sitemaps.

Rich results aren't guaranteed

Having a media sitemap makes your content eligible for rich results, but Google decides whether to show them based on content quality, relevance, and other ranking factors. A sitemap gets you in the door; your content quality determines whether you stay.

Key Takeaways

Media sitemaps are an extension of the standard sitemap protocol, not a replacement. Use them when your site's value proposition is visual -- product images, original videos, photography, recipes with video instructions. They're straightforward to implement (just add namespace and tags to your existing sitemap), and the potential upside in search visibility makes them worth the effort for media-heavy sites.


Standard sitemaps list pages. Media sitemaps describe what's on them. If your content is visual, help Google see what you see.

Validate your XML sitemap

Check your sitemap for errors, broken URLs, and indexing issues. Free instant validation.