How to add .html extension to WordPress permalinks?

Many top-ranking websites on search engines may include links that lack the .html and.php extensions. In most cases, adding them to your new URLs is not necessary from an SEO standpoint. However, there are several circumstances in which this may be beneficial. Migration from Magento to WooCommerce is one example of this.

Is it beneficial for SEO to end URLs with “.html”?

The identical question has been posed hundreds of times on StackOverflow and Quora. Although SEO is a complex topic in and of itself, the solution is straightforward in this situation. URL file extensions, such as .html, .php, .aspx, and so on, do not seem to have a direct impact on the search engine ranking of your website.

Furthermore, this subject has previously been addressed in one of the videos on the Google Search Central YouTube channel. According to John Mueller in the video, Google does not care whether URLs terminate in .html, .php, .asp, or have no file extensions at all.

As previously indicated, retaining the.html extension in your WooCommerce shop permalinks after migrating from Magento makes sense.

Increasing numbers of businesses are making the switch from Magento to WooCommerce. There are many articles on the internet that outline the overall migration procedure. If you use Magento, you have surely noticed that the platform automatically appends a .html suffix to the end of your product and category URLs.

After moving to WooCommerce, it is a good idea to maintain your existing store URLs intact for SEO reasons. It may be difficult, however, to maintain your original permalink structure using simply WordPress’s built-in features. Permalink Manager may be the most straightforward answer to this issue.

You can use the plugin to recreate the original permalink structure of your Magento shop by removing the WooCommerce rewrite bases added to native permalinks. Simultaneously, you may add .html to the URLs of products and product categories.

Permalink Manager gives you complete control over your permalinks. You may use this in a variety of ways to improve your SEO score. For example, you can use it to quickly add .html to your WordPress permalinks.

The instructions below apply to WooCommerce permalinks, but you may do the same with other content types in a similar manner. If you want to append the file extension to your URL addresses, go to the “Permastructures” section and use the permalink format editor.

"Permastructures" section

The procedure is quite simple. Find the content type where the file extension should be added to the permalinks and enter it at the end of the input field.

WooCommerce permalinks, like Magento's, may contain a.html extension.
WooCommerce permalinks, like Magento’s, may contain a.html extension.

To apply the new format to existing content and append the extension to the old URLs, use the “Regenerate/reset” tool. More information on how to regenerate custom permalinks may be found in a separate article.

From now on, all new permalinks will end with .html file extension. If needed, you can individually tweak each of them using “URI Editor“.

URI Editor
The Permalink Manager will automatically assign the default URI as a custom permalink for new posts and terms.
Go up