Skip to content

docs(en/sitemap.mdx): describe customSitemaps #11563

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions src/content/docs/en/guides/integrations-guide/sitemap.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,24 @@ export default defineConfig({
});
```

### customSitemaps

In some cases, you might have a section on your site that *isn't* created by Astro. If that section has it's own sitemap and you'd like to include it in the `sitemap-index.xml` file created by Astro, you can use this option.

```js title="astro.config.mjs" ins={8}
import { defineConfig } from 'astro/config';
import sitemap from '@astrojs/sitemap';

export default defineConfig({
site: 'https://stargazers.club',
integrations: [
sitemap({
customSitemaps: ['https://stargazers.club/blog/sitemap.xml', 'https://stargazers.club/shop/sitemap.xml'],
}),
],
});
```

### entryLimit

The maximum number entries per sitemap file. The default value is 45000. A sitemap index and multiple sitemaps are created if you have more entries. See this [explanation of splitting up a large sitemap](https://developers.google.com/search/docs/advanced/sitemaps/large-sitemaps).
Expand Down