Home
/
Website Help
/
Other
/
How to mask URLs using .htaccess

How to mask URLs using .htaccess

The following method will allow you to mask some of your website’s address.

For example, when someone opens up:

http://yourdomain.com/something

the actual content that will be displayed can be the one under:

http://yourdomain.com/something/else

although the URL in the visitor’s address bar will remain http://yourdomain.com/something.

To achieve this, add rules similar to the ones below into your website’s .htaccess file:

RewriteEngine On
RewriteRule ^something/?$ /something/else/

Make sure to substitute something and else with the directories you use on your website.

RELATED ARTICLES

Share This Article