This compact guide will primarily explore SEO and URL management in PrestaShop, but many of the concepts presented are applicable to any CMS. We will delve into how PrestaShop creates URLs for categories and products and discuss strategies for effectively optimizing them.

What is meant by SEO and URL

SEO, or"Search Engine Optimization," encompasses a number of techniques and strategies used to improve a website's position on search engines such as Google. The main goal of SEO is to increase a site's visibility, attract more traffic and improve its online authority. SEO practices can range from technical optimizations on the site, such as improving page load speed, to content strategies such as selecting relevant keywords and creating valuable content that answers users' questions.

URLs, short for"Uniform Resource Locator," are essentially the Web addresses that lead users and search engines to a specific Web page. A well-structured URL is crucial for SEO because it can effectively communicate the content of the page to search engines and improve the user experience. A clear and descriptive URL is more easily interpreted by both humans and machines, contributing to better understanding and categorization of the site in search results.

Understanding and optimizing both the SEO and URL-related aspects of your website is critical to ensuring an effective and competitive online presence.

URL optimization in PrestaShop: Introduction to Friendly URLs

Product tab SEO setup in PrestaShop 8

By default, second-level URLs in PrestaShop (pointing to specific pages rather than the main domain) are not very informative, either to the customer or to search engines. For example, a URL such as http://www.mioecommercepresta.it/product.php?id_product=15 does not provide clear indication of the content of the page. The implementation of friendly URLs solves this problem, as demonstrated by the URL http://www.mioecommercepresta.it/17-salumi-tipici/15-tronchetto-di-porchetta.

In the case of this second URL, both categories and products are represented via URL friendly: in the example, id_category=17 turns into 17-typical-foods and id_product=15 turns into 15-portfolio. Although the ID number cannot be removed by default, keywords can be generated or changed manually based on the category or product name. This customization is done directly on the product or category configuration page, accessible from the Catalog menu. Here, the "Friendly URL" field is located on the main category configuration page and on the "SEO" tab of the product configuration.

Other elements of PrestaShop benefit from friendly URLs, such as CMS pages, user account pages and those with automatically generated content. The "SEO & URLs" section in the administration panel lists these pages and allows you to edit their friendly URLs and associated meta tags (title, description, keywords).

It is important to note that URL friendly URLs are only functional on servers that support URL rewriting, such as those that use Apache's mod_rewrite feature. Make sure your server supports this feature (consult your hosting provider) because enabling URL friendly could make your store inaccessible to customers if the server is not configured properly.

URL customization in PrestaShop

Product URL in prestashop

Since version 1.6 of PrestaShop, you have the ability to change the structure by which friendly URLs are generated within your online store.

For example, the default format for product display URLs is {category:/}

{id} - {rewrite} {-:ean13}.html, resulting in a URL such as /salumi-tipici/15-tronchetto-di-porchetta.html.

If you wish to change this structure, you can opt for a different format, such as {manufacturer:/}

{id} -{rewrite:/}, which would generate a URL like /leonifood/15-tronchetto-di-porchetta.html/.

To set up these changes, PrestaShop offers 8 configurable fields, each of which can be associated with several available keywords. It is important to note that some of these keywords are mandatory and are marked with an asterisk (*).

For example, when configuring product URLs, you could use the following keywords: id*, id_product_attribute*, rewrite*, ean13, category, categories, reference, meta_keywords, meta_title, manufacturer, supplier, price, tags. Of these, id*, id_product_attribute* and rewrite* are the only mandatory keywords. These options offer significant flexibility to customize URLs according to your store's specific needs and SEO strategies.

This customization system allows you to tailor URLs to your specific needs, improving both the usability and SEO of your site.

We Dispel Two Common SEO Myths: URL Length and Product IDs

There are two widely held misconceptions among SEO specialists: one concerns the length of URLs, and the other concerns the presence of product and category IDs in them.

Regardingthe first myth, the idea that short URLs are preferable dates back to outdated skills. Today, in 2024, the extensive use of artificial intelligences has made search engines capable of effectively handling even long URLs. Indeed, the latter can help engines better identify, for example, a product in our e-commerce. We will delve into the advantages and disadvantages of long URLs versus short URLs later.

The second myth concerns IDs in products and categories. This false belief stems from misinterpretation and, unfortunately, also from incompetence in the field. For example, a URL such as https://miosito.it/prodotto?id=1 is not a "Friendly URL," while a URL such as https://miosito.it/it/salumi-tipici/15-tronchetto-di-porchetta.html is considered a well-structured "Friendly URL." In the second example, the inclusion of a number (15) before the product name serves technical motivations of the CMS but also facilitates the work of search engines, especially in e-commerce catalogs, by helping them distinguish similar products without confusing them for duplicate URLs.

In addition, adding data such as the EAN of the product or its weight in kilograms to the URL can greatly improve indexing and climbing in search results (SERPs).

As aresult, there is no benefit in removing product and category IDs if the URL is well structured; doing so in PrestaShop or other CMSs would only mean spending money on modules that bring no benefit and may even worsen the indexing and stability of the CMS being used.

Is it better to Use Category or Categories in the product url?

As part of URL configuration in PrestaShop or other content management systems, category and categories keywords can be used to include category information in product URLs, but they serve slightly different purposes.

  1. Category: This keyword usually refers to the main or most relevant category with which a product is associated. If you use category in the URL structure, the name of the main product category will be shown in the URL. This is useful for keeping URLs simple and straightforward, especially if the product belongs to a category that is closely related to its main content or purpose.

  2. Categories: The categories keyword can be used to include all the categories associated with a product, often structured in a hierarchy. The use of categories in URLs can lead to longer and more complex URLs, but it can also improve SEO by including more specific and contextually relevant keywords that describe the product across multiple levels of categories.

The choice between categories and categories thus depends on the specific goals of the site, its structure, and SEO strategy. If you want shorter, more manageable URLs, category might be the best choice. On the other hand, if you want to maximize keywords for SEO and don't care about URL length, categories might be more advantageous.

If I include EAN or product CODE URL doesn't it become too long?

Including EAN13 (the European barcode that uniquely identifies products) and reference (product-specific reference) in product URLs in PrestaShop can offer specific advantages and disadvantages. Here is an overview to help you decide whether or not to include these elements in your e-commerce URLs:

Advantages

  1. SEO and Specific Search: Including EAN13 and reference can improve SEO for very specific searches. Customers searching for a specific product using its EAN code or reference may find the product page more easily if these data are present in the URL.

  2. Uniqueness of URLs: EAN13 codes and references are unique for each product, so their use in URLs helps avoid the problem of duplicate URLs, which can confuse search engines and dilute SEO strength.

  3. Traceability: For retailers monitoring traffic or product performance across multiple channels, having EAN13 and reference in URLs can make it easier to analyze product-specific metrics.

Disadvantages

  1. URL complexity: URLs that include codes such as EAN13 or reference tend to be longer and more complex, which can reduce readability for the user. Simple URLs are generally easier to remember and enter manually. It is also true, however, that no one today especially from mobile enters URLs manually which still subjects even short URLs to errors. In non-online advertisements and even on product labels QR codes are used today in order to facilitate and entice navigation. So this is a false problem.

  2. Aesthetics and Usability: Longer, numeric URLs can be less visually appealing and may look less "clean" or professional. Also, complex URLs can be difficult to share, especially on social media platforms where space is limited. Purely this is a problem that in 2024 has no cause for concern, social bookmarking is no longer used, so much so that Oracle shut down AddThis in 2023, and most importantly, there are services that shorten URLs and also provide statistical information such as bitly.com, which were initially created to get around this problem and are now used to get statistical data on how many clicks the url is receiving and thus get feedback on how well an ad campaign is performing.

  3. Risk of Errors: With the addition of specific numbers such as EAN13 and reference, the risk of typing errors by users attempting to enter the URL manually increases. As with 1 and 2 is not a real problem, we are unlikely to enter a URL by hand in the browser today and certainly not to go to a specific product page. The use of short URLs and QR Codes have completely supplanted this need, plus every browser today allows us to share web and social content without the need to copy or rewrite URLs and they can even generate QR Codes through extensions to use them on our paper documents and recently QR Code generation is native in Windows 11.

It is important to point out that the argument that a longer URL may complicate manual entry due to a higher risk of errors does not apply to PrestaShop's friendly URLs. These URLs include the product or category ID in their structure, and the CMS can recognize these IDs and automatically redirect to the corresponding element, preventing many typing errors. Consequently, removing IDs from URLs in PrestaShop is not only unnecessary, but could be a counterproductive decision.

Configuring URLs in PrestaShop

Let's explore how to configure URLs in the PrestaShop CMS, a key aspect of optimizing the visibility and SEO effectiveness of your e-commerce site. To change URLs in PrestaShop, it is important to follow some specific steps that will allow you to optimize the URL structure to improve both the usability and SEO of your online store. Here's how to proceed:

  1. Access theAdministration Panel: First, you need to access the back office of your PrestaShop site.

  2. Navigate to 'Traffic & SEO Preferences': Once in the admin panel, look for the"Traffic & SEO" option usually found under the "Store Parameters" section of the menu.

  3. Edit URL Settings: In this section, you will find several options for configuring URLs. You can change the URL structure for product pages, categories, manufacturers, and more. PrestaShop also allows you to customize static URLs like those in CMS pages.

  4. Enable URL Rewriting: Make sure the URL rewriting option is enabled. This makes it friendlier for both users and search engines.

  5. Set URL Templates: You can customize how URLs are generated using available tokens, such as

{categories} , {id} , {rewrite} , etc. For example, for a product URL, you might choose a template such as {category:/} {id} - {rewrite} .html to include categories, product IDs, and an SEO-friendly slug.
  • Save Changes: After configuring the settings according to your preferences, be sure to save all changes.

  • Regenerate URLs: If you have made significant changes to URLs, you may need to regenerate links to ensure that all pages are accessible with the new structure. This can be done in the"Traffic & SEO" section itself.

  • Correctly changing URLs in PrestaShop can significantly improve your site's usability and search engine optimization, contributing to better indexing and ranking in search engine results pages (SERPs).

    Conclusions

    In this guide, we explored the flexibility of URL management on PrestaShop. Typically, the default settings, enabling Friendly URLs and setting canonical 301 redirection in the URL Setting option, are sufficient, as the standard configurations are already optimal.

    PrestaShop also offers the ability to make advanced customizations, including SEO management of CMS pages through the SEO & URL section, where you can configure Friendly URLs and add other SEO parameters.

    It is important to note that PrestaShop also supports the use of accented URLs. Although Google handles them without problems, and they may be practical in the UK, some SEO tools, including updated ones such as SEO Zoom, may erroneously report duplicate URLs. This error does not stem from an actual problem, but from failure to update to standards after the use of accented URLs, even in domain names, was authorized in 2012.

    Many SEO manuals are outdated and do not reflect ongoing changes in the field. Google itself has released numerous core updates, nine in the past two years, with the last update on March 5, 2024. Each update changes how the search engine indexes content, aiming to provide users with relevant, high-quality search results.

    To reiterate, there are no shortcuts in SEO. Black Hat SEO techniques or over-optimization can lead to a brief improvement in indexing, but followed by long periods of penalties.

    There is no point in optimizing a URL without first improving the content itself. The main goal should be to provide essential information to customers, writing for them and not just for Google. You need to ask what the customer wants to know about the products being sold and make sure that all mandatory information, such as ingredients and allergens for food products, are present. A common mistake, especially for those who sell branded products or are manufacturers, is the omission of the GTIN code (EAN 13), which is essential not only for distribution but also to allow Google to uniquely identify a product and improve its indexing.

    In the e-commerce context, the product description and its data sheet account for about 90 percent of SEO effectiveness; everything else, although useful, has a marginal impact on indexing if there are no gross errors.

    It is crucial to check, before proceeding to change the URLs of an e-commerce or website that is already online, whether the platform supports automatic redirection from old to new URLs. In the absence of this functionality, you will need to manually implement 301 redirects to ensure that the old URLs correctly redirect to the new ones. This step is critical to maintain existing indexing and to avoid a loss of traffic. It is essential that these changes be handled by an SEO expert to ensure that the redirects are configured correctly and to minimize the negative impact on the site's ranking and presence on the engines; a failure to do this can lead to a complete loss of organic traffic and take several months to recover previous SERP rankings.

    Author: Loris Modena

    Loris Modena

    SENIOR DEVELOPER

    For Ind Loris Modena owner of Arte e Informatica, began working in the computer industry in 1989 as a systems engineer involved in the maintenance and installation of computer systems. He starts programming for the web in 1997 dealing with CGI programming in PERL and later moving to programming in PHP and JavaScript. During this period he approaches the Open source world and Linux server management.

    Product added to wishlist