301 redirecting some pages directly, and the rest to a single page
-
I've read through the Redirect guide here already but can't get this down in my .htaccess
I want to redirect some pages specifically (/contactinfo.html to the new /contact.php)
And I want all other pages (not all have equivalent pages on the new site) to redirect to my new (index.php) homepage.
How can I set it up so that some specific pages redirect directly, and all others go to one page?
I already have the specific oldpage.html -> newpage.php redirects in place, just need to figure out the broad one for everything else.
-
also, keep in mind that if you are ranking on secondary terms on the non-front pages, you will lose a lot of that relevance by forwarding to only your home page (esp. if it's not about that specific thing.
example:
old site about fruit on home page - old subpage about applesthe old subpage about apples may rank really well
next, you forward the old subpage about apples to your new front page
the search engines go "oh, this page isn't as relevant as the old apples subpage that no longer exists, let's bump down the rankings"hence, it's always best to forward your equivalent old content to your equivalent new content.
-
hi -
how many pages are we talking here?check with your website host. many of of them have redirect utilities (such as isapi_rewrite : http://www.isapirewrite.com/) installed on the server (or just "rewrite" for apache i think) that will allow you to add a set of rules to your .htacess so it filters the way you want every time someone hits an old page. you would need 2 rules:
1.) when site is contactinfo.html --> contact.php
2.) when all others ---> send to index.phpi would highly advise forwarding more relevant pages to their new equivalents if they are available. doing it the way you've mentioned will send link juice to index.php, but you may run into relevance issues.
isapi_rewrite is a little complicated in terms of it's syntax rules, but they've got a pretty useful forum. additionally, sometimes website hosts have a pro that can help you if you can't figure it out.
hope that's of some help! :>)
dan
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
-
Redirecting a single page on a separate domain to a new site?
My client started a subdivision of their company, along with a new website. There was already an individual page about the new product/topic on the main site, but recognizing a growth area they wanted to devote an entire site to the product/topic. Can we/should we redirect that page on the old corporate/main site to the new domain, or just place a link or two? Thoughts?
Technical SEO | | VTDesignWorks0 -
Where is the 301 redirect?
Hi, in the last week I take an issue for 301 permanent redirect for a subfolder in the main website! In that folder i have a index.php file for a google map fullscreen edition and the only link who connects the wordpress website with the subfolder is only a direct link! Is that an error of seomoz app or something else? Thanks 1.jpg
Technical SEO | | petrospan0 -
301 re-directs to similar content, good idea?
We need to remove about 50 articles from our site, and we can find similar content to re-direct these to. Would it be a good or bad idea to re-direct this content? Or should we just 404 it? Should a 301 re-direct always be an exact match?
Technical SEO | | nicole.healthline0 -
301 redirects
At the moment it's possible to access the home page of my website via two different urls, with and without www. and you've told me that this can be resolved with Canonicalization and a 301 redirect. Do I do this with my web hosting package or in my html pages? If I can't do it with my web host (1&1) then is there an idiot's guide of how to do it yourself? I've also got both the domain vamospaella.co.uk and vamospaella.com. Is it better to have one of these redirecting to the other for UK traffic (at the moment .co.uk redirects to .com) Thanks
Technical SEO | | melissa10 -
Is it better to delete web pages that I don't want anymore or should I 301 redirect all of the pages I delete to the homepage or another live page?
Is it better for SEO to delete web pages that I don't want anymore or should I 301 redirect all of the pages I delete to the homepage or another live page?
Technical SEO | | CustomOnlineMarketing0 -
301 Redirect
Need a little bit of help on this one. I have a product page which actually has 3 products on the page in question: www.example.com/products I thought it would be best for each product to have a page on its own: www.example.com/product-1 www.example.com/product-2 www.example.com/product-3 however my question is: The page with the 3 products www.example.com/products where should the 301 go to? Can you do a 301 to all the new product pages? Hope that makes sense Kind Regards,
Technical SEO | | Paul780 -
301 Redirect
Hi there, We are re-branding & re-structuring our website, there will be quite a number of 301 re-directs, possibly hundreds. The question is: Should i wait until the re-branding has been completed and do al the 301's in one go?, or should I try and do 301's as i go along? Kind Regards
Technical SEO | | Paul780 -
301 Redirect?
Sometimes I want to redirect pages on my site. Like a search result: http://www.inthelighturns.com/memorials/catalogsearch/result/?q=hearts to a page designed for what they're searching for: http://www.inthelighturns.com/hearts.html There's no real worry about transferring page rank and this may not be a permanent redirect. Just a "I want this page to show this page for some time" kind of redirect. What's the best solution? Thanks Tyler
Technical SEO | | tylerfraser0