Follow these steps to make your website URLs more user-friendly using the .htaccess file:
- Login to your Control Panel or FTP
Access your website’s control panel or use an FTP client to manage files. - Open the File Manager or Connect via FTP
Navigate to the "File Manager" section in your control panel or establish an FTP connection. - Locate the
public_htmlDirectory
Go to your website’s main directory. - Edit or Create the
.htaccessFile
Open the existing.htaccessfile or create a new one if it doesn’t exist. - Add the Rewrite Code
Insert the following code to enable user-friendly URLs:# Enable mod_rewrite RewriteEngine On # Rewrite rule to convert URLs RewriteRule ^your-friendly-url$ your-script.php [L]Replace
your-friendly-urlwith the desired user-friendly URL path.
Replaceyour-script.phpwith the actual file or resource to load. - Save the File
Save the.htaccessfile and test your user-friendly URL in a browser.
Your website URLs are now more readable and easier for users to navigate.