Article version: Enterprise Server 2.14

This version of GitHub Enterprise will be discontinued on This version of GitHub Enterprise was discontinued on 2019-07-12. No patch releases will be made, even for critical security issues. For better performance, improved security, and new features, upgrade to the latest version of GitHub Enterprise. For help with the upgrade, contact GitHub Enterprise support.

Sitemaps for GitHub Pages

GitHub Pages is available in public repositories with GitHub Free, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server.

GitHub Pages can automatically create sitemaps for your projects.

GitHub Pages will not override a sitemap.xml file that exists in the root of your repository.

Setting up

To enable automatic sitemap generation, you must add the following line to your site's _config.yml file:

plugins:
  - jekyll-sitemap

If you don't have a _config.yml file, you will need to create one in the root of your GitHub Pages repository. For more information, see Jekyll's official plugins documentation.

Testing locally

To preview the output of your sitemap locally:

You should see a new sitemap.xml file generated in your Jekyll _site folder.

For more information, see The Jekyll Sitemap Gem.

Ask a human

Can't find what you're looking for?

Contact us