Salesforce offline conversions to Meta, Google Ads, TikTok, LinkedIn, Microsoft Ads, Reddit, Pinterest and X

Salesforce FlowApex or outbound messagePrivate sales webhook
Eight ad platforms

Your ads never see what happens after the form. Make a Salesforce Flow, Apex trigger or outbound message post each stage change to the DataCops sales webhook, so Meta, Google Ads, TikTok, LinkedIn, Microsoft Ads, Reddit, Pinterest and X learn which clicks became customers.

Setup in 5 minutes
No credit card
One lead from a Meta ad
From form fill to won deal in HighLevel
With DataCops
Form fillSent to Meta
Booked callSent to Meta
Showed upSent to Meta
Deal wonSent with its value
Matched to the original ad click by email

Trusted by agencies and brands running paid media

AffilinoBigfishClever DigitalKeetraxLegendListingLogicNumeroStormZealdBurst Digital
Definition

How do Salesforce offline conversions work?

Offline conversions are sales, or steps toward a sale, that happen away from your website and are sent back to the ad platform that brought the customer. In Salesforce that means a lead that became qualified, or an opportunity that reached Closed Won.

DataCops connects to Salesforce through a private sales webhook. Salesforce posts a small message when a stage changes, DataCops matches the person to the ad click it kept on your own domain, and sends the result to every platform you connected.

A Salesforce Flow, Apex trigger or outbound message posts each stage change to a private webhook, and DataCops sends it to Meta, Google Ads, TikTok, LinkedIn, Microsoft Ads, Reddit, Pinterest and X.

What your ads learn from

Salesforce lead to customer
What your ads see today Form Qualified Closed Won, with value
With DataCops Form Qualified Closed Won, with value
Salesforce with a sales cycle
What your ads see today Form Meeting held Proposal Closed Won
With DataCops Form Meeting held Proposal Closed Won

From ad click to Closed Won

What happens between the first visit and the conversion your ads receive.

  1. Step 01
    Saved on yourdomain.com
    fbclid from Meta Kept
    gclid from Google Ads Kept
    ttclid from TikTok Kept
    Kept for up to 90 days

    The script on datacops.yourdomain.com keeps the ad click ID with the visitor for up to 90 days.

  2. Step 02
    Stages your CRM reports
    Booked call Reported
    Showed up Reported
    Won, with value Reported

    The deal moves in Salesforce. A Flow or Apex callout posts the stage, email or phone, and value.

  3. Step 03
    Finding the ad click again
    Won dealby email or phone
    Ad click, 23 days earlierMatched

    DataCops matches the person to the click, by click ID or by an email linked to their visit.

  4. Step 04
    Won deal sent
    Meta Sent once
    Google Ads Sent once
    TikTok Sent once
    LinkedIn Sent once

    Consent and duplicates are checked, then the sale goes to every ad platform you connected.

Every post from Salesforce is logged in plain words: sent, not sent, duplicate, ignored or rejected.

Why send Salesforce stages to your ads

Ad platforms optimize for what they are told. If the only signal is the form fill, they find more people who fill in forms, including the ones who never answer the phone. A Closed Won event with a value tells them what a good click looks like.

The catch is timing. Salesforce closes a deal weeks after the click. Safari caps browser-script cookies at 7 days, and iOS Link Tracking Protection strips some click IDs from links. By the time the deal closes, the ad click is often gone from the browser. DataCops keeps the click on your own domain, so the match still works on the day Salesforce reports the sale.

There is a second reason. Most B2B teams already know which campaigns bring form fills. Few know which campaigns bring pipeline. Once Salesforce stages flow back, the same campaign view in each ad platform starts to show qualified leads and revenue next to clicks, and the bidding learns from them too.

How DataCops keeps the click until the deal closes

The DataCops script loads from a subdomain of your own site, such as datacops.yourdomain.com, set up with one DNS record. Because it is your own domain, browsers treat it as part of your site, and ad blockers that match known tracking hosts do not stop it.

On each visit it keeps the Google, Meta, TikTok, Microsoft, LinkedIn and X click IDs with the visitor. When the visitor shares an email, on your form or in a signup, DataCops links that email to their visit and their ad click. That link is what lets a Salesforce post that only carries an email find the right ad later.

If the same person comes back weeks later on a new device and uses the same email, the earlier click can still be credited. For returning visitors on the same browser, you can switch on a first-party server cookie that keeps them recognised for up to 400 days, even on Safari. It is a per-site switch and starts off.

How to connect Salesforce to the DataCops webhook

Copy the private sales webhook URL from your DataCops dashboard. Treat it like a password and keep it out of shared documents. From Salesforce, there are three ways to call it.

  1. Salesforce Flow. A record-triggered flow on Lead or Opportunity, fired when the stage changes, with an HTTP callout action that posts the JSON below. This needs no code and is the easiest to maintain.
  2. Apex. A trigger or queueable class that makes an HTTP callout when the stage field changes. Use it when you need logic a Flow cannot express, and register the webhook host as a remote site or named credential.
  3. Outbound message or middleware. An outbound message, or Zapier, Make or n8n listening to Salesforce and posting to the webhook. Use it when your team already runs one of these.

Direct posting is one less thing to break. A middleware tool adds a step and a task count you may pay for, but it is quicker to set up if nobody on your team writes Flows. If you prefer an API key over a webhook secret, the public conversions API takes the same kind of post and counts a repeated messageId once.

Example payload from a Closed Won opportunity

This example uses made-up values. Field names are the real ones the webhook reads.

{
  "event": "won",
  "email": "dana.reyes@example.com",
  "phone": "+14155550137",
  "value": 4800,
  "currency": "USD",
  "order_id": "006XX00000ABC123",
  "gclid": "Cj0KCQjw-example",
  "fbclid": "IwAR-example",
  "test": false
}

The event is required, and the stage names it accepts are in the offline conversions docs. Email or phone must be present, and phone should carry the country code. Send value and currency on won events so the ad platforms can optimize for revenue. Click IDs are optional and worth sending when you store them on the Lead or Contact, because a click ID is the strongest match there is.

Which Salesforce stages to send

Send the stage that happens often enough to teach a campaign and late enough to mean something. Most B2B teams end up with two or three.

  • Qualified lead. The lead is real and in your market. This is the best first signal for teams with fewer than a few dozen deals a month.
  • Meeting held. A rep spoke to them. It removes the leads that book and never show.
  • Closed Won, with value. The revenue signal. Send it with the opportunity amount and the opportunity ID as order_id.

Closed Lost is best left unsent. Sending it as a conversion would teach the platform to find more people you lose. In DataCops, each stage maps to a standard event such as Lead or Purchase, and you choose per event which platforms receive it.

Hold a lead until Salesforce says it is real

Some teams want the ad platforms to learn only from leads that sales accepted. DataCops can hold a lead instead of sending it. The held lead keeps its original click IDs and hashed details. When Salesforce marks it qualified, a Flow calls the release endpoint with the event name and email, and DataCops sends the held lead, oldest first. A release runs once, so a double call does not double send.

Leads can also be released or dropped from the lead list in the dashboard. Held leads that are not released within 14 days expire, which keeps old, cold leads out of your ads. HubSpot users get this release automatically, checked every 5 minutes. With Salesforce, the Flow calls the release endpoint.

One sale, one conversion

Salesforce edits records often. An opportunity can hit Closed Won, go back to Negotiation and come back again. DataCops keeps a sale ledger per ad platform. A Purchase with an order_id is sent once per order per platform, and remembered for 400 days. A Lead with an email is sent once per platform in a 30-minute window. A repeat shows in the log as a duplicate, with the first send it matched.

The same ledger covers other sources. If the browser pixel, a form and Salesforce all report the same order with the same ID, each ad platform still gets it once. Meta also receives the event_id, so its own browser and server events dedupe.

Refunds and lost deals after the sale

When a closed deal is refunded, post the refund through the conversions API. On Google Ads, DataCops retracts the conversion for a full refund and lowers its value for a partial one. A duplicate refund post adjusts once. Meta and TikTok have no API to correct a sent conversion, so nothing is sent to them for a refund.

Five Salesforce pitfalls to plan for

  1. Lead conversion changes the record. When a Lead converts, Salesforce creates a Contact, an Account and often an Opportunity, and mapped fields do not always copy across. Map email, phone and click ID fields on both the Lead and the Contact.
  2. One contact, several opportunities. Use the opportunity ID as order_id. A customer who buys twice counts twice, and an opportunity edited three times counts once.
  3. Stage renaming. If someone renames a stage, automation that matches on the name stops firing. Match on a stable field such as IsWon, and review the list when the pipeline changes.
  4. Sandbox versus production. A sandbox will happily post to a live webhook. Send the test flag as true from every sandbox and test record.
  5. Ownership. Automation runs as a user. Run flows as an integration user with access to every field you send, so a deactivated rep does not stop your callouts.

Privacy and consent

Email, phone and names are cleaned and SHA-256 hashed before they leave our servers. DataCops estimates a match score out of 10 from the details you send, so you can see when adding phone or a click ID would help. The score is our estimate, not the platform's own rating.

The built-in cookie banner is built to the IAB TCF v2.2 standard, shows in Europe by default, and turns on Google Consent Mode v2. The server checks consent again before every send. For EU, UK and Swiss visitors, nothing goes to an ad platform until the visitor opts in. If your site handles health topics, Health mode sends ad platforms only the click, the value and your homepage address.

See exactly what reached each platform

The delivery report shows, per platform, how many conversions were sent, skipped or failed, with a plain reason for each one: a duplicate, a held lead, an event not mapped, a consent rejection, and so on. History goes back up to 400 days. Alerts email you when deliveries start failing or an ad platform token is about to expire, so a broken Flow does not go unnoticed for a month.

Good to know before you start

  • Salesforce connects through the private sales webhook, directly or through Zapier, Make or n8n.
  • A sale links to an ad click through click IDs in the post or an email DataCops already linked to a visit, so capture email on your forms.
  • Post each stage when it happens: Meta takes events up to 7 days old, Google Ads up to 90 days after the click.
  • Qualify leads in Salesforce before they reach a stage you send, since CRM posts carry no browser bot check.

Everything behind each Salesforce conversion

Capture Background

One first-party script, served from your own domain

  • Runs first-party from datacops.yourdomain, not a blockable third-party host
  • One script, one CNAME, live in about 5 minutes, no container to host
  • Server-side collection on Cloudflare's edge, close to every visitor
  • Captures click IDs at the network level, so fbclid and gclid still reach your CAPI feed after browsers strip them
  • Recovers 15 to 25% of the sessions other setups lose

Traffic Visibility

10%
20%
30%
40%
50%
60%
70%
80%
90%
100%

First-Party Script

~78%

Blockers and ITP cut your sessions

Real people only

Filter fake leads before you send

A bot that fills in your form becomes a lead your ads try to find more of. DataCops checks every visit for bots and datacenter traffic, and for VPNs and proxies if you choose. Switch on Real people only for a platform and flagged visits never reach it.

Sales that come from your CRM are sent as your CRM reports them, with no bot check, so qualify them there before you send.

How DataCops spots bots
Meta, delivery
Real people only
Bots and datacenter traffic never reach Meta. VPNs and proxies too, if you choose.
Send everything
Meta gets every visitor, bots included.
Lead from a bot Skipped

Set up Salesforce offline conversions

About 5 minutes for the site, plus the Flow on the Salesforce side.

  1. Step 1
    code

    Add the DataCops script
    One script and one DNS record keep every ad click on your own domain.

  2. Step 2
    ads_click

    Connect your ad platforms
    One-click sign-in for Meta, Google Ads, TikTok and LinkedIn. An API key for Microsoft Ads, Reddit and Pinterest.

  3. Step 3
    hub

    Post from Salesforce
    Point a Flow, Apex callout or outbound message at your private sales webhook.

In short

Salesforce offline conversions with DataCops, in short

DataCops is a tool that sends Salesforce offline conversions to Meta, Google Ads, TikTok and LinkedIn: a Salesforce Flow, Apex callout or outbound message posts each stage to a private webhook, matched to the ad click, with every send logged.

How DataCops does it

1

Post each stage from Salesforce

A Salesforce Flow, an Apex callout, an outbound message, or Zapier, Make or n8n posts each stage change to your private DataCops sales webhook. There is no native Salesforce app; the webhook is the connection.

2

What the post carries

Email or phone, the value and currency, an order ID, a timestamp and any click IDs. An order ID means a repeated sale is counted once.

3

Matched to the ad click

A sale links to its click through click IDs in the post, or through an email DataCops already linked to a visit, so capture email on your forms. DataCops keeps the click on your own domain for up to 90 days, and a signed server-set cookie lasts up to 400 days where enabled.

4

Post when it happens

Meta takes events up to 7 days old and rejects a request with an older one. Google Ads takes uploads up to 90 days after the click. Post each stage as it changes instead of in a monthly batch.

5

Qualify before you send

Every visit gets a bot verdict against 360+ billion IPs and 350+ monitoring points, with a Real people only switch per platform, off by default. CRM posts carry no bot flags, so the check applies to the site visit. Every form email is checked for disposable providers, domains with no mail server and an email risk score, and LeadCops can hold a lead.

6

Warm up, and see every send

Ads Warmup sends a CSV of up to 20,000 past won deals and customers, each with a 0 to 10 match score, to Meta, Google Ads and TikTok, dated when you send. A delivery log row shows each send as sent, held, skipped or failed with the reason.

Best for: B2B and enterprise sales teams on Salesforce who advertise on Meta, Google Ads, TikTok or LinkedIn and want won deals to teach the ads.

Free to start. See pricing.

When not to use DataCops

You need a native Salesforce connector

DataCops connects through the private webhook, directly or through Zapier, Make or n8n.

You need bot checks on Salesforce records

Qualify leads in Salesforce before the stage you send. CRM posts carry no browser bot check.

You need refunds sent back to the ads

Refunds do not reach Meta or TikTok. Google Ads is corrected: a full refund retracts the conversion and a partial one lowers its value.

One report is all you want

DataCops sends conversions to your ads. It is not a reporting layer.

FAQ

Yes. A Salesforce Flow, an Apex callout, an outbound message, or Zapier, Make or n8n posts each stage change to your private DataCops sales webhook. DataCops matches the person to the ad click and sends the conversion to Meta, Google Ads, TikTok, LinkedIn, Microsoft Ads, Reddit, Pinterest and X.

Let your ads learn from Closed Won

Start free, add the script, and post your first Salesforce sale in an afternoon.

Setup in 5 minutes. No credit card.

Live traffic quality

Updated just now

Visits · last 24h

487
Real users
35873.5%
Bots · auto-filtered
12926.5%

Without filtering, 26.5% of your reported traffic is bot noise inflating dashboards and draining ad spend.

Don't trust your analytics!

Make confident, data-driven decisions withactionable ad spend insights.

Setup in 2 minutes
No credit card