Stupid Question About 301 Redirect

JakeStratham

New member
Oct 28, 2009
2,641
177
0
Location, Location
I need your help.

I'd like to 301 a Wordpress site to another domain. Ideally, every page on the old site should send folks to the home page of the new site. For example:

oldsite.com ---> newsite.com
oldsite.com/about/ ---> newsite.com
oldsite.com/contact/ ---> newsite.com
oldsite.com/whatever/ ---> newsite.com

I know there are a few options - for example, putting something like the following in the .htaccess file:

RewriteEngine on
RewriteRule ^(.*)$ http://newsite.com/$1 [R=301,L]

... or inserting some redirect code in the header.php file

... or using something like this plugin or this plugin.

Strangely, I've never had a reason to 301 a site, and realize this is a facepalm question. I admit my ignorance.

I'm looking for the easiest way possible, preferably something I can do through the WP dashboard or cpanel.

What method would you suggest?
 


For SEO benefit you do not want to redirect all the pages on the old site to the same page on new site (ex. oldurl.com/a, oldurl.com/b = newurl.com/new).

Either way, SEO benefit or not: You don't want to do a Wildcard Redirect because that will try to match up the redirects to the other website (ex. oldurl.com/a = newurl.com/a).

If you're not dev savvy you can just apply in cPanel or wherever you purchased the registrar (usually on the registrar).

I do not recommend plugins usually (security/speed risk), for a quick job like this you especially do not want one.
 
No need to touch the .htaccess.

You can do this directly at the registrar. Go to domain management, click on the domain, click URL forwarding. You'll get these fields:

HOST NAME IP ADDRESS/ URL RECORD TYPE
@
www

For IP ADDRESS/URL, type in the full homepage url
For RECORD TYPE, click URL Redirect (301)