Creating a redirect
The content team can create redirects without help from a developer. You’ll need the URL of the:
- Page you’re replacing
- Page you’re creating (which you’ll set in WordPress using the URL Slug field in the Document tab of the right menu)
Before you make a redirect, check these things first:
- Is the page in the site navigation menu? If so, update the WordPress fragment titled Menu Links by either:
- Changing the link to go to the new URL
- Removing the row that contains the link to the page that’s being redirected
- Is anywhere on our site linking to this URL? Search engines prefer that as few redirects as possible as used. Update the URL of these hyperlinks or remove them prior to putting a redirect in place.
- Are there any anchor links on the page you need to account for?
Once that’s done:
- Open the Page Redirect Table WordPress post.
- Create a new row at the bottom of the table.
- In the original_url column, enter the slug for the page you want to redirect.
a. Include forward slashes at the beginning and end of the slug (for example: /safer-economy/). The redirect will not work if the slashes are not included.
- In the replacement_url column, enter the URL or the slug for the page you want to send people to when they visit that URL.
a. Include forward slashes at the beginning and end of any slug you use here too.
- Leave the Header label column blank.
- If the URL you added to original_url is a page that gets translated, add a new row for each translated version.
a. If you’re pointing to a page on our site that gets translated, make your replacement_url the corresponding translated version of our site.
- Search the list for any instances of the URL you’ve added to the original_url column.
a. This prevents double redirects, which search engines do not like.
- Update the page to begin redirecting.