Salesforce Sales Cloud and Marketing Cloud Integration

This document will guide you through the process of syncing your Salesforce Sales Cloud and SFMC accounts.

📘

Before you start with syncing, you need to install the Salesforce Sales Cloud package. Click here for more details.

Installation

It’s time to install the managed package. A managed package is a collection of components and applications that make the connection between your Salesforce Sales Cloud and Marketing Cloud accounts work. Follow along with these steps to download the latest version of the managed package.

  1. Make sure you are using the latest version of a supported web browser, and then click on one of these URLs.
  2. Sign in to your Salesforce Sales Cloud account using your admin credentials, and then click Install for Admins Only.
  3. Click Install. (If prompted, grant access to these third-party websites).
  4. Click Continue.

Note: Be sure to wait until the managed package installation is complete before moving on to the next step.

Configure Salesforce Sales Cloud Settings

Modify Page Layouts

In order to see email activity from within a Salesforce Sales Cloud account, we need to make some modifications to page layouts. This layout configuration is for Admins.

  1. Click on the gearbox, and then click on "Setup."
Setup
  1. Follow the path- Object Manager>> Search User >> User Page Layouts.
  2. Click on "Edit."
User Page Layouts
  1. Drag "Marketing Cloud for AppExchange Admin" and "Marketing Cloud for AppExchange User" from the palette to the Additional Information section of the user page layout.
Additional Information section
  1. Click "Save."

Modify Lead Page Layout

In order to have the details of all leads from your loyalty program, let's update the lead page layout.

  1. Click on the gearbox, and then click on "Setup."
  2. Follow the path- Object Manager>> Search Lead >> Page Layouts.
  3. Identify a page layout to work with and click Edit.
Page Layouts
  1. In the layout you selected, from the tool palette options, select Related Lists.
  2. Drag "Email Sends" from the palette to the bottom of the Lead Page layout to create a new related list.
Email Sends
  1. Then drag "Individual Email Results" from the palette to the bottom of the Lead Page layout to create another new related list.
Individual Email Results
  1. Next, select Visualforce Pages from the palette options, and drag and drop "LeadActions" to the description information section.
LeadActions
  1. Save it.
  2. Click "Yes" to Overwrite Users’ Related List Customizations?
Overwrite message

Modify Contact Page Layout

In order to have visibility to all emails sent to leads and contacts from Salesforce Sales Cloud, let's update the contact page layout.

  1. Click on the gearbox, and then click on "Setup."
  2. Follow the path- Object Manager>> Search Contact >> Page Layouts.
  3. Select a layout to update that only admins see. Once selected, click on Edit.
Page Layouts
  1. In the tool palette, select Related Lists. Drag Email Sends from the palette to the bottom of the Contact page layout to create a new related list.
Email Sends
  1. Drag Individual Email Results from the palette to the bottom of the Contact page layout, following Email Sends, to create another new related list.
Individual Email Results
  1. Click "Visualforce Pages" in the palette. Drag "ContactActions" from the palette to the Additional Information section of the Contact page.

ContactActions

  1. Click "Save."
  2. Click "Yes" to Overwrite Users’ Related List Customizations?

Grant Access to Your Marketing Cloud Connect Admin

In order to grant some permissions to your Marketing Cloud Connect admin (this can be you or another user), follow the given steps:

  1. Follow the path- Search "Users" in quick search>> Click Users.
  2. Click Edit next to the name of the admin user you’ve identified.
  3. Under Additional Information, select Marketing Cloud for AppExchange Admin and Marketing Cloud for AppExchange User.
Additional Information
  1. Click Save.

Note: If you don't see Marketing Cloud for AppExchange Admin and Marketing Cloud for AppExchange User follow these steps.

Set Up the Salesforce Sales Cloud API User

Create the Salesforce Sales Cloud API user (also called the Salesforce System user), which connects Salesforce Marketing Cloud to your Salesforce Sales Cloud.

  1. Follow the path- Search "Users" in quick search>> Click Users.
  2. Click on "New User."
New User
  1. Create a new user with the following settings:
  • First Name: John
  • Last Name: Doe-CRM
  • Email: Use an email address that you have access to.
  • Username: Must be unique and in the format of an email address. We suggest: [email protected]
  • User License: Salesforce
  • Profile: System Administrator
  • Role: Specify the role.

Note: There are limits to User Licenses, to check your license status, search "Company Information" in quick search and click.

  1. Under General Information, click the "Marketing User" checkbox.
  2. Under Additional Information, select the "Marketing Cloud for AppExchange Admin" and "Marketing Cloud for AppExchange User" checkboxes.
checkboxes
  1. Select the checkbox for "Generate new password and notify user immediately."
  2. Click on "Save."

📘

Important: An email will be sent to the address you specified. Follow the instructions in that email to verify the identity of the new user record and specify the password for this new user account.

Note: If you don't see Marketing Cloud for AppExchange Admin and Marketing Cloud for AppExchange User follow these steps.

Create Permission Set in Salesforce Sales Cloud

For the two systems to communicate properly, we need to create a generic permission set in Salesforce Sales Cloud and update Marketing Cloud connected app settings. This is required to grant access to Marketing Cloud users connecting to Salesforce Sales Cloud.

  1. Follow the path: Search "Users" in quick search>> Permission Sets.
  2. Click "New."
Permission Sets
  1. Enter permission set information. We suggest the label "Marketing Cloud Connected App" and a description that reads, "Gives access from Salesforce Sales Cloud to Marketing Cloud."
permission set information
  1. Click Save.
  2. Click "Manage Assignments" and then click "Add Assignments."
  3. Select the CRM API User account you created in the last section.
  4. Click Assign, and then Done.
manage assignment

Update Field-Level Security

The email opt-out field is standard on the Contact and Lead objects. For Marketing Cloud Connect to work properly, you need to ensure that all Marketing Cloud Connect users have view access to this field.

Leads Security

  1. Follow the path Object Manager>>Lead >> Fields & Relationships>> Email opt-out.
  2. Click on "Email opt-out" and then on "Set Field-Level Security."
Set Field-Level Security
  1. Check the "Visible" box for all user profiles, including the System Administrator profile, that need access to Marketing Cloud Connect.
  2. Add read-only restrictions based on your business requirements to any user profiles that should not be able to edit this value, such as the Partner Community User.

Visibility

  1. Click on the "Save" button.

Contacts Security

  1. Follow the path- Object Manager>>Contacts >> Fields & Relationships>> Email opt-out.
  2. Click on "Email opt-out" and then on "Set Field-Level Security."
Set Field-Level Security
  1. Check the "Visible" box for all user profiles, including the System Administrator profile, that need access to Marketing Cloud Connect.
  2. Add read-only restrictions based on your business requirements to any user profiles that should not be able to edit this value, such as the Partner Community User.
visibility
  1. Click on the "Save" button.

Configure Marketing Cloud

Marketing Cloud Connect API User

Just like Salesforce Sales Cloud, Marketing Cloud requires a user account for its connection to the Salesforce Sales Cloud environment. It’s a best practice to dedicate a user license solely for this purpose. Here’s how to set up your Marketing Cloud Connect API user.

Create a User

  1. In Marketing Cloud, hover over your username and select "Setup."
  2. From the Setup screen, type "Users" into the Quick Find box and click "Users."
  3. Click "Create."
Users
  1. Enter your email address for the Reply Email and Notification Email Address fields.
  2. Enter a unique username, for example, MC-API-User.
  3. Leave the External Key field blank, unless your organization requires it.
  4. Select a Time Zone and a Culture Code.
  5. Select an API user.
  6. Create a temporary password.
new users
  1. Click Save.

Manage Roles for Users

  1. From the Users screen, select the checkbox next to the user you just created.

Manage Roles for Users

  1. Click "Manage Roles."
  2. Click "Edit Roles."
  3. Assign the following roles:
    • Administrator
    • Marketing Cloud Administrator
manage roles
  1. Click Save.
  2. Log out of Marketing Cloud and immediately log back in with the Marketing Cloud Connect API User credentials you just created.

Configure the Marketing Cloud Connection

Once logged back into Marketing Cloud, navigate back to Setup. It’s time to connect your Marketing Cloud account to the corresponding Sales Cloud or Service Cloud org. Before you begin this process, be sure to log out of your Salesforce Sales Cloud account. (Closing the tab doesn’t log you out.) This prevents an incorrect connection, since the system automatically connects to any active Salesforce session.

  1. In Marketing Cloud Setup’s Quick Find field, type "Salesforce Integration."
  2. Once found, select Salesforce Integration.
  3. Click "Edit."
  4. Make sure "Scope by User" is deselected.
  5. Click "Connect Account."
Salesforce Integration
  1. Click OK to acknowledge the popup window.
  2. A login page displays in a new window. If you log in to Salesforce through a company-specific login page, select Use Custom Domain and enter the domain address before entering your user credentials. For example, if your org's login URL is https://example.my.salesforce.com, enter example.
  3. Enter the username and password for the CRM API user that you created in the last unit.
  1. Click Allow to grant access for the Marketing Cloud API User to access the Salesforce Sales Cloud org.

Note: You just created the handshake between Marketing Cloud and your Salesforce Sales Cloud org. That established a connected app relationship inside Salesforce Sales Cloud.

Finalize Configuration

It’s time to finalize the configuration of the connected app settings in Salesforce Sales Cloud. Log out of Marketing Cloud and log back in to your Salesforce Sales Cloud account with your personal admin credentials to make these next updates.

  1. In Setup, type "Connected Apps" in the Quick Find box and click "Connected Apps."
  2. Click "Salesforce Marketing Cloud."
Salesforce Marketing Cloud
  1. Click "Edit Policies."
  2. Under "Permitted Users", select Admin approved users are pre-authorized.
Permitted Users
  1. If a warning message appears, click OK.
  2. Under IP Relaxation, select Relax IP Restrictions.

configuration

  1. Under Refresh Token Policy, select "Immediately expire refresh token."
Refresh Token Policy

Pause for effect.

What did those steps do?

These two steps are needed for ease of use and authentication within connected applications.

Note: Check out Connected App IP Relaxation and OAuth 2.0 Asset help pages for detailed information about these steps.

  1. Click Save.
  2. Scroll down the page and click Manage Permission Sets.

Manage Permission Sets

  1. Choose the permission set for the Marketing Cloud Connected App that you made in the last unit.
  2. Click Save.

Complete the Managed Package Configuration

Next, stay in the Setup screen to finish the Managed Package configuration.

  1. Type "process automation" in the Quick Find box and select Process Automation Settings.
  2. If the Default Workflow User is empty, click the lookup icon and specify a user with System Administrator permissions to be the default workflow user. (We suggest using the newly created CRM API user account.)
Process Automation Settings
  1. Click "Save."

Note: This is an important step; skipping it prevents the managed package wizard from properly configuring workflow rules.

Session Settings

  1. Next, type "session settings" in the Quick Find box and click Session Settings.
  2. Scroll to the bottom of the page and click "Save."

Note: You don’t actually change any settings, but this is a necessary step for the configuration. If this step is not performed, the managed package wizard is not able to add IP allow listing.

Marketing Cloud Connector Setup Wizard

Now it’s time to connect your accounts using the setup wizard.

  1. From the top navigation, click the plus icon to navigate to the All Tabs screen.
  2. Click "Marketing Cloud."
  3. Click "Verify Remote Site" from the popup screen.
  4. Click "Okay" on the next popup about the MetadataAPI.
  5. Click "Start Wizard" to begin the setup wizard.
Marketing Cloud Connector Setup Wizard
  1. The next screen is a prompt for the Default Workflow User you created. Click Next.
  2. Click Next to move forward and acknowledge you’ve saved the session security settings.
  3. Click Next to acknowledge field-level security information.
  4. Click Done to acknowledge the page layout update information.
  5. At the main Marketing Cloud Connector Setup screen, select I agree to acknowledge the automated changes, and then click Configure Marketing Cloud Connector.
  6. If all goes well, you are rewarded with a configuration summary.
configuration summary
  1. Click "Okay" to finish the setup wizard.

Connect to Marketing Cloud Within Salesforce Sales Cloud

Next, it’s time to configure settings for the integration and make the connection in your Salesforce Sales Cloud account.

  1. Click the plus icon to navigate to the All Tabs screen.
  2. Click "Marketing Cloud."
  3. Click "Connect to Marketing Cloud."
  4. Enter the username and password for the "Marketing Cloud API User."
  5. Click "Login."
  6. If successful, you see a screen to configure Marketing Cloud Connect settings. Under the Account section on the page, select Email.
  7. In the Sends section, select all options.
  8. In the "Notifications" section, enter the appropriate email address to get error messages from Marketing Cloud Connect.
  9. In the Tracking section, select appropriate options for your organization about the specific email tracking data that Marketing Cloud sends to the Salesforce Sales Cloud system. Keep in mind that the choices you make for these can affect the overall storage of your Salesforce Sales Cloud org.
  10. Leave the defaults for the rest of the settings and finish by clicking Save Settings.
  11. Select at least one business unit from the Business Unit Management screen and click Save.

Marketing Cloud User Integration

With the connection established in the Salesforce Sales Cloud system, we can now finish the Marketing Cloud user integration. Log out of Salesforce Sales Cloud and back into Marketing Cloud using your personal admin account.

  1. In Marketing Cloud, hover over your name and select Setup.
  2. Next, select Users under Administration.
  3. Click the name of the Marketing Cloud Account API user.
  4. Click Integrate in the Salesforce.com Status field on the user's general settings screen.
salesforce connector
  1. Enter the username for the CRM API user and click Save Settings.

If successful, the Salesforce.com Status updates to Integrated.

salesforce connector

Next we run through a scenario to test the connection and make sure everything is working properly.

Create Field Mapping

One of the coolest features of Marketing Cloud Connect is its automatic synchronization of data between Marketing Cloud and Salesforce Sales Cloud. To make this work, we need to configure some basic field mapping. We specify the relationships between subscribers in Marketing Cloud and the corresponding fields in the Lead and Contact objects in Salesforce Sales Cloud.

  1. Log into Marketing Cloud with your Marketing Cloud Connect API credentials.
  2. In Marketing Cloud, hover over Email Studio and click Email.
  3. Hover over Subscribers and select Profile Management.
  4. Click "Create."
Field Mapping
  1. On the General tab, type your first name in the top text box.
  2. Click the Salesforce tab.
  3. Select the first name in the Map to Salesforce Lead Field picklist.
  4. Scroll down in the Map to Salesforce Contact/Account Field picklist to the Contact General section and select First Name. Select both checkboxes to display on the Salesforce Profile Center.
Field Mapping
  1. Click "OK."
  2. Repeat steps 3–9 to create a second attribute, using the last name instead of the first name.

Marketing Cloud Connect setup is now complete.

Testing

Now that you’ve successfully set up Marketing Cloud Connect, let’s do a quick test to ensure everything is working properly. First, we build a basic email template in Marketing Cloud and then send an email to leads inside Salesforce Sales Cloud.

Create an Email in Marketing Cloud

Get started by creating a basic email template in Marketing Cloud Content Builder.

  1. In "Content Builder," click "Create."
  2. Select "Email Message" from the drop-down list.
  3. Below Define Properties, select "Text Only" from the drop-down list.
  1. In the Name field type MC Connect Test and then click Next.
  2. In the Subject field, type Marketing Cloud Connect Test Email.
  3. Paste the following code into the body and then click Save and Exit.
    • Dear %%First Name%% %%Last Name%%,
    • System attributes (%%jobid%%, %%memberid%%)
    • Forward to a Friend: %%ftaf_url%%
    • Update Your Profile: %%profile_center_url%%
    • This email was sent by:
      • %%Member_Busname%%
      • %%Member_Addr%%
      • %%Member_City%%, %%Member_State%%,%%Member_PostalCode%%,
      • %%Member_Country%%

Create a Test Lead in Salesforce Sales Cloud

Now that we have an email created in Marketing Cloud, we need to create recipients in the Salesforce Sales Cloud environment to send our test message.

  1. Log out of Marketing Cloud and log in to your Salesforce Sales Cloud account.
  2. Select Leads in the navigation bar.
  3. Click "New."
  4. Fill out First Name, Last Name, Company, and Email Address with something memorable—you can use your name and company, for example. Ensure the email address you use is one that you have access to so you can view the test email.
  5. Click Save.

Create Test Lead Report

  1. Navigate to Reports from the All Tabs page.
  2. Click "New Report."
  3. In the Select Report Type section, click "Leads," then click "Create."
  4. Enter ID in the Quick Find text box.
  5. Double-click the lead ID to add it as a column in the report.
  6. In the Show picklist, select All leads.
  7. Next to Filters, click Add. A new filter appears below the date field.
  8. Click the down arrow and scroll down the picklist to select Email.
  1. Leave the operator as equals, and then enter the email address you specified when you created the test lead.
  2. Click OK.
  3. Click Run Report. You should see a single result: the test lead that you created.
  1. If the report looks as expected, click "Save As."
  2. Name the report "MC Connect Leads Test" and save it in the Marketing Cloud Admin report folder.
  3. Click "Save."

Send a Test Email from Salesforce Sales Cloud

Now it’s time for the real test. Here’s how to send that Marketing Cloud–generated email from within the Salesforce Sales Cloud org.

  1. In Salesforce Sales Cloud, click the plus icon to navigate to the All Tabs screen.
  2. Click "Marketing Cloud."
  3. Click "Find."
  4. Click "Content Builder" and select the MC Connect Test email template you created.
MC Connect Test
  1. Click "plus" sign the Recipients section of the form.
  2. Select the Marketing Cloud Admin Reports folder.
  3. Select the MC Connect Leads Test.
  4. In the From section of the form, select the desired value. Since this is a test email, any option is fine.
  5. Select the checkbox next to I certify that all of these people have opted in (required).
  6. Click Send.

The email is now queued for sending. Even though the default setting is immediate send, it can take up to an hour to see the email in your inbox. Marketing Cloud is designed for sending email to millions of subscribers at once, so there are a number of asynchronous processes and queues involved in this simple test. In other words, don’t worry if the email doesn’t show up right away.

When it does, if everything is set up properly, the test email arrives in your inbox with the first name and last name populated, along with other details from the email.

Marketing Cloud Connect Is Connected!

Cue the confetti—you have successfully set up Marketing Cloud Connect for your account.

When you are ready to deploy Marketing Cloud Connect to your users, be sure to:

  • In Salesforce Sales Cloud: repeat steps to assign proper page layouts and permission sets to users who plan to use Marketing Cloud Connect.
  • In Marketing Cloud: Integrate all users needing access to both systems.