Issue Bug Closed

#90045Sitemap Errors if the language has no trailing slash at the end like /de it is linked in the sitemap like /de/

Timo Poppinga 01/02/20, 14:46 updated 11/14/26, 20:01

Description

No description.

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.

History 5

  1. Richard Haeser commented and changed status New Needs Feedback <span data-processor="relativetime" data-value="2021-01-31T10:22:50+00:00" > 01/31/21, 10:22 </span>

    What exactly is the error? How do you access the sitemap (which URL)?

  2. Timo Poppinga commented <span data-processor="relativetime" data-value="2021-02-02T17:45:12+00:00" > 02/02/21, 17:45 </span>

    @richard Haeser it is related to TYPO3 routing. TYPO3 does not support / after the language slug correctly.
    This mees if you configure TYPO3 witout trailing slash is works fine, only at the root langauges slugs the trailing slash is still added.

    If this will be fixed in TYPO3 Core “routing” all this issues are fixed

  3. Georg Ringer commented and changed status Needs Feedback Closed <span data-processor="relativetime" data-value="2026-11-14T20:01:18+00:00" > 11/14/26, 20:01 </span>

    Hi, and thanks for reporting this and for the follow-up in the comments!

    This is the same behaviour as described in #90151: with a language base without a trailing slash (base: /de), the link to the language root page (slug /) is generated as /de/, while a request to /de/ is redirected (307) back to /de. The XML sitemap uses the same link generation, so the root page is listed as /de/ as well.

    I verified this on main with typo3/seo-sitemap and two languages: with base: /fr the sitemap lists https://example.org/fr/, which redirects. With base: /fr/ the listed URL is the one that is delivered, and no redirect happens. The same applies to canonical and hreflang links (#88544).

    The recommended setup is therefore to configure the language base with a trailing slash. Changing the link generation for bases without trailing slash would alter the URLs of every existing site that uses this spelling (canonicals, sitemaps, redirects, caches), so this is working as designed.

    I am closing this as a duplicate of #90151, where the details are documented. Thanks!