Redirect from old wordpress site to new php site? Best approach
-
Hi
I have two websites one legacy site done in wordpress the other in php. However I would like to merge the two together and remove the wordpress site.
However it has a good link profile and the pages rank well.
What is the best approach to do a 301 redirect from the old site with all its pages pointing to the homepage of the new site?
If so what's the best way to do this in wordpress?
Many thanks
-
Ian
- Meta refreshes should never be replaced with 301's, they are actual much worse than a 302 redirect.
- There are a few redirects you can find - http://www.aowaa.com/5-wordpress-301-redirect-plugin/ and http://wordpress.org/extend/plugins/simple-301-redirects/. The disadvantage I find with using plugins is that they extremely slow down your site.
- For doing 301 redirects it's entirely up to the server your site is hosted on.
-
Basically because there were too sites in tandem and when the business areas merged there is only a need for one site.
I am struggling with the best way to achieve this as described in my post at the bottom of this thread
-
Can this be done?
on each page indexed?
Are there not any Wordpress plugins that would do this without delving into the htaccess file?
In your example you mention the code below, how would I change what I have below to redirect from my mydomain.co.uk site to point at the correct site mydomain.com site
And on the redirect 301 lines, how would I redirect - what would the code need to be?
www.mydomain.co.uk/sample to www.mydomain.com/newsamplepage.php
-
Hi Ian,
Edward has started on the right step in terms
Ian I wouldn't say cms is too important as hosting and server details, because hosting & server is what limits your ability to migrate the website.
Check out this recent article - http://www.seomoz.org/blog/web-site-migration-guide-tips-for-seos and go to the URL mapping section to get a comprehensive step by step guide. Focus on your best pages.
Naghirniac, rather than searching pages indexed by google, it would be better to use a site crawler like Xenu or screaming frog as it will find all duplicate and 404 pages for you.
Good luck,
V
-
Ian,
You will need to do the follow:
1) Search pages indexed by google
You will need to do the 301 redirection only for the pages that google already indexed. To discovery then you need to google "site:www.example.com", where example.com is your website
2) Create the .htaccess file
Inside of the .htaccess file you will need to include:
RewriteEngine On RewriteCond %{HTTP_HOST} ^example.com RewriteRule (.*) http://www.example.com/$1 [R=301,L]
redirect 301 /old.html http://www.example.com/new.html
The first part is to avoid duplicated content from www.example.com and example.com. The line redirect 301 you will need to write for each page you need a redirection (founded at step 1). That's all.
-
redirect the pages in the .htaccess file.
rather than redirect them all to the homepage, you should redirect them to the most relevant page on the other site.
why are you getting rid of one site?
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Should I keep a website which is outdated or close it down? It has a few links. If I keep it can I redirect people to our newer site?
We are in the process of buying some intellectual property, and it's websites are very dated and only have around 5 external links each. What's the best course of action? Do we close down the sites; then redirect the urls to our current website, or do we leave the sites up, but redirect people to our new site. Reference: current website: www.psychometrics.com Old sites that come with the intellectual property: http://www.eri.com/ plus http://www.hrpq.com/ Thanks, Dan Costigan
Technical SEO | | dcostigan0 -
How best to fix 301 redirect problems
Hi all Wondering if anyone could help out with this one. Roger Bot crawler has just performed it's weekly error crawl on my site and I appear to have 18,613 temp redirect problems!! Rather, the same 1 problem 18,613 times. My site is a magento store and the errors it is giving me is due to the wishlist feature on the site. For example, it is trying to crawl links such as index.php/wishlist/index/add/product/29416/form_key/DBDSNAJOfP2YGgfW (which would normally add the item to one's wishlist). However, because Roger isn't logged into the website it means that all these requests are being sent to the login url with the page title of Please Enable Cookies. Would the best way to fix this be to enable wishlists for guests? I would rather not do that but cannot think of another way of fixing it. Any other Magento people come across this issue? Thanks, Carl
Technical SEO | | daedriccarl0 -
We have set up 301 redirects for pages from an old domain, but they aren't working and we are having duplicate content problems - Can you help?
We have several old domains. One is http://www.ccisound.com - Our "real" site is http://www.ccisolutions.com The 301 redirect from the old domain to the new domain works. However, the 301-redirects for interior pages, like: http://www.ccisolund.com/StoreFront/category/cd-duplicators do not work. This URL should redirect to http://www.ccisolutions.com/StoreFront/category/cd-duplicators but as you can see it does not. Our IT director supplied me with this code from the HT Access file in hopes that someone can help point us in the right direction and suggest how we might fix the problem: RewriteCond%{HTTP_HOST} ccisound.com$ [NC] RewriteRule^(.*)$ http://www.ccisolutions.com/$1 [R=301,L] Any ideas on why the 301 redirect isn't happening? Thanks all!
Technical SEO | | danatanseo0 -
Just noindexed and redirected junk from my site. Now what?
Hi to all! I've just finished 301 redirecting some pages and "noindex - follow" some other. I have to add a lot of canonicals yet, but this is a start. Now how I check the results? Should I wait a week or so to see if something improves? How long does it takes for Google to remove the pages I've just redirected and noindexed? My site is crawled every day (as all sites I guess). Thanks!
Technical SEO | | enriquef0 -
Best Strategy to Rank Wordpress Category
Does anyone some suggestions for best practices when trying to rank categories using Wordpress? Unless you filter it, a category provides a complete list of all posts in that category. I can add a good title and description but am not sure beyond that. Has anyone tried using a sticky post in the category and putting keyword body text in that? Lookin' for ideas.
Technical SEO | | waynekolenchuk1 -
Is it worth setting up 301 redirects from old products to new products?
This year we are using a new supplier and they have provided us a product database of approx. 5k products. About 80% of these products were in our existing database but once we have installed the new database all the URLs will have changed. There is no quick way to match the old products with the new products so we would have to manually match all 5k products if we were were to setup 301 rules for the old products pointing to the new products. Of course this would take a lot of time. So the options are: 1. Is it worth putting in this effort to make the 301 rules? 2. Or are we okay just to delete the old product pages, let the SE see the 404 and just wait for it to index the new pages? 3. Or, as a compromise, should we 301 the old product page to the new category page as this is a lot quicker for us do do than redirecting to the new product page?
Technical SEO | | indigoclothing0 -
Old proudct pages - eComm Site
Hello, Geeks.com currently has approx. 194k pages in Google index. (approx. 30k suppl.) http://www.google.com/search?q=site%3Ageeks.com+inurl%3Aadditem&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a#sclient=psy&hl=en&client=firefox-a&hs=Ltp&rls=org.mozilla:en-US%3Aofficial&source=hp&q=site:www.geeks.com%2F&aq=f&aqi=&aql=&oq=&pbx=1&fp=876898a2ea0c82c7&biw=1512&bih=641 We have many thousands of old product urls which have gone out of stock, never to "see the light of day" again. 14 years worth! Should we be 301'ing all old products pages that go out of stock, if we know for certain we will never carry that SKU again? If we were to do a "mass" 301 of 30k+ urls how would google or other SE's react to that? Could there be any negative implications to doing so? What is considered best practice for eComm sites, as I imagine we are not alone with this type of situation. Thank you in advance. Michael B.
Technical SEO | | JustinGeeks0 -
How to Redirect only specific pages to new domain
My HTACCESS FILE IS AS FOLLOWS: rewriteengine on
Technical SEO | | askthetrainer
rewritecond %{HTTP_HOST} ^mydomain.com$
rewriterule ^mydomain/(.*)$ "http://www.mydomain.com/$1" [R=301,L] #4d864805b49b5 I want to move ONLY specific pages from this domain to a new domain How do I edit my HTACCESS (which redirects http:// to www.) to move specific pages from old domain (which I have to delete) to new domain.... I.e. http://mydomaon.com/move.html needs to move to http://mynewdomain.com/move.html Where i can delete the original domains0