Friendly URLs in PrestaShop: configuration and typical mistakes
Changing the URL format of a store with a history is one of the riskiest decisions in SEO. We explain how to get it right from the start.
PrestaShop lets you configure the URL format in Shop Parameters > Traffic & SEO. The default configuration is reasonable, but it pays to understand what each option implies before changing it.
Default format
- Product:
/{category:/}{id}{-:id_product_attribute}-{rewrite}{-:ean13}.html - Category:
/{id}-{rewrite} - CMS:
/content/{id}-{rewrite}
The numeric ID in the URL lets PrestaShop find the page even if the text changes. Removing it is possible with modules, but it adds complexity.
Common mistakes
- Changing the format on a store with years of traffic without redirects: every indexed URL starts returning 404.
- The category in the product URL: if the product is in several categories, it can have several URLs. PrestaShop uses the default category and sets the canonical, but check that the canonical is correct.
- Special characters: with “Accented URL” disabled, characters such as ñ and accented letters are transliterated. Enable it or not, but do not change it afterwards.
- Inconsistent capitals and trailing slashes that generate duplicates.
The .htaccess file
PrestaShop regenerates the .htaccess when you save the SEO settings. If you have your own rules (redirects, security), put them outside PrestaShop’s markers or they will be lost.