[SalesForce] Custom URL in Salesforce Communities

I need to configure a Salesforce Community to display a customer URL, ie portal.[DOMAIN].com instead of the standard [DOMAIN].force.com/

The following KB from Salesforce doesn't seem to work

We've got the cert installed and everything seems to be setup correctly in Salesforce.

I've done this before but it only comes up every 18 mos or so. Whatever I learned last time (and didn't write down), is forgotten.

Appreciate any help.

Best Answer

I do not know how did you setup. But recently, I setup this and documented everything. Just follow this, you should be able to set it up.

Custom Domain Masking of Salesforce Communities

Prerequisites & Assumptions

  • Assuming your company domain is: www.mycompany.com. Your custom community domain that you want to mask with is: customer.mycompany.com (customer.mycompany.com is equivalent to https://customer.mycompany.com)
  • Your Salesforce generated community domain that is going to be masked is: https://mycompany.force.com/customer/.
  • All sites are secure means we do have security certificate for our custom domain.
  • You have salesforce administration permission.

Steps to setup the masking

Prepare Host-name for CNAME configuration from Salesforce:

  • Get Salesforce 18 digits organization id. You can get that easily by running query in developer console (Your Name → Developer Console → Query Editor) SELECT Id from Organization
  • Copy the Id and update it in lowercase. For example if it was received as 00D000000000052DNA then make it to 00d000000000052dna
  • Now host name will be based on this formula: .<18 digits Salesforce internal org id in lowercase>.live.siteforce.com

    customer.mycompany.com.00d000000000052dna.live.siteforce.com

Create a CNAME entry in your DNS

  • Ask your DNS provider to create a new CNAME with target prepared in last step. It may take 24-48 hours to activate after adding it. Until it's configured, you can not perform further steps.

Add the domain information to your Salesforce Org

Once CNAME propagation in DNS is completed, we can add this new custom domain in salesforce.

  1. In your Salesforce Org, click Setup.

  2. Under "Administer," Click Domain Management | click Domains.

  3. Click Add A Domain.

  4. Enter your custom domain in the Domain Name field.

Map the Custom Domain to your Community

  1. In your Salesforce Org, click on Setup.

  2. Under "Administration," click Domain Management | then click Domains.

  3. Click on the domain that you added.
  4. Click New Custom URL.
    • You should be redirected to the Custom URL Edit screen.
    • Select here your community site and Keep path as it is.

Add HTTPS support to custom domains:

In above given 4 steps, we’ve completed domain masking successfully. But if you want your community to run over secure layer (HTTPS) then you’ve to add certificate as below:

  1. Create a Certificate Authority (CA) Signed Certificate

    1. Click Setup.
    2. Under "Administer," click Security Controls | then click Certificate and Key Management.
    3. Click Create CA-Signed Certificate as mentioned at bottom in this article: https://help.salesforce.com/articleView?id=000205653&type=1&language=en_US
  2. After creating the certificate, click Download Certificate Signing Request. -After the certificate downloads, you'll need to send it to a CA of your choice.

    • After you get the certificate back

      1. Click Setup.
      2. Under "Administer," click Security Controls | then click Certificate and Key Management.
      3. Click the name of the certificate, then click Upload Signed Certificate.
      4. Click Browse to locate the CAsigned certificate. The CA-signed certificate must match the certificate created in Salesforce.
        • If you upload the wrong CA signed certificate, the upload will fail.
      5. Click Save.

After you successfully upload the signed certificate, the status of the certificate will change to Active.

After you've uploaded your CA signed certificate, go back to "Domains" and enter your domain into the Domain Name field. Click the lookup icon next to Certificate and Key, and you'll be able to select your newly uploaded CA signed certificate.

Source Articles https://help.salesforce.com/articleView?id=000205653&type=1&language=en_US