Custom redirects

by Benson Lee | Last edited: 3/14/2012

Sometimes you may want to give out a simpler URL like http://yoursite.com/men instead of http://yoursite.com/resources/groups/men. These are called "redirects" or " vanity URLs". To make one, you will be editing your site's "htaccess" file. htaccess tells the webserver what to do with different URLs. Warning: errors in the htaccess file will almost invariably result in a broken site!

To edit htaccess, go to Admin > Site > htaccess.

Here is an example redirect rule:

Redirect /men/ http://www.yoursite.com/resources/groups/men

These rules need to be very precise to work correctly. There needs to be a space in between "Redirect", the custom URL ("/men/") and the full URL ("http://www.yoursite.com/help/resources/groups/men").

Your custom URL needs to have a slash at the beginning and at the end. If your custom URL is multiple words, utilize a dash (e.g. /sunday-message/).

If you accidentally break your site entering these rules, deleting them and re-saving will revert your site back to normal.

Feedback

Was this resource helpful?