Custom Software Apps & SharePoint Consulting

How to Create User-Friendly Redirects in SharePoint Online

If you ever need to establish permanent redirects in SharePoint Online, there are several ways to go about it, but only one that produces a clean user experience.

This came up recently with a client who had a home site collection and a marketing site collection. We wanted to make sure that when user navigated to the home site collection, they automatically ended up in the marketing site collection. If both sites were in the same collection, it would be as easy as making the home page of the marketing site the home page for the entire collection. Since they weren’t in the same collection, we had to approach it from a different angle.

SharePoint provides a redirect page as part of the Publishing Feature, but this method has a 5 second delay on it, which is far too long. You could also use JavaScript in a Content Editor Web Part to set the window location to the new URL. This happens almost immediately when the page is accessed, but you still get the unpleasant loading of some elements from one site before the screen goes white and the elements from the new site are loaded.

The best way to go about creating redirects in SharePoint Online is actually not much more work:

  1. Load up SharePoint Designer and create a new aspx page in the Site Pages folder for the source site. Edit it in advanced mode.
  2. Add the following tag under thetag:
  3. Replace “Destination URL” with the URL that you want to redirect to.
  4. The ‘0’ (that’s a zero) indicates no delay before loading the new URL.
  5. Note that you have to set this page as the home page for the site in Designer, since you can’t actually open it through the UI without being immediately redirected.

The result is that users visiting this page will be redirected before any of the page elements load, resulting in a very clean experience.

Share this post with your friends

Share on facebook
Share on reddit
Share on twitter
Share on linkedin
Skip to content