PHPackages                             svc/sitemap-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. svc/sitemap-bundle

ActiveSymfony-bundle[Utility &amp; Helpers](/categories/utility)

svc/sitemap-bundle
==================

Bundle to create easy XML sitemaps and robots.txt files

1.4.0(3mo ago)1204↓100%MITPHPPHP ^8CI passing

Since Nov 29Pushed 3mo ago1 watchersCompare

[ Source](https://github.com/Sven-Ve/svc-sitemap-bundle)[ Packagist](https://packagist.org/packages/svc/sitemap-bundle)[ RSS](/packages/svc-sitemap-bundle/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)Dependencies (5)Versions (14)Used By (0)

SvcSitemapBundle
================

[](#svcsitemapbundle)

[![CI](https://github.com/Sven-Ve/svc-sitemap-bundle/actions/workflows/php.yml/badge.svg)](https://github.com/Sven-Ve/svc-sitemap-bundle/actions/workflows/php.yml)[![Latest Stable Version](https://camo.githubusercontent.com/f6078dab9ca3c93aaf6df1936170865b16f9fe60e6e646af83acb0dc76a9ad87/68747470733a2f2f706f7365722e707567782e6f72672f7376632f736974656d61702d62756e646c652f76)](https://packagist.org/packages/svc/sitemap-bundle)[![License](https://camo.githubusercontent.com/57de6d3fa8961ef8c066572e9307b68e90bf23e3935d6e53a745e9fad9d13aa7/68747470733a2f2f706f7365722e707567782e6f72672f7376632f736974656d61702d62756e646c652f6c6963656e7365)](https://packagist.org/packages/svc/sitemap-bundle)[![Total Downloads](https://camo.githubusercontent.com/6bcc768684e18e14814846879c3b72c1316d82ced8731d395b9c5b5fffd743cd/68747470733a2f2f706f7365722e707567782e6f72672f7376632f736974656d61702d62756e646c652f646f776e6c6f616473)](https://packagist.org/packages/svc/sitemap-bundle)[![PHP Version Require](https://camo.githubusercontent.com/9f43c852bc437f21bf6eb8a0cdedc32dfc5ebbd5295211db14c659222bef114a/687474703a2f2f706f7365722e707567782e6f72672f7376632f736974656d61702d62756e646c652f726571756972652f706870)](https://packagist.org/packages/svc/sitemap-bundle)[![Symfony](https://camo.githubusercontent.com/a8f2eb9e85bc0c14bdc9de931a01c5a4baff448bfc35f9b5f0651d68a2ffcf35/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f73796d666f6e792d362b253230253743253230372b253230253743253230382b2d677265656e)](https://symfony.com/)[![Last commit](https://camo.githubusercontent.com/6f4a1e01681054f5c3e0f780d47a779fde52142d8bbc30083c78e5ce56f62040/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6173742d636f6d6d69742f5376656e2d56652f7376632d736974656d61702d62756e646c65)](https://camo.githubusercontent.com/6f4a1e01681054f5c3e0f780d47a779fde52142d8bbc30083c78e5ce56f62040/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6173742d636f6d6d69742f5376656e2d56652f7376632d736974656d61702d62756e646c65)

### This bundle creates easy XML sitemaps and robots.txt files in a Symfony application

[](#this-bundle-creates-easy-xml-sitemaps-and-robotstxt-files-in-a-symfony-application)

Features
--------

[](#features)

- ✅ **XML Sitemap Generation** with full support for lastmod, changefreq, and priority
- ✅ **PHP Attributes Support** - Modern `#[Sitemap]` and `#[Robots]` attributes for type-safe configuration (PHP 8+)
- ✅ **Multi-language Support** with hreflang alternate URLs
- ✅ **robots.txt Generation** with optional sitemap reference
- ✅ **Static &amp; Dynamic Routes** via event system
- ✅ **Security Validation** - Prevents XSS (javascript:, data: schemes blocked)
- ✅ **UTF-8 Validation** - Ensures all content is valid UTF-8
- ✅ **Size Limits** - Automatic validation (50,000 URLs / 50MB per sitemap)
- ✅ **Console Commands** for easy generation
- ✅ **GZIP Support** for compressed sitemaps

### Short examples

[](#short-examples)

#### sitemap.xml

[](#sitemapxml)

```

    https://shorter.li/svc-contactform/de/contact/
    2024-12-09T15:07:58+01:00
    weekly
    0.2

    https://shorter.li/de/
    2024-12-09T15:07:58+01:00
    weekly
    1.0

    https://shorter.li/login/de
    2024-12-09T15:07:58+01:00
    weekly
    0.1

```

#### robots.txt

[](#robotstxt)

```
User-agent: google
Allow: /
Allow: /de/
Allow: /en/
Allow: /public
Disallow: /admin

User-agent: bing
Allow: /
Disallow: /de/
Disallow: /en/
Disallow: /admin

User-agent: *
Disallow: /

Sitemap: https://example.com/sitemap.xml

```

Documentation
-------------

[](#documentation)

### Sitemap

[](#sitemap)

- [Installation](docs/01-installation.md)
- [Configuration](docs/02-config.md)
- [Static sitemap routes](docs/03-static_routes.md)
- [Dynamic sitemap routes](docs/04-dynamic_routes.md)
- [Dumping sitemap.xml](docs/05-dump_sitemap.md)

### Robots.txt

[](#robotstxt-1)

- [Static robots.txt configuration](docs/06-robots_static.md)
- [Dynamic robots.txt rules](docs/07-robots_dynamic.md)
- [Generating robots.txt](docs/08-dump_robots.md)

Note

Many thanks to the creators of the [PrestaSitemapBundle](https://github.com/prestaconcept/PrestaSitemapBundle). From there I got many ideas and sometimes also some code...

###  Health Score

40

—

FairBetter than 88% of packages

Maintenance81

Actively maintained with recent releases

Popularity15

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~35 days

Recently: every ~27 days

Total

13

Last Release

100d ago

Major Versions

0.4.1 → 1.0.02025-10-12

PHP version history (2 changes)0.0.1PHP ^8.2

0.1.0PHP ^8

### Community

Maintainers

![](https://www.gravatar.com/avatar/32cf6fdc8247699d8d6a80d5c9c11215031520c0aa2ae7ba52e81536db860a84?d=identicon)[iSven](/maintainers/iSven)

---

Top Contributors

[![Sven-Ve](https://avatars.githubusercontent.com/u/79282618?v=4)](https://github.com/Sven-Ve "Sven-Ve (31 commits)")

---

Tags

phpsitemapsymfonysymfony-bundle

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/svc-sitemap-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/svc-sitemap-bundle/health.svg)](https://phpackages.com/packages/svc-sitemap-bundle)
```

###  Alternatives

[shivas/versioning-bundle

Symfony application versioning, simple console command to manage version (with providers e.g. git tag) of your application using Semantic Versioning 2.0.0 recommendations

1121.2M1](/packages/shivas-versioning-bundle)[netgen/layouts-core

Netgen Layouts enables you to build and manage complex web pages in a simpler way and with less coding. This is the core of Netgen Layouts, its heart and soul.

3689.4k10](/packages/netgen-layouts-core)[symfony/ai-bundle

Integration bundle for Symfony AI components

30282.3k6](/packages/symfony-ai-bundle)[pixelopen/cloudflare-turnstile-bundle

A simple package to help integrate Cloudflare Turnstile on Symfony.

31205.8k3](/packages/pixelopen-cloudflare-turnstile-bundle)[netgen/content-browser

Netgen Content Browser is a Symfony bundle that provides an interface which selects items from any kind of backend and returns the IDs of selected items back to the calling code.

14112.1k8](/packages/netgen-content-browser)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
