Loading
Set Up and Maintain Your Salesforce Organization
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          Test External Redirections

          Test External Redirections

          After you update your Trusted URLs for Redirects allowlist, verify that the corresponding redirections are allowed.

          Required Editions

          Available in: all editions

          To understand where and when Salesforce restricts redirections based on the Trusted URLs for Redirects allowlist, see External Redirection Restrictions in Salesforce

          Tip
          Tip If a redirection fails after you add the base URL to the Trusted URLs for Redirects allowlist, check the blocked URL string for malformation or other issues, such as a typo in the string.
          1. If you know the action or link that redirects users to an allowed URL, initiate the redirection from within Salesforce.
          2. To test multiple URLs in succession, you can test the redirection from your browser.
            1. Log in to Salesforce.
            2. In the browser address bar, delete the URL path: the characters after the first forward slash (/).
            3. Replace the path by entering this string: ?startURL=targetUrl.

            If the redirection is allowed, you’re redirected to targetUrl. If the redirection is blocked, you get an Invalid Page Redirection error.

            Here’s an example of an Invalid Page Redirection error.

            Invalid page redirection error
          Testing Example
          Testing Example

          To allow redirections from production to sites in your sandbox, you added https://mycompany--uat.sandbox.my.site.com to your Trusted URLs for Redirects allowlist in production. You also decided not to allow redirections from your production org to files in that sandbox, which are hosted on this URL: https://mycompany--uat.sandbox.file.force.com

          After you log in to your production org, the browser address bar contains this URL: https://mycompany.lightning.force.com/lightning/page/home.

          To test redirections to the allowed sandbox site URL, you delete lightning/page/home from the URL in the browser bar and replace it with ?startURL=https://mycompany--uat.sandbox.my.site.com. The new URL is https://mycompany.lightning.force.com/?startURL=https://mycompany--uat.sandbox.my.site.com. Because the target URL is on the allowlist, when you press Enter, you’re redirected to the sandbox site.

          To test redirections to the blocked sandbox content URL, you modify the URL in the browser address bar to https://mycompany.lightning.force.com/?startURL=https://mycompany--uat.sandbox.file.force.com. Because the target URL isn’t on the allowlist, when you hit Enter, you get an Invalid Page Redirection error.

           
          Loading
          Salesforce Help | Article