PHPackages                             stefandoorn/sitemap-plugin - 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. stefandoorn/sitemap-plugin

ActiveSylius-plugin[Utility &amp; Helpers](/categories/utility)

stefandoorn/sitemap-plugin
==========================

Sitemap Plugin for Sylius

v3.0.0(9mo ago)851.0M↓10.4%52[16 issues](https://github.com/stefandoorn/sitemap-plugin/issues)[4 PRs](https://github.com/stefandoorn/sitemap-plugin/pulls)MITPHPPHP ^8.2CI failing

Since Jun 16Pushed 4mo ago3 watchersCompare

[ Source](https://github.com/stefandoorn/sitemap-plugin)[ Packagist](https://packagist.org/packages/stefandoorn/sitemap-plugin)[ RSS](/packages/stefandoorn-sitemap-plugin/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (21)Versions (90)Used By (0)

Sylius Sitemap Plugin
=====================

[](#sylius-sitemap-plugin)

[![License](https://camo.githubusercontent.com/857bc9b03cabc02cdd06adb38bee6041273a16e515095673bc7c53e39c5b46bd/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f73746566616e646f6f726e2f736974656d61702d706c7567696e2e737667)](https://packagist.org/packages/stefandoorn/sitemap-plugin)[![Version](https://camo.githubusercontent.com/e478a2fd7c3a6ca3f7fdcd71a956900c9ee8454918a2921c6c50aaf3177c23e8/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f73746566616e646f6f726e2f736974656d61702d706c7567696e2e737667)](https://packagist.org/packages/stefandoorn/sitemap-plugin)[![Build](https://github.com/stefandoorn/sitemap-plugin/actions/workflows/build.yml/badge.svg)](https://github.com/stefandoorn/sitemap-plugin/actions/workflows/build.yml)[![Coverage Status](https://camo.githubusercontent.com/0820594cb0c5ade228f3b0ff244d6c5a57c0d5200238474662b4371c932610cf/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f73746566616e646f6f726e2f736974656d61702d706c7567696e2f62616467652e7376673f6272616e63683d6d6173746572)](https://coveralls.io/github/stefandoorn/sitemap-plugin?branch=master)

[![](https://camo.githubusercontent.com/5b98e02f3693c16fd3f40037251d70ca5e1ecd2a11608dd21c9c7e3933b8942e/68747470733a2f2f73796c6975732e636f6d2f6173736574732f62616467652d617070726f7665642d62792d73796c6975732e706e67)](https://sylius.com/plugins/)

Big thanks
----------

[](#big-thanks)

Goes out to the Sylius team. The core code of this plugin is created by the Sylius team. Unfortunately it got removed from the Sylius core. Luckily the Sylius team approved the extraction to a separate bundle.

Features
--------

[](#features)

- Creates a sitemap index file to point to sub sitemap files per type of data
- Default providers: taxons, products &amp; static content (homepage &amp; contact)
- Easily add your own providers
- Product provider supports locales (hreflang) &amp; is channel aware
- Taxon provider supports locales (hreflang)

Installation
------------

[](#installation)

1. Run `composer require stefandoorn/sitemap-plugin`.
2. Add to `app/config/bundles.php`:

```
  SitemapPlugin\SitemapPlugin::class => ['all' => true],

```

3. Add to `app/config/packages/_sylius.yaml`:

```
    - { resource: "@SitemapPlugin/Resources/config/config.yaml" }

```

4. Add to `app/config/routes.yaml`:

```
sylius_sitemap:
    resource: "@SitemapPlugin/Resources/config/routing.yml"

```

5. Add to `app/config/packages/sylius_sitemap.yaml`:

    - [Default configuration](#default-configuration)
6. Forcing HTTPS on Generated URLs, see [Symfony Docu](https://symfony.com/doc/current/routing.html#forcing-https-on-generated-urls). In console commands, where there is no HTTP request, URLs use http by default. You can change this globally with these configuration parameters:

```
# config/services.yaml
parameters:
    router.request_context.scheme: 'https'

```

Usage
-----

[](#usage)

Generate your sitemap from the CLI:

```
 $ bin/console sylius:sitemap:generate
```

*Add this command to your cronjob to regularly generate a new sitemap, e.g. once a day.*

If you only want to generate the sitemap for a specific channel, use:

```
 $ bin/console sylius:sitemap:generate --channel=US_WEB
```

The plugin defines three default URI's:

- `sitemap.xml`: redirects to `sitemap_index.xml`
- `sitemap_index.xml`: renders the sitemap index file (with links to the provider xml files)

Next to this, each provider registers its own URI. Take a look in the sitemap index file for the correct URI's.

Default Configuration
---------------------

[](#default-configuration)

Get a full list of configuration: `bin/console config:dump-reference sitemap`

```
sitemap:
    providers:
        products: true
        taxons: true
        static: true
    template:             '@SitemapPlugin/show.xml.twig'
    index_template:       '@SitemapPlugin/index.xml.twig'
    exclude_taxon_root:   true
    hreflang:             true
    images:               true
    static_routes:
        - { route: sylius_shop_homepage, parameters: [], locales: [] }
        - { route: sylius_shop_contact_request, parameters: [], locales: [] }
```

The request context is also important for generating the URLs inside the sitemap:

- The hostname is defined per channel, if nothing set it defaults to `localhost`
- Other request context settings can be adjusted as mentioned in the [Symfony docs](https://symfony.com/doc/current/routing.html#generating-urls-in-commands)

Default storage
---------------

[](#default-storage)

By default, the sitemaps will be saved in `%kernel.root_dir%/var/sitemap`. You can change this setting by adjusting the parameter `sylius.sitemap.path`.

### Feature switches

[](#feature-switches)

- `providers`: Enable/disable certain providers to be included in the sitemap. Defaults are true.
- `exclude_taxon_root`: Often you don't want to include the root of your taxon tree as it has a generic name as 'products'.
- `hreflang`: Whether to generate alternative URL versions for each locale. Defaults to true. Background: .
- `images`: Whether to add images to URL output in case the provider adds them. Defaults to true. Background: .

Default providers
-----------------

[](#default-providers)

- Products
- Taxons
- Static content (homepage &amp; contact)

Add own provider
----------------

[](#add-own-provider)

- Register &amp; tag your provider service with `sylius.sitemap_provider`
- Let your provider implement `UrlProviderInterface`
- Use one of the default providers as an example to implement code

###  Health Score

63

—

FairBetter than 99% of packages

Maintenance63

Regular maintenance activity

Popularity55

Moderate usage in the ecosystem

Community26

Small or concentrated contributor base

Maturity91

Battle-tested with a long release history

 Bus Factor1

Top contributor holds 86.4% 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 ~63 days

Recently: every ~38 days

Total

48

Last Release

281d ago

Major Versions

0.5 → v1.0.02017-09-13

v1.x-dev → v2.0.0-alpha.12021-03-22

v2.4.2 → v3.0.0-alpha.12025-03-04

v2.4.3 → v3.0.0-alpha.22025-03-12

PHP version history (6 changes)0.1PHP ^5.6|^7.0

v1.0.0PHP ^7.1

v2.0.0-alpha.1PHP ^7.4

v2.0.0-alpha.6PHP ^7.4 || ^8.0

v2.4.0PHP ^7.4 || ^8.1

v3.0.0-alpha.1PHP ^8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/b7e3e1dbf1349563371dca037785c04abe3865e7b3c9e88f8493ecadad571911?d=identicon)[stefandoorn](/maintainers/stefandoorn)

---

Top Contributors

[![stefandoorn](https://avatars.githubusercontent.com/u/4903082?v=4)](https://github.com/stefandoorn "stefandoorn (387 commits)")[![mirondi](https://avatars.githubusercontent.com/u/14058199?v=4)](https://github.com/mirondi "mirondi (10 commits)")[![loevgaard](https://avatars.githubusercontent.com/u/2412177?v=4)](https://github.com/loevgaard "loevgaard (10 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (7 commits)")[![Roshyo](https://avatars.githubusercontent.com/u/9363039?v=4)](https://github.com/Roshyo "Roshyo (6 commits)")[![dependabot-preview[bot]](https://avatars.githubusercontent.com/in/2141?v=4)](https://github.com/dependabot-preview[bot] "dependabot-preview[bot] (6 commits)")[![jbcr](https://avatars.githubusercontent.com/u/51637606?v=4)](https://github.com/jbcr "jbcr (4 commits)")[![Jeroen-G](https://avatars.githubusercontent.com/u/1116853?v=4)](https://github.com/Jeroen-G "Jeroen-G (3 commits)")[![Prometee](https://avatars.githubusercontent.com/u/861820?v=4)](https://github.com/Prometee "Prometee (2 commits)")[![sweoggy](https://avatars.githubusercontent.com/u/5914253?v=4)](https://github.com/sweoggy "sweoggy (2 commits)")[![alexrowesoap](https://avatars.githubusercontent.com/u/29568210?v=4)](https://github.com/alexrowesoap "alexrowesoap (1 commits)")[![tsogoo](https://avatars.githubusercontent.com/u/880494?v=4)](https://github.com/tsogoo "tsogoo (1 commits)")[![David-Crty](https://avatars.githubusercontent.com/u/3600892?v=4)](https://github.com/David-Crty "David-Crty (1 commits)")[![kpitn](https://avatars.githubusercontent.com/u/41059?v=4)](https://github.com/kpitn "kpitn (1 commits)")[![lamasfoker](https://avatars.githubusercontent.com/u/12940668?v=4)](https://github.com/lamasfoker "lamasfoker (1 commits)")[![lruozzi9](https://avatars.githubusercontent.com/u/26346480?v=4)](https://github.com/lruozzi9 "lruozzi9 (1 commits)")[![Margauxfeslard](https://avatars.githubusercontent.com/u/48242659?v=4)](https://github.com/Margauxfeslard "Margauxfeslard (1 commits)")[![mbenoukaiss](https://avatars.githubusercontent.com/u/34457865?v=4)](https://github.com/mbenoukaiss "mbenoukaiss (1 commits)")[![mmenozzi](https://avatars.githubusercontent.com/u/1199914?v=4)](https://github.com/mmenozzi "mmenozzi (1 commits)")[![phakpoom](https://avatars.githubusercontent.com/u/12756630?v=4)](https://github.com/phakpoom "phakpoom (1 commits)")

---

Tags

ecommercephpsitemapsitemap-generatorsitemap-pluginsyliussymfonysyliussylius-plugin

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/stefandoorn-sitemap-plugin/health.svg)

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

###  Alternatives

[sylius/refund-plugin

Plugin provides basic refunds functionality for Sylius application.

691.7M14](/packages/sylius-refund-plugin)[monsieurbiz/sylius-rich-editor-plugin

A Rich Editor plugin for Sylius.

75380.8k6](/packages/monsieurbiz-sylius-rich-editor-plugin)[synolia/sylius-scheduler-command-plugin

Scheduler Command Plugin.

34361.5k](/packages/synolia-sylius-scheduler-command-plugin)[odiseoteam/sylius-blog-plugin

This plugin add blog capabilities to your Sylius project

37104.5k](/packages/odiseoteam-sylius-blog-plugin)[webgriffe/sylius-table-rate-shipping-plugin

Provides table rate shipping calculator.

1490.4k](/packages/webgriffe-sylius-table-rate-shipping-plugin)[dedi/sylius-seo-plugin

Sylius SEO plugin by Dedi.

28138.9k](/packages/dedi-sylius-seo-plugin)

PHPackages © 2026

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