Google news sitemap format
A Google News sitemap is a specific type of sitemap that helps Google News understand the structure and content of your website, making it easier for your news articles to be discovered and indexed. Here is the format for a Google News sitemap:
Required elements:
<?xml version="1.0" encoding="UTF-8"?>
: The XML declaration at the top of the file.<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:news="http://www.google.com/schemas/sitemap-news/0.9">
: The root element of the sitemap, which specifies the XML namespace for the sitemap and the news extension.<url>
: Each URL in the sitemap is wrapped in a<url>
element.<loc>
: The<loc>
element specifies the URL of the news article.<news:news>
: The<news:news>
element specifies the news article's metadata, including the publication date, title, and keywords.
Optional elements:
<news:publication>
: Specifies the publication's name and language.<news:publication_date>
: Specifies the date the article was published.<news:title>
: Specifies the title of the news article.<news:keywords>
: Specifies the keywords associated with the news article.<news:section>
: Specifies the section or category of the news article.
Example:
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:news="http://www.google.com/schemas/sitemap-news/0.9">
<url>
<loc>https://example.com/article1</loc>
<news:news>
<news:publication>Example News</news:publication>
<news:publication_date>2022-01-01T12:00:00Z</news:publication_date>
<news:title>Breaking News: New Year, New Beginnings</news:title>
<news:keywords>new year, new beginnings, breaking news</news:keywords>
</news:news>
</url>
<url>
<loc>https://example.com/article2</loc>
<news:news>
<news:publication>Example News</news:publication>
<news:publication_date>2022-01-02T12:00:00Z</news:publication_date>
<news:title>Local Sports: Team Wins Championship</news:title>
<news:keywords>local sports, team wins, championship</news:keywords>
</news:news>
</url>
</urlset>
Tips:
- Use the
news:news
element to specify the news article's metadata. - Use the
news:publication
element to specify the publication's name and language. - Use the
news:publication_date
element to specify the date the article was published. - Use the
news:title
element to specify the title of the news article. - Use the
news:keywords
element to specify the keywords associated with the news article. - Make sure to include the
<?xml version="1.0" encoding="UTF-8"?>
declaration at the top of the file. - Save the file with a
.xml
extension, such assitemap_news.xml
. - Submit the sitemap to Google News using the Google Search Console or by uploading it to your website's root directory.