Reputation: 546243
I'm managing an established site which is currently in the process of being upgraded (completely replaced anew), but I'm worried that I'll lose all my Google indexing (that is, there will be a lot of pages in Google's index which won't exist in that place any more).
The last time I upgraded a (different) site, someone told me I should have done something so that my SEO isn't adversely affected. The problem is, I can't remember what that something was.
Update for some clarification: Basically I'm looking for some way to map the old paths to the new ones. For example:
mysite.com/old_awesome_page.php
, user clicks it.mysite.com/new_awesome_page.php
And when Google gets around to crawling the site again...
old_awesome_page.php
new_awesome_page.php
.There won't be a simple 1:1 mapping like that, it'll be more like (old) index.php?page=awesome --> (new) index.php/pages/awesome
, so I can't just replace the contents of the existing files with redirects.
I'm using PHP on Apache
Upvotes: 0
Views: 238
Reputation: 6345
301 redirect all your old (gone) pages to the new ones.
Edit: Here's a link to help. It has a few links to other places too.
Upvotes: 4
Reputation: 13399
You need to put some rewrite rules in an .htaccess file.
You can find lots of good information here. It's for Apache 1.3, but it works for Apache 2, too.
From that article, a sample for redirecting to files that have moved directories:
RewriteEngine on
RewriteRule ^/~(.+) http://newserver/~$1 [R,L]
This reads:
There are additional directives that you can use to set a [301] redirect
You could do:
RewriteEngine on
RewriteRule old_page.php new_page.php [L]
But you'd have to have a rule for every page. To avoid this, I'd look at using Regular Expressions, as in the first example.
Upvotes: 3
Reputation: 47075
You can tune Google's view of your site, and probably notify its changes, from within Google Webmaster Tools. I think you should build a sitemap of your current site, and have it verified when the site changes.
Upvotes: 2