Drupal URL Redirects

URL redirects are used when content on your web site is moved from one location to another. If the original URL has been published for a while then visitors and search engines may have bookmarked the page and continue to try to access it at the original URL even though the page has moved to a new URL. This causes a 404 Page Not Found error which is detrimental to site visitor experience and search engine ranking. When a web site redesign is performed the old URLs will probably not match the new URLs. It is very important to map the old URLs to the new URLs, if the content has predominantly remained the same, to maintain search engine ranking.

Creating a URL redirect<

  1. Login to the site using an administrative account
  2. Navigate to Site Building > URL Redirects > Add Redirect
  3. In the From field type in the relative path of the old link. If our original link is http://www.codamoda.com/this-page-is-not-here then we would only type in this-page-is-not-here.
  4. The To field is a little more complicated. Drupal uses System paths such as http://www.codamoda.com/node/126 and can also use Friendly paths such as http://www.codamoda.com/the-new-page. It is always best to use the System path. To find the System path:
    1. Open the new URL in a new browser window.
    2. If you see an Edit button click on it
    3. The current URL should now look like http://www.codamoda.com/node/126/edit.
    4. We remove the domain name http://www.codamoda.com/ and /edit from the URL to get the system path. In this case it would be node/126.
    5. So we type in node/126 into the To field.
    6. If you do not see an Edit button then we use the relative path. For example if our URL is http://www.codamoda.com/the-new-page then we remove the domain name http://www.codamoda.com/ and we are left with the-new-page so we enter that into the To field.
  5. By default the Advanced options sets the redirect type to 301 Moved Permanently which is appropriate for most cases. Do not change this.
  6. Click the Save button
  7. We can now test the redirect by opening the old URL
    > http://www.codamoda.com/this-page-is-not-here.
    It should automatically change to
    > http://www.codamoda.com/the-new-page.

Add your comment

The content of this field is kept private and will not be shown publicly. If you have a Gravatar account associated with the e-mail address you provide, it will be used to display your avatar.
  .dESM9b.    .d@9SSb.    .d@9SSb.   @@SES@SM55   .dESM9b.  
d8EP Y5Hb dS5P Y8Eb dS5P Y8Eb dS@P d8EP Y5Hb
YEMb. d98P H95 S85 H95 S85 dESP YEMb. d98P
"YMMHMS" Y98b. d8EE Y98b. d8EE d@HP "YMMHMS"
.d@P""YSb. "YE95P95E "YE95P95E 9SE5EE55 .d@P""YSb.
859 HHH EH5 EH5 d99P 859 HHH
Y@8b d85P YSHb dHSP YSHb dHSP d59P Y@8b d85P
"YH8@5P" "Y@55HP" "Y@55HP" dEMP "YH8@5P"