UltimateWB
Do MORE, FASTER, EASIER, & BETTER!
Login    Register    Forgot Password?
Article Keywords
Titles
Content
Tags
How To Create 301 Redirects via .htaccess file

If you just want to redirect users to a temporary page while you are creating your website, you can use the Site Maintenance Redirect App that comes built-in UltimateWB.  But say you have switched from another website builder that didn't let you choose your webpage URLs and you want to change your page URLs, then you want to create server-side 301 redirects.  You want to tell search engines and web visitors what your old webpage URL was and what the new webpage URL is, both to redirect users and also to transfer your webpage ranking.  The best way to do this is by directly editing your .htaccess file, and just add the necessary coding to the very end of the file.

1) Login to your cPanel (web hosting control panel)

2) Scroll down the page and Click on the "File Manager" icon:

cPanel, File Manager

 

3) On the pop-up, make sure the checkbox is marked to "Show Hidden Files (dotfiles)" and Click "Go":

cPanel, File Manager, Show Hidden Files, .dot files

 

4) Now on your File Manager, scroll down to the .htaccess file - this should be right after your folders.  Click to highlight, and then click on the top menu "Edit" button:

cPanel, File Manager, Edit .htaccess file

 

5) This will open the .htaccess file so that you can edit it and then click on the top right "Save" button on this page to save your changes.  Scroll down this page and add your coding to the bottom of the page.  It is important that you make no changes to the current code to avoid problems with your website.  If you make this mistake though, you can download another copy of the UltimateWB software .htaccess file and re-upload it to your server.

 

Ok, now the code you should add!

Here is a sample code you can follow for redirecting Page URL 1 to Page URL 2:

Redirect 301 /old-page-name http://www.your-domain.com/new-page-name

To redirect an entire directory to another URL:

RedirectMatch 301 /old-dir/(.*) http://www.yourdomain.com/new-dir/$1

Any files in /old-dir/ will be redirected to /new-dir/

Any questions, just ask!

Related Links
Report article by:
Report a concern
Comments:
0.00 Rating0.00 Rating0.00 Rating0.00 Rating0.00 Rating0 Ratings
Please use the form below to post your comment/rating!
Name:
Email (not posted):
Website:
Rating:
1 star out of 52 stars out of 53 stars out of 54 stars out of 55 stars out of 5
Subject:
Comment:
Enter Code:
*case sensitive
Subscribe to new comments
Comments/Ratings (0)
Sort By
No Comments, be the first to comment!
Report comment by:
Report a concern
Comments: