How to measure LinkedIn Ads pipeline in Salesforce

Updated

To measure ad pipeline in Salesforce, every paid lead needs two things: a clean Lead Source and membership in a Salesforce campaign for that ad channel. Every opportunity then needs the right contacts attached as contact roles. With those in place, a Campaigns with Opportunities report shows pipeline by channel, and you can divide spend by opportunities to get cost per opportunity.

This guide covers LinkedIn Ads, Google Ads and Microsoft Ads. It explains each Salesforce field and setting, why it matters, and where most setups break.

How Salesforce credits pipeline to a channel

Salesforce gives you three places to record where an opportunity came from. Each answers a slightly different question.

Salesforce feature What it records Best for
Lead Source One picklist value on the lead, carried to the contact and opportunity Simple “which channel brought them in” reporting
Primary Campaign Source One campaign on the opportunity, which gets 100% of the credit A single campaign-level answer per opportunity
Campaign Influence Every campaign a contact on the opportunity touched, with a share of credit Seeing all the channels that played a part

Most teams need all three. Lead Source tells you the channel. Campaigns tell you which program. Campaign Influence tells you what else helped.

Step 1: Standardize Lead Source

What it does: gives every lead one channel value. Why: it’s the simplest field to report on, and it travels with the record. Salesforce maps standard lead fields to the matching standard fields on the account, contact and opportunity when a lead is converted.

  1. Agree on a short list of paid values, for example LinkedIn Ads, Google Ads and Microsoft Ads. Keep organic social, events and referrals as separate values.
  2. Set the value automatically from the form or the lead sync, never by hand. Reps choosing from a long picklist is how “Web”, “Website” and “Paid” end up meaning the same thing.
  3. Decide whether Lead Source can change after creation. Most teams lock it so it stays a first-touch record.

One catch: the Lead Source values available during conversion depend on the converting user’s default record type. If your record types use different picklists, test a conversion before you rely on the field.

Step 2: Create a campaign for each channel and program

What it does: gives every ad program a Salesforce campaign that leads and contacts join. Why: campaigns hold the cost, the members and the linked opportunities in one place.

A structure that works for most teams:

  • Parent campaign per channel: “Paid - LinkedIn Ads”, “Paid - Google Ads”, “Paid - Microsoft Ads”.
  • Child campaign per ad campaign or program: for example “LinkedIn - Q4 CFO webinar”.

Set the child’s Parent Campaign field to link them. Salesforce supports up to five levels, and results such as responses and converted leads roll up to the parent. The hierarchy fields, such as Total Value Opportunities in Hierarchy, give you channel totals without extra reports.

Fill in these campaign fields:

  • Type: a consistent value such as Paid Social or Paid Search.
  • Budgeted Cost and Actual Cost: planned and actual spend. Update Actual Cost monthly from the ad platform.
  • Active: checked while the campaign runs.

Then set Campaign Member Statuses on each campaign, for example Clicked and Form Submitted. Mark the statuses that count as a response with the Responded option, so response counts mean something.

Step 3: Capture UTMs in hidden fields and map them through conversion

What it does: stores the campaign details from the ad click on the lead. Why: without them you can’t tell which LinkedIn or Google campaign produced a lead, and you can’t add it to the right Salesforce campaign automatically.

  1. Create custom lead fields: UTM Source, UTM Medium, UTM Campaign, UTM Content and UTM Term. Add fields for click IDs too, such as GCLID.
  2. Add matching hidden fields to every web form. Your form tool or a small script reads the values from the landing page URL and submits them with the form.
  3. Create the same custom fields on Contact and Opportunity.
  4. Map them for lead conversion. From the object management settings for leads, go to the fields section and click Map Lead Fields. Choose the contact or opportunity field for each custom lead field and save.

Step 4 matters more than it looks. Custom lead fields don’t carry over on conversion unless an admin maps them. Skip it and the UTM data disappears at the moment it becomes useful.

Then tag the ads themselves:

Channel utm_source utm_medium utm_campaign
LinkedIn Ads linkedin paid_social Campaign ID plus name, from LinkedIn’s dynamic UTM values
Google Ads google cpc {campaignid} ValueTrack parameter
Microsoft Ads bing cpc {CampaignID} dynamic parameter

LinkedIn can fill campaign, campaign group and creative IDs or names automatically with dynamic UTM values, except on Message Ads and Conversation Ads. Google has no campaign-name ValueTrack parameter, so use the ID and keep auto-tagging on. Microsoft Advertising supports tracking templates and Final URL suffixes with dynamic values such as {CampaignID} and {keyword}.

Keep values lowercase and identical across teams and agencies. If tracking looks wrong, our guide to broken or missing UTMs walks through the usual causes.

Step 4: Add leads to campaigns automatically

What it does: turns each paid lead into a campaign member. Why: campaign reports, Primary Campaign Source and Campaign Influence all depend on campaign membership.

Build a Flow (or use your marketing automation platform) that runs when a lead is created or updated:

  1. Read UTM Source and UTM Campaign.
  2. Find the matching Salesforce campaign.
  3. Create a campaign member with the status Form Submitted.

Native lead forms need their own route. LinkedIn Lead Gen Forms and Google lead forms never visit your website, so they carry no UTMs. Whatever syncs those leads into Salesforce should also set Lead Source and add the lead to the right campaign.

Step 5: Understand Primary Campaign Source, and how it gets overwritten

What it does: names one campaign on each opportunity. Why: the standard campaign reports use it, so its value decides which channel gets credit.

When a lead belongs to more than one campaign, Salesforce applies the most recently associated campaign to the opportunity’s Primary Campaign Source on conversion. That’s documented in Salesforce’s lead conversion considerations. Converted leads’ campaign memberships move to the new contact.

“Most recent” is the problem. Picture this:

  1. A prospect fills in a form from a LinkedIn ad in March and joins your LinkedIn campaign.
  2. In May, they’re added to a webinar invite list.
  3. In June, sales converts the lead and creates an opportunity.

The webinar campaign becomes the Primary Campaign Source. LinkedIn, which created the lead, gets nothing in the standard report. List imports, newsletter campaigns and event uploads cause this every day.

Ways to protect it:

  • Only add people to a campaign when they respond, not when they’re merely sent something.
  • Use separate Campaign Member Statuses for “Sent” and “Responded”, and keep email sends out of channel campaigns.
  • Use a Flow to set Primary Campaign Source from your own rule, such as the most recent paid campaign before the opportunity’s created date.
  • Rely on Lead Source and the UTM fields for first-touch reporting, since they don’t move.

Step 6: Require Opportunity Contact Roles

What it does: links the people on a deal to the opportunity. Why: Campaign Influence looks for campaign members who are also contact roles on the opportunity. No contact role, no influence.

Opportunities that sales creates directly from an account often start with no contact roles. Make adding them part of the process:

  1. Add the Contact Roles related list to the opportunity page layout.
  2. Ask reps to add every person in the buying conversation and mark one as primary.
  3. Build a report of open opportunities with no contact roles and review it weekly.
  4. If reps skip it, consider a validation rule or Flow that blocks moving past an early stage without one.

Step 7: Turn on Campaign Influence

What it does: credits every campaign a contact on the opportunity touched, not only the primary one. Why: paid channels often start the journey and lose the Primary Campaign Source to a later touch.

  1. From Setup, enter “Influence” in the Quick Find box and select Campaign Influence Settings.
  2. Under Campaign Influence, select Enabled.
  3. Review the auto-association settings, including the time frame and campaign types to include.

The default model in Customizable Campaign Influence is Primary Campaign Source, which gives 100% to that one campaign. First-Touch, Last-Touch and Even-Distribution models are available with Account Engagement, per Salesforce’s Campaign Influence implementation guide.

Two things to know from that guide. Influence records are only created for open opportunities. And once an opportunity closes, won or lost, no new influence records are added.

Step 8: Build the reports

Pipeline by channel (campaign-based)

  1. Open the Reports tab and click New Report.
  2. Choose the Campaigns category, then Campaigns with Opportunities.
  3. Add Campaign Name, Parent Campaign, Opportunity Name, Created Date, Stage and Amount.
  4. Filter Opportunity Created Date to your period. Group by Parent Campaign to see each channel.

This report uses the opportunity’s Primary Campaign Source, so check Step 5 first.

Pipeline by channel (Lead Source)

Create an Opportunities report, group by Lead Source, sum Amount, and filter by Created Date. It’s the cleanest first-touch view.

Influenced pipeline

With Customizable Campaign Influence on, use Campaigns with Influenced Opportunities (Customizable Campaign Influence). It shows amount, stage and revenue share by campaign. The guide notes that Opportunity Contact Role fields and cross filters aren’t available in that report type.

Step 9: Choose an attribution rule and calculate cost per opportunity

There are three honest ways to credit a channel. Pick one as your default and label every number with it.

Rule What gets credit Salesforce fields
Sourced The channel that first brought the person in Lead Source; earliest campaign membership
Opportunity creation The last paid touch on or before the opportunity’s created date Opportunity Contact Roles plus campaign member dates
Influenced Opportunities at accounts the channel reached in the 180 days before creation Ad platform company reach matched to Salesforce accounts

Then:

Cost per opportunity = channel spend in the period ÷ opportunities created and credited to that channel in the lagged period.

For example, $40,000 on Google Ads and 16 credited opportunities is $2,500 per opportunity. Shift the opportunity window by your own typical lead-to-opportunity gap. Measure it from Salesforce: the median days between a lead’s created date and its opportunity’s created date.

Common mistakes

  • Relying on Primary Campaign Source alone. The most recent campaign wins, so list imports and email campaigns steal credit from paid channels.
  • Not mapping custom lead fields. UTM fields vanish at conversion unless they’re mapped.
  • Opportunities with no contact roles. Campaign Influence can’t see them.
  • Adding non-responders to campaigns. Every “sent” member is a chance to overwrite the primary campaign.
  • utm_medium=social on paid ads. Analytics tools file it as organic, and your Flow may too.
  • Trusting platform-reported pipeline. Google’s offline conversion imports from CRM connectors look back only 14 days on the first run, and LinkedIn’s click cookie lasts 30 days. Slow B2B deals fall outside both. Salesforce is the source of truth.
  • No lag. Judging this month’s spend on this month’s opportunities makes every new campaign look like a failure.
  • Leaving Actual Cost blank. Without spend on the campaign, nobody can calculate cost per opportunity in Salesforce.

How PipeHalo does this automatically

Keeping all of this clean is a part-time job. PipeHalo does the joining for you every morning.

Connect your ad accounts and Salesforce. PipeHalo reads both, and it never creates, edits or deletes anything in Salesforce. The Pipeline page credits each new opportunity to the one channel that sourced it. It checks the UTM fields an admin points it to on leads, contacts and opportunities first, then the opportunity’s Primary Campaign Source, then Lead Source. It puts that next to spend from LinkedIn, Google, Microsoft and Reddit Ads: leads, opportunities, pipeline, closed-won, cost per lead, cost per opportunity and pipeline per $1.

When source values are messy, an admin picks the right channel once in Channel mapping, and every opportunity is recredited. The daily checks flag broken or missing UTMs and spend with no pipeline, with what to try and the money at stake where there is one. See why LinkedIn ads show no pipeline for that problem in detail, or the full list of checks on the features page.

Try the live demo to see the Pipeline page with 13 months of sample LinkedIn, Google and Meta ads data. The sample CRM is HubSpot, but the crediting works the same way.

Why does Salesforce credit my webinar instead of LinkedIn?

On conversion, Salesforce sets Primary Campaign Source to the lead’s most recently associated campaign. If the lead joined a webinar list after the LinkedIn ad, the webinar wins. Use Lead Source or Campaign Influence for the fuller picture.

Do I need Campaign Influence to measure ad pipeline?

No. Lead Source and Primary Campaign Source are enough for sourced pipeline. Campaign Influence adds the other campaigns that touched a deal, which matters most for LinkedIn and account-based programs.

Which report type shows opportunities by campaign?

Use Campaigns with Opportunities under the Campaigns category. With Customizable Campaign Influence on, use Campaigns with Influenced Opportunities (Customizable Campaign Influence).

Click through a real workspace.

13 months of sample data across every channel and the CRM. Yours to explore for 7 days.

Try the live demo