InMotion Hosting Support Center

When using SEF URLS in your PretaShop 1.5 store, you may not like the default format. For example, the format for a product is as follows: category/id-rewrite-text-ean13.html. This URL comes from different variables strung together to give you a more human-readable format. There are four parts to the URL as shown by the color differences in the text. Below is a table displaying the separate sections:

KeywordSample CodeDescription
category music-ipods The category under which the product is listed.
id 1 The unique product ID number in the database.
rewrite text ipod-nano Thsi comes from the friendly URL field under the SEO tab of the Product Edit page.
ean13 123 This comes from the ean13 or JAN field from the Information tab of the Product Edit page.

Why change the format?
The friendly URL for an ipod nano using the sample code for each section above will be This URL may not suit your tastes and you may want to arrange it differently for your customers. Perhaps you want to remove the ean13 number, or move the product ID to the back, or make it appear as its own category separated by slashes. Unfortunately, you cannot remove the id entirely from the URL as it is required by PrestaShop's core coding.

Formatting Syntax
The default URL format is {category:/}{id}-{rewrite}{-:ean13}.html. The syntax is fairly straight forward, each keyword is enclosed in a set of curly braces like {}. You can add a slash (/) or a dash (-) in between keywords (outside the curly braces) to add them to the URL. For example: {category}/{id}-{rewrite} will result in category/id-rewrite. You may also notice the use of the colon (:) character. This is used within a keyword when adding a slash or a dash. {category :/} results in category/. You can use either method to add dashes or slashes. Below we will change the default URL format for our ipod nano to be more visitor friendly.

Modifying your SEF URL format in PrestaShop 1.5

  1. Log into your PrestaShop admin dashboard.
  2. Using the toolbar across the top of the page, hover over the Preferences tab and then click on the SEO & URLs option from the popup menu.
  3. Once on the SEO & URLs page, scroll down until you get to the section labeled Schema of URLs. Although there are many fields to work with, we will work with the first one, Route to products. In our example, we will remove the ean13 number from the URL by removing the keyword tag {-:ean13}. We also will add a slash instead of a dash between the product ID and the rewrite text. To do this we enter the code in the field as {category:/}{id}/{rewrite}.html
    new url format coding
  4. Once you have your desired format in place, click the green Save button in the upper right corner to save the changes. Below you can see the before and after shots for the URL formatting change.
    format: {category:/}{id}-{rewrite}{-:ean13}.html format: {category:/}{id}/{rewrite}.html
    before url formatting change after SEF URL format changes
Was this article helpful?
Continued Education in Course Prestashop 1.5
You are viewing Section 24: 343: How to alter the format of SEF URLs in PrestaShop 1.5
Section 23: 347: How to change the invoice date format in PrestaShop 1.5
Section 25: 342: Restoring a database backup in PrestaShop 1.5

Related Questions

Here are a few questions related to this article that our customers have asked:
Ooops! It looks like there are no questions about this page.
Would you like to ask a question about this page? If so, click the button below!
Ask a Question

Support Center Login

Our Login page has moved. Please click the button below to be redirected to the login page.

n/a Points
2014-10-07 4:00 am

May i know how to rewrite the category page from to

How to rewrite product page from to

How to rewrite cms page from to


43,761 Points
2014-10-07 7:52 am
Hello Vivian,

Unfortunately, the SEF do not remove the category ID from the URL. There is a paid solution for this, if you like. It is about 50 Euros and can be found here.

As for the other requests, /en/ is the default for English language version, and removing the category name is possible, but would take you modifying source code to do it. It is not readily done by using the back end of PrestaShop as that is not what it was made for.

SEF URLs are not meant for the customer, but for Search Engines. Instead of having something like it comes out like It is meant for search engines to better understand how to rank your pages, and since they are dynamically generated, the SEF makes them look more like actual pages would. Customers or visitors simply bookmark URLs, they do not memorize them, so removing a category name is not useful for that purpose.

Removing the ID number, even though it can be done via the paid module, is not recommended at all. PrestaShop uses that number, so removing it from the URL can have consequences.

Kindest Regards,
Scott M
n/a Points
2014-10-07 10:16 pm

For this domain was about 3 years, some of my category page is PR1. If i cannot make the url same as previously then my PR will be gone. Category on url just make my url too long so i want to remove it. Are you mean free version cannot solve this? I must buy the module to solve this?

43,761 Points
2014-10-08 7:06 am
Hello Vivian,

To remove the product ID from the URL, yes, you would need to purchase a module. But we still recommend against doing that as it can have consequences on your site.

You can change the existing URL structure a bit, using the instructions above. For instance, you can try removing the {category} portion of the URL. This means that it would go from {category:/}{id}/{rewrite}.html to {id}/{rewrite}.html

That may make is shorter for you. We have extremely long URLs in some of our articles and we are a PR 7 site. The longer URLs have not affected our ranking, so I wouldn't dwell on that too much.

Kindest Regards,
Scott M
n/a Points
2015-09-18 7:04 am

Hello scott, sorry to revive this topic again but you've said twice, "removing IDs can have consequences...", could you explain it a bit more, what type of consequences?Many thanks in advance!Regards,Xavi

43,761 Points
2015-09-18 10:18 am
Hello Xavi,

In the simplest terms it can break the ability of the URL to point to the correct item. This can range from a URL not found to pointing to a different product entirely.

Kindest Regards,
Scott M
n/a Points
2014-08-09 8:21 am

Great post, I have developed a module that cleans URLs and make them SEO friendly, let me now how do you rate this one,

31,445 Points
2014-08-11 11:28 am
Hello Alastair,

Thank you for your suggestion. Your Pretty URLs PrestaShop module looks helpful.

If you want to create a blog post about it in our User Submitted articles section, I would be happy to link to the post.

If you have any further questions, feel free to post them below.
Thank you,

n/a Points
2015-08-11 2:21 am

Thanks for appreciating our module. I have written a detailed post about PrestaShop URLs with title "One Webpage, Multiple Links, Ugly or Pretty URLs: Does it Matter to Google?" 

Please link this post to my article as you said above

Link of article is here;


10,077 Points
2015-08-11 11:39 pm
Hello Alastair,

I have enabled the link to the article you have written. Thanks again for your input.

Best Regards,
TJ Edens
n/a Points
2015-08-12 4:06 am

Thank you so much for approving the link. Regards,

Post a Comment

Email Address:
Phone Number:

Please note: Your name and comment will be displayed, but we will not show your email address.

11 Questions & Comments

Post a comment

Back to first comment | top

Need more Help?


Ask the Community!

Get help with your questions from our community of like-minded hosting users and InMotion Hosting Staff.

Current Customers

Chat: Click to Chat Now E-mail:
Call: 888-321-HOST (4678) Ticket: Submit a Support Ticket

Not a Customer?

Get web hosting from a company that is here to help. Sign up today!