Loading
Salesforce now sends email only from verified domains. Read More
Extend Salesforce with Clicks, Not Code
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
          Add a Custom URL

          Add a Custom URL

          To specify the site to load when users access your custom domain, add a custom URL. Optionally, you can define additional relationships between your domains and sites by mapping paths for your domain to your sites.

          Required Editions

          Available in: both Salesforce Classic and Lightning Experience
          Available in: Enterprise, Performance, and Unlimited Editions.
          Applies to: Salesforce Sites and LWR, Aura, and Visualforce sites
          User Permissions Needed
          To view custom URLs:

          Manage Custom Domains

          OR

          View Setup and Configuration

          To add, edit, and delete custom URLs:

          Manage Custom Domains

          OR

          View Setup and Configuration AND either Create and Set Up Experiences OR a Site.com Publisher license

          Before you can add a custom URL, set up your custom domain in Salesforce.

          A custom URL consists of a domain, a custom path prefix, and a unique site path. For a domain to serve an Experience Cloud site or Salesforce Site, at least one custom URL is required.

          In the Custom URLs table, even though the domain name and path are in separate columns, the URLs consist of the combination of the two.

          1. If the custom domain serves a LWR site, associate the domain with a Commerce LWR site or with an LWR site that's hosted on Experience Delivery.
          2. From Setup, in the Quick Find box, enter Custom URLs, and then select Custom URLs.
          3. Select New Custom URL.
          4. Select a domain.
            1. Enter the name of the domain, or leave the field blank to get a full list of your domains.
            2. Click the lookup icon (The lookup icon), and then select the name of the domain in the search results.
          5. Select a site.
            1. Enter the name of the site, or leave the field blank to get a full list of your sites.
            2. Click The lookup icon, and then click the name of the site in the search results.

            Each domain can serve up to 200 sites, and each site can be associated with up to 500 domains. An Experience Cloud site counts as two sites, so if you use only Experience Cloud sites, each domain can serve 100 sites.

            Note
            Note If you’re using a custom domain that has enabled the Salesforce CDN, then the first site you associate it with has to be either a Commerce LWR site or a site hosted on Experience Delivery.
          6. Enter a unique path.

            To specify the root path, such as https://www.example.com, enter a slash (/).

            The first character of the path must be a slash (/) to indicate the root. You can extend the path after the slash. For example, if you select the domain, www.example.com, and then enter /products as the path, the resulting custom URL that serves your selected site is https://www.example.com/products.

            You can use the same path for more than one domain, but you can use each path only one time within the same domain.

            Salesforce reserves some path names, such as /home, /flash, /img, /servlet, and /sfdc. If you enter a reserved path value, you see an error. In that case, use another relevant prefix to suit your business needs.

            Note
            Note

            If you host multiple sites on the same domain, review your site URLs for conflicts because it’s possible to configure the same URL for pages on two different sites.

            Let’s say that you host Site A and Site B on the same domain, www.example.com. Site A’s URL uses the custom URL path prefix /products. Site B serves pages from the root path and has a page with the page path /products. As a result, both Site A’s URL and Site B’s page URL are https://www.example.com/products.

            In this scenario, a site visitor can access the Site B page only through a navigation menu on Site B. If a site visitor navigates to https://example.com/products any other way, they’re directed to Site A.

            If you identify a potential conflict, either rename the site path or choose a different path for serving the content on your custom domain.

          7. To set this custom URL as the preferred URL for authenticated pages and email, select Site Primary Custom URL.

            This option is available for the root path for Experience Clouds sites and Salesforce Sites, but not for legacy Site.com sites.

            Each site can have only one primary custom URL. If you enable this setting on more than one URL that serves the same site, the last custom URL saved with that setting is used for authenticated pages and email.

            For Experience Cloud sites and Salesforce Sites, if you don’t select a primary URL, the first HTTPS custom URL in the site, determined alphabetically, is used for authenticated pages and email. If no custom URL uses HTTPS, your system-managed site domain is used. The system-managed domain format for Experience Cloud sites is MyDomainName.my.site.com in orgs with enhanced domains and ExperienceCloudSitesSubdomain.force.com in orgs without enhanced domains. The system-managed domain format for Salesforce Sites is MyDomainName.my.salesforce-sites.com in orgs with enhanced domains and SalesforceSitesSubdomain.force.com in orgs without enhanced domains.

          8. Save your changes.

            If your domain uses your HTTPS certificate on Salesforce servers, saving the first custom URL added to the domain starts the provisioning process for the domain. After the provisioning process is complete, the domain’s status on the Domains Setup page changes to Awaiting Activation, and you receive an email. To activate your domain, on the Domains Setup page, click Activate next to your custom domain name.

            If your custom domain uses another domain configuration option and the domain is active, the path is publicly available.

          Example
          Example

          In this example, we want to serve two Experience Cloud sites via our custom domain. The system-managed URL for the site named Storefront is https://MyDomainName.my.site.com/store, and the URL for the site named Jobs is https://MyDomainName.my.site.com/joblisting. We add the www.example.com domain in Salesforce, and then we add two custom URLs.

          To drive users to the Storefront site, we create a custom URL for the root path of the domain.

          • For domain, we select our active domain, www.example.com.
          • For site, we select Storefront.
          • For path, we enter /.

          When we save this custom URL, users who visit https://www.example.com see the content from https://MyDomainName.my.site.com/store, but the address bar in their browser shows https://www.example.com.

          So users can apply for positions within the company, we create a custom URL for the Jobs site.

          • For domain, we select our active domain, www.example.com.
          • For site, we select Jobs.
          • For path, we enter /apply.

          When we save this custom URL, users who visit https://www.example.com/apply see the content from https://MyDomainName.my.site.com/joblistings, but the address bar in their browser shows https://www.example.com/apply.

           
          Loading
          Salesforce Help | Article