In the previous post, we already introduced you how to configure URL Rewrites in Magento 2 so that you can easily do it by yourself when setting up your stores.
Today, we continue to show you how to rewrite URLs in Magento 2 manually and especially a new solution to optimize your work with Magento 2 Import URL Rewrites extension.
How to Rewrite URLs Manually in Default Magento 2
After you enable URL Rewrites and Automatic Redirects, you can easily create auto redirect product and category URLs by ticking in the Create Permanent Redirect for old URL checkbox, under URL keys of Product or Category Edit Page.
- For auto product URL redirects:
Check out a tutorial of How to create product URL Rewrites in Magento 2 for more information.
- For the auto category URL redirects:
Therefore, when you change URL keys in the product or category edit page, customers will be redirected to the new URLs without having any troubles and your page is not affected regarding SEO and ranking.
However, there are 2 problems you have to face when using URL Rewrites:
- In case you have a lot of product and category URLs which need to be rewritten, and you have to edit URL one by one in product or category edit page. Besides, adding new URL rewrites in Marketing→ SEO $ Search→ URL Rewrites is another way to rewrite these URLs. However, this is a disaster because it is a big work for you to solve and especially costs you much time and money.
- If you want to rewrite URLs of CMS pages or custom pages, how can you do while there is not any configuration to Create Permanent Redirect for old URL in Edit pages? Therefore, you have to manually do by navigating to Marketing→ SEO $ Search→ URL Rewrites and Add New URL Rewrite.
Hence, we developed Magento 2 Import URL Rewrites extension to help you solve 2 above problems by importing URL Rewrites via a CSV file so that all URL Rewrites can be quickly updated at the same time.
How to Import URL Rewrites to Magento 2
To import URL Rewrites to Magento 2, you need to prepare a CSV file which includes all necessary information about these URLs such as product ID, store ID, old path, the new path and so on. This sample file is easily downloaded in the configuration of the module and has a format as below:
It can be seen that Magento 2 Import URL Rewrite extension allows you to import URL Rewrites of product, category, CMS page, and even custom page.
After preparing the complete CSV file, you need to select Import behavior as your demand and also validate the file by clicking Check data.
If the CSV file does not include any errors, you can quickly Import and receive a message about the successful process. On the contrary, in case the CSV file has problems, they are shown for you in details to edit.
How to Export URL Rewrites in Magento 2
This Magento 2 Import URL Rewrite extension supports export function and allow you to export all URL Rewrites or export URL Rewrites by Entity Type, Store View and Redirect Type. URL Rewrites are exported into a CSV file also.
Magento 2 Import URL Rewrites a very simple task with this extension because you don’t need to edit one by one or add each URL Rewrite in the backend. It is time-consuming and costs you both human resources and costs. Therefore, Magento 2 Import URL Rewrites extension is absolutely an ideal solution to simplify your work as well as optimize their business.
Here is our series of Magento 2 Import Export function. Please take a look for more useful information:
- 6 Best Magento 2 Import Export Extensions for All Websites
- A Complete Guide on Product Import and Export in Magento 2
- How to Add New Product Attributes in Magento 2