Skip to content

PrestaShop SEO: friendly URLs, canonical redirects, robots.txt, schema and speed

Published 7 October 20268 min readBy the SmoothSeen editorial team

PrestaShop technical SEO comes down to four screens: SEO & URLs (friendly URLs, the canonical redirect and robots.txt), Product Settings (what happens to disabled products), the Google sitemap module and Performance (caching and CCC). This guide walks through each setting in PrestaShop 9.2, the current release, with a tested module for AI crawlers.

Key points

  • PrestaShop 9.2.0 was released on 30 September 2026 and, since 9.1, new installations use the Hummingbird theme instead of Classic.
  • The redirect to the canonical URL ships as a 302; PrestaShop's own admin recommends switching it to 301 once the store is live.
  • The «Generate robots.txt file» button overwrites the whole file, so rules you add by hand vanish at the next generation; a module on the actionAdminMetaAfterWriteRobotsFile hook keeps them.
  • The generated robots.txt blocks filters (?q=) and sort orders (?order=) but leaves pagination (?page=2) crawlable, and each page declares itself as canonical.
  • A disabled product returns a 404 by default; you can change that to a 301 to another product or category, or to a 410.

To check it on your own site: Online shops

On this page

PrestaShop is an open-source ecommerce platform written in PHP. It controls URLs, canonicals, robots.txt, the sitemap (through a module) and the theme's product markup; it does not control compression, headers or the PHP version on your server. Version 9.2.0 was published on 30 September 20261 and runs on PHP 8.1 to 8.52. Since 9.1, new installations ship with the Hummingbird theme instead of Classic3. What applies to every online shop is in the guide to ecommerce SEO for Google and AI search.

Where is each SEO setting in PrestaShop 9?

Setting
Friendly URLs and canonical
Admin path
Shop Parameters > Traffic & SEO > SEO & URLs > Set up URLs
What it decides
Readable URLs and the response to non-canonical URLs
Setting
URL format
Admin path
SEO & URLs > Schema of URLs
What it decides
Routes for products, categories and pages
Setting
robots.txt
Admin path
SEO & URLs > Robots file generation
What it decides
Regenerates the file
Setting
Disabled products
Admin path
Shop Parameters > Product Settings
What it decides
404, 410 or product shown as discontinued
Setting
Title, meta description, URL and redirect for each product
Admin path
Catalog > Products > SEO tab
What it decides
What search engines see for that page
Setting
HTTPS
Admin path
Shop Parameters > General > Enable SSL
What it decides
Store served over https
Setting
Caching and CCC
Admin path
Advanced Parameters > Performance
What it decides
Smarty, CSS and JavaScript

How do you enable friendly URLs and the canonical redirect?

In SEO & URLs, under Set up URLs4:

  1. Friendly URL: turn it on if your server supports URL rewriting (on Apache, mod_rewrite). PrestaShop warns that if the server does not support it, the store can become unavailable.
  2. Accented URL: allows non-ASCII characters in URLs. Switched off, URLs carry no accents, which makes them easier to copy and link to.
  3. Redirect to the canonical URL: decides how the store responds when someone requests a page through a URL that is not its own. There are three options: no redirection, 302 and 301.

In PrestaShop 9.2 the installation sets this last option to 302, and the admin itself recommends «301 Moved Permanently» once the store has gone live5. Change it. A 302 tells Google that the right URL might change.

Schema of URLs is where you define routes. In the 9.2 code, the product route is {id}{-:id_product_attribute}-{rewrite}.html, which produces /12-t-shirt.html or, with a combination, /12-45-t-shirt.html6. The number cannot be removed with the default routes4. A product page's canonical points to the product URL without a combination7, so combinations do not compete with each other. Change the format once the store is indexed and every URL changes: decide before launch.

What does PrestaShop do with filters and pagination?

The faceted search module adds filters to the category URL with the q parameter (for example, ?q=Size-M), and sorting uses order8. A category's canonical keeps only the page number and drops the filters9, which is what Google asks for: every page in a series crawlable and canonical to itself10, and filters out of the index11.

The robots.txt PrestaShop generates fits that. It blocks ?q=, ?order=, ?tag=, ?id_currency=, ?search_query=, ?back= and ?n= (after & too), the cart, account, search and order controllers, and internal folders such as classes/, config/ and vendor/; and it allows module CSS, JS and images12. It does not block ?page=. We checked it with a matcher that applies Google's rules: /3-clothes and /3-clothes?page=2 stay allowed; ?q=Size-M, ?order=product.price.asc and ?page=2&q=Colour-Blue are blocked.

If a filter combination has its own search demand, do not open up the filter: create a category with its own copy and URL.

How do you add rules for AI crawlers without losing them?

The Generate robots.txt file button replaces the whole file, and the documentation says your own rules must be added after PrestaShop has generated its version4. The problem is the next generation: it wipes what you added. Generation fires two hooks, actionAdminMetaBeforeWriteRobotsFile and actionAdminMetaAfterWriteRobotsFile12, so a small module can write your block every time. Save it as modules/robotsia/robotsia.php, install it and regenerate robots.txt:

<?php
if (!defined('_PS_VERSION_')) {
    exit;
}

class RobotsIa extends Module
{
    public function __construct()
    {
        $this->name = 'robotsia';
        $this->tab = 'seo';
        $this->version = '1.0.0';
        $this->author = 'Your store';
        $this->ps_versions_compliancy = ['min' => '8.0.0', 'max' => _PS_VERSION_];
        parent::__construct();
        $this->displayName = 'robots.txt: AI crawlers';
        $this->description = 'Adds a group for training crawlers every time robots.txt is generated.';
    }

    public function install()
    {
        return parent::install() && $this->registerHook('actionAdminMetaAfterWriteRobotsFile');
    }

    public function hookActionAdminMetaAfterWriteRobotsFile(array $params)
    {
        $fd = $params['write_fd'];
        fwrite($fd, "\n# Model training: blocking these does not remove you from AI answers\n");
        foreach (['GPTBot', 'ClaudeBot', 'Google-Extended', 'CCBot'] as $bot) {
            fwrite($fd, 'User-agent: ' . $bot . PHP_EOL);
        }
        fwrite($fd, 'Disallow: /' . PHP_EOL);
    }
}

How we tested it: php -l in the official php:8.3-cli image, and a run of the hook with the same write order as Tools::generateRobotsFile in 9.2: the group appears at the end, after PrestaShop's rules. It leaves the User-agent: * group alone, so OAI-SearchBot, Claude-SearchBot and PerplexityBot (the crawlers that decide whether ChatGPT, Claude or Perplexity can cite you) follow the general rules. GPTBot, ClaudeBot and CCBot collect content to train models, and Google-Extended does not affect Google Search1314. The full list is in the guide to AI crawlers and robots.txt.

How is the sitemap generated?

PrestaShop generates it with the Google sitemap module (gsitemap), which creates one sitemap per language and stays current through a cron URL shown in its configuration15. Order matters: robots.txt only includes the Sitemap: line if the sitemap index file (1_index_sitemap.xml for shop 1) already exists when you generate it12. Generate the sitemap first, then robots.txt.

The module ships with priorities per page type, but do not spend time on them: Google ignores <priority> and <changefreq>16.

What happens when you disable a product?

Under Shop Parameters > Product Settings, the default behaviour for disabled products is an error page with a 404 response; the other options are a 410, or showing the product as discontinued with a 200, 404 or 410 response17. On each product, the SEO tab has a redirection setting for when the product is offline, which allows a permanent (301) or temporary (302) redirect to another product or to a category18.

The rule of thumb: if the product is not coming back and has a clear replacement, 301 to the replacement or its category; if it is not coming back and there is no replacement, 410; if it is coming back soon, show it as discontinued with a 200 so you keep the URL.

What structured data does the theme output?

Classic and Hummingbird generate a product JSON-LD block in templates/_partials/microdata/product-jsonld.tpl1920. This is what Hummingbird 2.1.2 prints, against what Google asks for in merchant listings21:

Property
name, image, offers.price, priceCurrency
Hummingbird 2.1.2
Yes
Google
Required
Property
availability, url, priceValidUntil
Hummingbird 2.1.2
Yes
Google
Recommended
Property
sku, mpn, gtin (EAN-13), gtin12 (UPC)
Hummingbird 2.1.2
Yes
Google
Recommended
Property
brand
Hummingbird 2.1.2
The manufacturer; without one, the store
Google
Recommended
Property
aggregateRating
Hummingbird 2.1.2
Yes, with the product comments module
Google
Recommended
Property
itemCondition
Hummingbird 2.1.2
Only if you display the condition
Google
Recommended
Property
shippingDetails, hasMerchantReturnPolicy
Hummingbird 2.1.2
No
Google
Recommended

Two details. The markup's description comes from the page's meta description, not from the product description: fill it in on every product. And if you assign no manufacturer, the brand becomes your store's name; for third-party products, assign the real manufacturer. For shipping and returns, Google recommends declaring the policies once in your Organization markup21. More detail in the guide to product schema.

How do you force HTTPS and speed up the store?

Under Shop Parameters > General, turn on Enable SSL. In the 9.2 code, with SSL on, the store serves every page over https and 301-redirects requests that arrive over http22. HSTS and the other headers belong on the server: the guide to Apache HTTPS, HSTS and security headers has the snippets.

Under Advanced Parameters > Performance23:

  1. Smarty: in production, keep caching on and choose never to recompile template files; Force compilation is for development only.
  2. CCC: Smart cache for CSS and for JavaScript are on in a fresh installation24. PrestaShop asks you to test the store with the JavaScript one, because combining scripts can sometimes cause problems.
  3. Debug mode: off in production.

Measure the result against Google's thresholds at the 75th percentile: LCP of 2.5 s or less, INP of 200 ms or less and CLS of 0.1 or less25.

How to check it

  • Canonical redirect: curl -I https://www.example.com/12-wrong-name.html should return a 301, not a 302.
  • robots.txt: open /robots.txt, look for your block at the end and for the Sitemap: line, and review the robots.txt report in Search Console.
  • Canonical: Search Console URL Inspection on a product with a combination and on a filtered category.
  • Markup: run a product page through the Rich Results Test.

What SmoothSeen does with this

SmoothSeen analyses a product or category page and checks what this guide configures: robots.txt, sitemap, canonical and noindex, product structured data, speed with real-user Core Web Vitals (or Lighthouse when there is no field data), compression, HTTPS and headers. On the AI side it checks which crawlers your robots.txt allows, keeping search and training apart, and whether your server returns a 403 to any of them.

What to do this week

Open SEO & URLs and check that Redirect to the canonical URL is set to 301. Then generate the sitemap, regenerate robots.txt and confirm it carries the Sitemap: line. To see the rest of the list measured, analyse your online store with SmoothSeen.

Frequently asked questions

Can you remove the number from PrestaShop URLs?

Not with the default routes: the numeric ID is part of the product and category routes, and PrestaShop uses it to find the page. Third-party modules can remove it, but they change every URL in the store. It only pays off on a new store or in a planned migration with 301 redirects from every old URL.

Do you need to regenerate robots.txt after updating PrestaShop?

It is worth checking. The file does not update itself: it reflects the rules of the version you generated it with and the languages active at that time. After a major update, or when you add a language, generate it again from SEO & URLs. If you added rules by hand, move them into a module first so you do not lose them.

Does PrestaShop block ChatGPT or Perplexity?

No. The generated robots.txt only has the User-agent: * group, with blocks on parameters, private controllers and internal folders. OAI-SearchBot and PerplexityBot can read product and category pages. If you are not being cited, check first whether your server or firewall answers them with a 403 while serving the page to a browser.

Are PrestaShop's meta keywords worth filling in?

Not for Google. PrestaShop still has a keywords field on some pages, but Google documents that the meta keywords tag has no effect at all on indexing or ranking in Google Search. Spend that time on the meta title, the meta description and the product description, which do show up in results.

Sources

  1. 1PrestaShop 9.2.0, official PrestaShop repository on GitHub, 30 September 2026.
  2. 2install-dev/install_version.php, official PrestaShop repository, version 9.2.0, accessed 9 October 2026.
  3. 3PrestaShop 9.1 is available, PrestaShop Project, 23 March 2026.
  4. 4SEO and URLs, PrestaShop 9 documentation, accessed 7 October 2026.
  5. 5install-dev/data/xml/configuration.xml (PS_CANONICAL_REDIRECT) and classes/controller/FrontController.php, official PrestaShop repository, version 9.2.0, accessed 9 October 2026.
  6. 6classes/Dispatcher.php, official PrestaShop repository, version 9.2.0, accessed 9 October 2026.
  7. 7src/Adapter/Presenter/Product/ProductLazyArray.php, official PrestaShop repository, version 9.2.0, accessed 9 October 2026.
  8. 8ps_facetedsearch: src/Product/SearchProvider.php, official PrestaShop repository, accessed 9 October 2026.
  9. 9controllers/front/listing/CategoryController.php, official PrestaShop repository, version 9.2.0, accessed 9 October 2026.
  10. 10Pagination, incremental page loading, and their impact on Google Search, Google Search Central, updated 10 December 2025.
  11. 11Managing crawling of faceted navigation URLs, Google Search Central, updated 18 December 2025.
  12. 12classes/Tools.php, generateRobotsFile and getRobotsContent functions, official PrestaShop repository, version 9.2.0, accessed 9 October 2026.
  13. 13Overview of OpenAI Crawlers, OpenAI, accessed 7 October 2026.
  14. 14Google's common crawlers, Google Crawling Infrastructure, updated 14 July 2026.
  15. 15PrestaShop/gsitemap, official repository of the Google sitemap module, accessed 9 October 2026.
  16. 16Build and submit a sitemap, Google Search Central, updated 8 July 2026.
  17. 17ProductPreferences/GeneralType.php, official PrestaShop repository, version 9.2.0, accessed 9 October 2026.
  18. 18Managing products, PrestaShop 9 documentation, accessed 9 October 2026.
  19. 19PrestaShop/classic-theme: product-jsonld.tpl, official PrestaShop repository, accessed 9 October 2026.
  20. 20PrestaShop/hummingbird v2.1.2: product-jsonld.tpl, official PrestaShop repository, accessed 9 October 2026.
  21. 21Merchant listing (Product, Offer) structured data, Google Search Central, updated 8 September 2026.
  22. 22classes/controller/FrontController.php, sslRedirection function, official PrestaShop repository, version 9.2.0, accessed 9 October 2026.
  23. 23Performance, PrestaShop 9 documentation, accessed 7 October 2026.
  24. 24install-dev/data/xml/configuration.xml, official PrestaShop repository, version 9.2.0, accessed 9 October 2026.
  25. 25Web Vitals, web.dev (Google), updated 31 October 2024.

How to cite this article

SmoothSeen. (2026, October 7). PrestaShop SEO: friendly URLs, canonical redirects, robots.txt, schema and speed. https://smoothseen.com/en/blog/prestashop-seo/

Who writes this

SmoothSeen is a website audit tool that measures visibility in search engines and AI assistants and delivers reports under the agency's own brand.

This blog belongs to SmoothSeen: when an article discusses the product, it does so knowing the product is ours. Third-party figures link to their original source.

Change history

  • First version.

Keep reading

PrestaShop 9 SEO: a technical guide for your store