Back to the knowledgebase

Does Craft automatically create redirects when I change a page's slug?

Yes. When you change the slug of a published entry, Craft CMS and Retour work together to automatically create a 301 redirect from the old URL to the new one. This happens in the background without you needing to manually create a redirect yourself.

What is covered automatically
Any time a live, enabled entry's URL changes- whether because you changed the slug directly or because the entry's position in a structure changed its path- a redirect is created from the previous URL to the updated one. This protects existing links and search engine rankings automatically.

What is not covered
Automatic redirects are only created for published, enabled entries. Changes to drafts, disabled entries, or entries that have never been live do not generate automatic redirects. Redirects also will not be created if the entry had no URL before the change- for example, if a section was not configured to give entries their own URLs.

Checking automatically created redirects
Automatically created redirects appear in the Redirects list in Retour alongside any you have created manually. You can edit or delete them from there if needed.

Similar articles