---
title: Lead Source Attribution Automation — Domain-Based Mapping
type: article
created: '2026-04-05'
updated: '2026-04-05'
source_docs:
- raw/2026-03-13-weekly-call-w-karly-129884582.md
tags:
- salesforce
- lead-attribution
- automation
- pardot
- account-engagement
- apex
- abm
layer: 2
client_source: null
industry_context: null
transferable: true
---

# Lead Source Attribution Automation — Domain-Based Mapping

## Overview

When leads enter Salesforce through agency-managed landing pages or contact enrichment tools, the Lead Source field often defaults to the wrong value — typically the ad platform or enrichment tool rather than the agency responsible for the lead. This article documents the pattern for correcting that attribution automatically using a domain-based Salesforce automation.

The approach was first implemented for [[clients/papertube/index|PaperTube]]'s ABM campaign, where leads arriving via the `PaperTube.pro` landing page were being attributed to "Google AdWords" or "Hunter.io" instead of "Asymmetric."

---

## The Problem

Salesforce populates the Lead Source field using whatever signal arrives first — often the ad platform that drove the click (e.g., Google AdWords) or the enrichment tool used to source the contact (e.g., Hunter.io). When an agency manages a dedicated landing page or domain, inbound leads from that domain should be attributed to the agency, not the upstream traffic source.

**Symptoms observed:**
- Leads from `PaperTube.pro` showing Lead Source = "Google AdWords"
- ABM contacts loaded via Hunter.io showing Lead Source = "Hunter.io"
- Client unable to distinguish agency-sourced leads from self-sourced leads

---

## The Solution

Deploy a Salesforce automation (Flow or Apex trigger) that watches the UTM Source or referrer URL on incoming leads and contacts, and overwrites the Lead Source field when a match is found.

### Logic

```
IF Lead.UTM_Source contains "PaperTube.pro"  (wildcard match, any path)
  THEN Lead.Lead_Source = "Asymmetric"

IF Contact.Lead_Source = "Hunter.io"
  AND Contact is in ABM sequence
  THEN Contact.Lead_Source = "Asymmetric"
```

The domain wildcard (`PaperTube.pro/*`) ensures that any page on the managed domain — regardless of path or campaign — triggers the correct attribution.

### Scope

- **Object:** Lead (for inbound form fills) and Contact (for loaded ABM contacts)
- **Trigger:** On insert and on update when UTM Source changes
- **Field written:** `Lead_Source` (standard picklist field; "Asymmetric" must exist as a picklist value)

---

## Account-Level Attribution

By default, Salesforce does not expose a Lead Source field on the Account object — it exists only on Lead and Contact. To surface attribution at the account level:

1. Add a custom `Account_Lead_Source__c` field to the Account object.
2. Create an automation that syncs `Contact.Lead_Source` → `Account.Account_Lead_Source__c` when a contact is created or updated under that account.
3. Use the Contact as the authoritative source; the Account field is a read-through for reporting.

> **Note:** The standard Lead-to-Contact conversion mapping does not automatically carry Lead Source to a custom Account field. The sync automation must be set up separately.

---

## Picklist Requirements

Before deploying, confirm that "Asymmetric" (or your agency name) exists as a value in the Lead Source picklist. This is a global value set in Salesforce — adding it to Lead Source on the Lead object also makes it available on Contact.

To verify: **Setup → Object Manager → Lead → Fields & Relationships → Lead Source → Edit**

---

## Reporting

Once attribution is corrected, create a Lead report filtered to `Lead Source = Asymmetric` to track agency-sourced pipeline. Because Lead and Contact are separate objects in Salesforce, two reports are typically needed:

| Report | Object | Filter |
|---|---|---|
| New Leads (Agency) | Lead | Lead Source = Asymmetric |
| ABM Contacts (Agency) | Contact | Lead Source = Asymmetric |

These reports can be added to a shared ABM dashboard for client-facing visibility.

> **Scope gotcha:** New reports default to "My Leads/Contacts" scope, which hides records owned by other users. Change the scope to "All Leads" / "All Contacts" (or "Organization") to see the full dataset. This was the cause of empty "Asymmetric Activity" reports observed during the PaperTube setup.

---

## Implementation Notes

- The automation was built and deployed live during the [[meetings/2026-03-13-weekly-call-karly-papertube-quora|2026-03-13 weekly call]] using an Apex-assisted approach via the existing ABM Apex class.
- The existing Apex sync class (which handles Pardot engagement data) was the natural place to add UTM-based attribution logic, since it already reads and writes contact/lead fields on each sync cycle.
- A backfill was run after deployment to retroactively update existing contacts whose Lead Source was set to Hunter.io.

---

## Related

- [[knowledge/salesforce/abm-lead-engagement-notifications|ABM Lead Engagement Notifications — Apex Alert System]]
- [[clients/papertube/index|PaperTube Client Overview]]
- [[meetings/2026-03-13-weekly-call-karly-papertube-quora|Weekly Call — PaperTube ABM & Quora Teams Integration (2026-03-13)]]