A URL redirect forwards a user to a different URL than the one they were trying to access. This is important for new websites because some of the URLs on old websites may change on the new website.
IMPORTANT
Only users with the Site Admin role can manage redirects.
When to Use Redirects
- New websites: A URL redirect will point users to the new URL if they happen to try and access the old URL. For example, a URL on an old website such as, http://www.duke.edu/about-us/contact, may change to http://www.duke.edu/contact on the new website. This is especially important for high-traffic pages or URLs specifically referenced in any marketing materials.
- Shorter URLs: Let's say you want to advertise or market a page on your site, but the URL on your site is really long. You can come up with a short URL for your marketing material that will be easy for users to remember and then create a URL redirect to the correct page.
- Incorrect URLs: If an incorrect URL was sent to your users, for example in a marketing campaign, then you can create a URL redirect to point to the correct URL. In case anyone tries to use the incorrect URL, they will be forwarded to the correct URL.
View Existing Redirects
- In the content administration menu, go to Configuration > Search and metadata > URL redirects.
Redirects to avoid
Do not redirect any of your enabled List Page URLs (e.g., /news, /events, or other custom URL aliases you may have created). Redirecting these system-generated pages may cause errors on your site.
Create a Redirect
while editing a piece of content
After you create and save any type of content on your site, there will be a URL redirects option available.
(* = required field)
1. Find the content item you want to add a redirect to.
2. Open the URL redirects expand/collapse section and click Add URL redirect.
3. A new browser window will open. Enter the following information.
- Redirect status: The status should most often be 301 Moved Permanently. For information about what each redirect status means, visit https://en.wikipedia.org/wiki/List_of_HTTP_status_codes#3xx_Redirection.
- Path*: Enter the old URL path that you want to be redirected. Only enter the part of the URL after the ".edu/" – for example, "your-page" instead of "https://yoursite.duke.edu/your-page."
- URL paths are not case sensitive – e.g., "About" and "about" will work the same
- To*: Leave this as is because it is the path of the content item that you want users to get redirected to from the old URL you entered into the Path field.
- Be sure to Save your redirect.
from the "aDD url redirect" screen
- There are two ways to reach this screen:
- In the content administration menu, visit Configuration > Search and metadata > URL redirects. Click the Add redirect button.
- Visit Configuration > Search and metadata > URL redirects > Add redirect (at URL path /admin/config/search/redirect/add).
- Fill out the fields as follows:
- Redirect status: The status should most often be 301 Moved Permanently.
- Path*: Enter the old URL path that you want to be redirected. Only enter the part of the URL after the ".edu/" – for example, "undergraduate-program" instead of "https://sanford.duke.edu/undergraduate-program."
- To*: Use this field to search for and select the content you would like users redirected to. When you click the desired content's title, this field will auto-populate with a URL path like "/node/123." Do not edit this path.
- If you are redirecting users to an external URL (i.e., a page on a completely different website), do not use the auto-select feature and instead type the full external URL (e.g., https://duke.edu).
- Be sure to Save your redirect.
Complex Redirects
If more complex redirects are desired, please contact the Sites@Duke Pro team.