This plugin generates a sitemap.xml
from all pages in Kirby. It's possible to exclude pages from the sitemap and to assign which pages should have the highest priority (1). The priority can be disabled for all pages otherwise pages are prioritized automaticaly by depth., (*1)
composer require blankogmbh/kirby-sitemap
, (*2)
kirby plugin:install blankogmbh/kirby-sitemap
, (*3)
Check out this repository to to /site/plugins/
or include it as a submodule git submodule add https://github.com/blankogmbh/kirby-sitemap.git site/plugins/kirby-sitemap
., (*4)
You can preview your sitemap by browsing to http://your-fancy-kirby-site.net/sitemap.xml., (*5)
The plugin can be configured via Kirby’s config.php
., (*6)
c::set('sitemap.exclude', [ 'error', // just the page error 'example*', // exclude all pages starting with example 'example/*', // exclude only subpages of example (but include example) ]);
c::set('sitemap.excludeHiddenPages', true);
If you set sitemap.excludeHiddenPages
to true, but want the hidden root pages to be included, (*7)
c::set('sitemap.includeHiddenRootPages', true);
c::set('sitemap.priority', [ 'contact', // just the page contact 'important*', // all pages starting with important 'important/*', // all subpages of important (but not important) ]); c::set('sitemap.priority', false); // disable prioritization
c::set('sitemap.pingGoogle', true);
c::set('sitemap.route.pattern', 'sitemap-xml');
Markus Denhoff / Blanko denhoff@blanko.de, (*8)
Inspired by Thomas Ghysels sitemap plugin., (*9)