SEO.fr Agency > Definition – SEO terms > URL Rewriting definition

URL Rewriting definition

What is URL Rewriting?

URL rewriting is the technique used to transform a complicated or unintelligible basic URL into one that’s easy to read and more comprehensible to both Internet users and search engines. This is necessary because dynamic sites often generate long URLs with code. The aim of this manipulation is to avoid redirecting the user to a non-functional page.

Naturally, a dynamic page address complicates the work of search engine spiders.

Why did we have to create this solution called URL Rewriting? Because, taking into account all the different variables involved, a dynamic website usually generates long, complex URLs for its pages, including codes that are incomprehensible to the surfer and difficult for indexing robots to classify.

These URLs, which are in a form like http://www.siteweb.com/dossier1/fichier1.html or http://www.siteweb.com/textes/texte.php?id=10&page=1&rubrique=2, are generated automatically, and a site’s SEO chances are diminished the more pages it contains.

Unhindered indexing, in other words good SEO, is achieved by writing the URL more explicitly in the first case, and by transforming special characters for easier reading in the second. There are also other SEO advantages to transforming exotic URLs into clean URLs, including the possibility of changing the website hierarchy without disorganizing web addresses, and control over the keywords appearing in URLs.

The importance of URL Rewriting

  • It makes a site’s URLs easier to read and remember, making them more user-friendly.
  • It optimizes natural citations, enabling search engines to understand your site’s web pages more effectively.
  • It makes URLs shorter and links shared on social networks prettier. Better conceal the technology used to generate the page (e.g., conceal the .php extension).
  • It enables better management of redirects and pages that are no longer available, thus improving the user experience.

It’s important to note that URL rewriting can lead to crawling and ranking problems if poorly implemented or configured. Consequently, it’s very important to test these rewrites thoroughly before putting them into production, and in the event of difficulty, correct the problem as quickly as possible!

SEO training?
Sylvain is here for you

16 years of digital marketing expertise

How do I rewrite my URLs?

The first thing to find out is whether your dynamic site’s host is a server that allows URL rewriting. Apache, for example, enables this by activating its “mod_rewrite” module.

The same goes for Microsoft’s IIS, which in ASP uses ISAPI filters that users can purchase, and in ASPX (.NET) offers functions such as RewriteURL. In principle, free hosting does not allow rewriting, which is not an ideal situation for SEO. On the other hand, if your server is dedicated, all you need to do is modify the configuration file to enable rewriting, then restart.

The second step is to find pages with parameters in their address, define their URL schema and write a new, clean URL schema. For example, a URL ending of the form “article.php?id=36&page=5&heading=3” could become “article-36-5-3.html”. The advice in this step is to use separators such as “-“, ” .”, “/”and “+”, which are well recognized by Google, instead of “_”, ” , “, ” ;”, “&”, “#” and “$”.

The third step is to write the rewriting rules in the appropriate .htaccess file.

The fourth step is to change all links to each file whose URL has been modified. The fifth and final step is to update your website and check that everything is in order.

Would you like to work with our team?
We are ready to welcome you!