Loading
Ongoing maintenance for Salesforce HelpRead More
Identify Your Users and Manage Access
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
          Brand Your Identity Pages with Dynamic URLs

          Brand Your Identity Pages with Dynamic URLs

          With dynamic branding, you can customize the branding of your login experience depending on context, such as who the user is or where they're logging in from. For example, change which logo you display depending on whether the user is an employee or customer. Or display a particular self-registration page based on the user's country code.

          Your dynamic branding settings apply to the entire login experience, including the pages used to log in, verify identity, reset passwords, and self-register. You can add dynamic branding to Experience Builder, Visualforce, and custom login pages.

          Dynamic branding relies on a URL parameter called the experience ID, or expid value. The expid value determines what the user experiences. At run time, the expid value resolves to the current value, and the appropriate URL is created to determine what branding the user sees.

          Here’s a scenario. Universal Distributing wants to brand the login experience depending on whether the user is an employee or customer. You create logos for each brand, appropriately named employee_logo.png customer_logo.png. Then you set the logo URLs so that employees see http://.../employee_logo.png and customers see http://.../customer_logo.png.

          From the Administration Login & Registration page, you specify the logo URL with the expid value: https://universaldistributing.com/{expid}_logo.png.

          When a customer logs in, the expid value is set to customer, the URL becomes https://universaldistributing.com/customer_logo.png, and the customer logo appears on the login page. Likewise, when an employee logs in, the expid value is set to employee, the URL becomes https://universaldistributing.com/employee_logo.png, and the employee logo appears on the login page.

          You define dynamic branding URLs for logos and right-frames on the Experience Workspaces Administration Login & Registration page. They apply to default and custom login pages.

          In addition to setting the experience ID, your login implementation must set the login URL according to the value of the experience ID. For example, by adding the logic to your login button, when expid=EMPLOYEE, the login button directs the user to https://universaldistributing.com/brands/expid=EMPLOYEE.

          You can also use Visualforce and Apex to create dynamic URLs. Use the Apex getExperienceId method of the System.Site class to retrieve the value of the experience ID. To set the experience ID, use the setExperienceId method, or add an experience ID dynamic parameter to one of these login endpoints.

          For example, use the CommunitiesSelfReg endpoint to pass in a different {expid} value to the self-registration page to deliver a different registration flow for each brand.

          • Extend an Endpoint with the Experience ID
            You can set the experience ID value by extending supported endpoints.
          • Add Dynamic Branding to Custom Pages
            For custom pages used to log in, verify identity, reset passwords, and self-register, you can implement dynamic URLs with a custom login Apex controller. Use the Apex methods getExperienceId and setExperienceId of the System.Site class to retrieve and store the expid value.
          • Dynamic Branding for Multiple Brands
            Dynamic branding is ideal for multi-brand companies. You can create a single login page that determines which brand appears at run time. All brands are served from the same login page that serves the same site.
           
          Loading
          Salesforce Help | Article