Category: cPanel & Hosting • Est. reading time: 3 minutes
A clean URL like yoursite.com/services reads better and ranks better than a messy one like yoursite.com/index.php?page=7. On most sites you can shape your URLs with rewrite rules in your .htaccess file. Here is the idea and a safe way to do it.
The Concept
Rewrite rules quietly translate a friendly address a visitor sees into the real file your server loads behind the scenes. The visitor gets the clean link, your server still finds the right page.
A Basic Example
Inside your .htaccess file, a rule to serve a clean path might look like this:
RewriteEngine On
RewriteRule ^services/?$ services.php [NC,L]
That lets visitors reach services.php simply by typing /services.
If You Run WordPress
Good news: you do not need to hand-write any of this. WordPress creates clean URLs for you through its Permalinks setting. Just choose the Post name option under Settings, then Permalinks. See our guide on WordPress permalinks.
Edit .htaccess carefully. Back it up first in File Manager, and change one rule at a time, since a mistake here can take your whole site offline.
Want clean, search-friendly URLs without the risk? This is squarely in our wheelhouse. Reach us at support@allydrez.com or 1-321-209-2004.