301 Redirects in IIS and Unix
I just had the pleasure of helping a friend change their domain name. From the outside, it looked as if I could write some simple rewrite rules, capture all the link juice and pass it via a 301 redirect to their new domain. But then I learned that the site was being hosted on Microsoft servers and that I would have to use IIS for the rewrite.
IIS is crap. On the other hand, UNIX is a mature, superior operating system with a proven track record for oh-so-important qualities such as reliability, performance and security. Web 2.0 is nothing new - collaborative creation started with the Unix operating system years ago. It continues to get better as more people contribute.
Ok maybe I’m showing some bias here. I’ll explain. IIS is crap in this instance because it is impossible to make a full page-to-page site redirect unless the web pages are dynamic. In other words, if you have a flat, html site, you have to redirect all pages to the home page of the new domain. That is sub-optimal at best.
So I moved the hosting to a Unix environment. I wrote 6 lines of code in the .htaccess file and redirected the entire old domain to the corresponding pages on the new domain within minutes. Sweet sweetness indeed. I passed all link juice and all rankings were maintained. Google didn’t miss a beat.
Sphere It
October 24th, 2007 at 4:33 am
I do most of my stuff in Coldfusion and I don’t do that much with html pages, however I pretty certain a simple meta refresh on each page will do the trick.
October 24th, 2007 at 3:10 pm
A meta refresh is like putting on a spare, a ‘weenie-wheel’, when you have a flat tire. Not a solid, long term solution. Would it prevent 404’s? Yes. Would it pass link juice? Nope. http://www.seobook.com/archives/000297.shtml
October 24th, 2007 at 3:21 pm
I’m no SEO genius, but I think Slim is right. 301 is the professional way to do it. Meta-refresh was cool, in like ‘98.
November 2nd, 2007 at 5:45 pm
Apache is a great server if you know how to use it. The same goes for IIS. With an ISAPI rewrite tool, you could do the same thing that you did but on IIS. Apache has the benefit of already having that functionality available though.
Glad it worked out.
November 2nd, 2007 at 6:13 pm
Good point Uncool. Having the right tools at the right time is a great benefit. With the right tools (and enough time) anything can be done!
January 10th, 2008 at 4:18 am
Slim, slim, slim. You know I can do anything with IIS?! Isapi_ReWrite is free in the basic version and you can set up host conditions so that all requests to a specific domain are 301 redirected to the same url on a differnt url. In fact, you can even use domain patterns. On perfectweddingguide.com, for example, pwg.com does just this. http://www.pwg.com/atlanta
Of course, you need access to install the isapi_filter. There are two ways to do it: msi installer (if you can log onto the box) or configure an isapi extension (if you can administer IIS).
The fact that Apache has this built in is just testiment to the fact that Unix people make more mistakes and often realize they need to redirect shit.
Now, Vista SUCKS! I am one more OS crash away from buying a macBook so that I can have a god out of the box Windows experience
January 10th, 2008 at 1:43 pm
Yes, Rusty, you could probably lasso a steer and make it sing ‘Baby Got Back’ with IIS, but the rest of us aren’t that talented. In a hosted environment (in this instance with Bluehost), IIS administration is limited and the isapi filter only requires more steps. More steps=more time.
And if you do get that Mac Leopard OS (running on Unix), I don’t know if if will be ‘god out of the box’, but it sure beats Windows.
February 5th, 2008 at 10:35 am
What’s wrong with a basic IIS redirect set to the whole domain that maps to the new domain?
Within IIS manager, set the redirect target to:
http://newdomain.comv
and the $v parameter will pass all of the url request from teh old domain to the new one - seamless :o)
February 7th, 2008 at 12:39 pm
My question would be whether that is something that could be done via a standard web hosting package (with limited permissions). It very well could work - I’ll never know