Search engine friendly URLs (SEFs) are not required, but are recommended for any website, including e-commerce. This can help search engines index the pages of your site, and it's considered a best practice for Search Engine Optimization. Fortunately, setting up SEFs in PrestaShop is easy to do and can be completed in just a few short steps.
Non SEF URLs vs SEF URLs
For a better understanding of the differences between non-search engine friendly URLS (non SEF URLs) and SEFs (search engine friendly URLs), let's look at an example of each.
|Non SEF URL
||A non SEF URL will contain query strings and IDs that will mean nothing to search engines or visitors:
||A SEF URL will be a more meaningful URL and can contain the category name, product name, etc.:
As you can see, SEF URLs provide information useful to search engines and look much better as well.
Enabling SEFs in Preferences
- The first part of the process to enable SEFs in PrestaShop is to enable friendly URLs in the Preferences tab of PrestaShop
- Begin by logging into your PrestaShop back office.
- Navigate to the Preferences tab and click on the SEO & URLs link
- Scroll down the page to the Set Up URLs area
- Click Yes next to Friendly URL to enable this for your shop and click the Save button.
This is only the first part of the process, now we will need to regenerate our .htaccess file to start using SEF URLs in our PrestaShop installation.
Generating Your New .htaccess file in Tools
- Navigate to the Tools tab in your PrestaShop back office and click on the Generators link.
- Under .htaccess file generation, make sure the box is checked nex to Friendly URL and click the Generate .htaccess file button.
Congratulations, you've now enabled Search Engine Friendly URLs (SEF URLs) for your PrestaShop site! Now your pages in PrestaShop will be more easily indexed by search engines.