Solved

IIS REdirect or webconfig ?

Posted on 2013-06-20
4
651 Views
Last Modified: 2013-06-24
Hello,

I was hoping for a little advice.  We are currently in the middle of a rebrand and will shortly introduce a new URL.  We'll be copying over our current content so it will be exactly the same website under a new URL.

What I was hoping was that someone might be able to advise on is what method of 301 redirect I should be using.    I have read that using page to page redirects is the best method to maintain our Google rankings (we are more or less the first result on a Google search of our key words) and we want to carry over that ranking.

So should I do this with the web.config file to get this 1:1 page match,   or is an IIS domain level redirect suitable or......

many thanks in advance for any replies.
0
Comment
Question by:citymarketing
  • 2
4 Comments
 
LVL 19

Expert Comment

by:Patricksr1972
ID: 39262976
Hi.,

Quickest and easiest way is to have your old website URL include a index.html with following code

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<meta http-equiv="refresh" content="0;URL=http://www.mynewurl.com" />
<title></title>

</head>
<body>

</body>
</html>
0
 
LVL 23

Expert Comment

by:Tiggerito
ID: 39265279
@Patricksr1972, The question is about 301 redirects and not meta refresh redirects.

If you are just changing domain and all the page paths are the same then you can do a site wide redirect. But if pages are moving you will have to do each one separately.

web.config is the simplest way to set them up. If you have 100s to do you may find web.config is slow and hard to maintain. Then you will be looking into custom code using the Routing module to handle your redirects.
0
 

Author Comment

by:citymarketing
ID: 39265506
Thanks for your reply tiggerito
We are just changing domain, as you say page paths will be the same.  So perhaps a domain level redirect will suffice.   However,  Google seems to discourage blanket redirects and suggest creating page:page redirects to make the link between old and new domains and maintain page ranking.  We do have several hundred pages and so web.config as you say might be too slow, in fact it would.

We just wanna keep our first returned result page rank on Google and keep our app functioning which runs off our primary domain !
0
 
LVL 23

Accepted Solution

by:
Tiggerito earned 500 total points
ID: 39267542
For the domain level redirect you want to make sure it does do page to page. By domain level we are saying you create one domain wide command to do all the redirects.

Google does not like you redirecting every old page to a home page, and that's the mistake a lot of people make when setting up a site wide redirect.

You can do a site wide command in web.config or set up the site wide redirects in IIS. Just make sure it does do page to page and is a 301.

This may work:

<rule name="site wide redirect, page to page">
  <match url=".+" />
  <conditions>
    <add input="{HTTP_HOST}" pattern="^www\.old-domain\.com$" />                    
  </conditions>
  <action type="Redirect" url="http://www.new-domain.com/{R:0}" />
</rule>
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

If you don't have the right permissions set for your WordPress location in IIS, you won't be able to perform automatic updates. Here's how to fix the problem.
Wondering how you can get your new website ranking on Google Search so that people find you online?  The answer is Search Engine Optimization (SEO). So how do you Start Ranking a New site with SEO?  Below is a starter guide to get your new website S…
This tutorial walks through the best practices in adding a local business to Google Maps including how to properly search for duplicates, marker placement, and inputing business details. Login to your Google Account, then search for "Google Mapmaker…
This Micro Tutorial will demonstrate how to add subdomains to your content reports. This can be very importing in having a site with multiple subdomains.

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now