How it works without Apex
LinkedIn and Google only know who filled out a form, not who actually became a paying customer weeks later. To teach those ad platforms which clicks turned into real deals, your team has to hide tracking tags (li_fat_id and gclid) inside every form, download won deals from HubSpot into spreadsheets each week, and upload them by hand to LinkedIn Conversions API and Google Offline Conversions. As soon as two people from the same company touch your site, those spreadsheets break.
How Apex does it for you
Apex saves each visitor's ad click (li_fat_id and gclid) when they land on your site and connects it to their work email when they request a demo. When your sales team marks a deal as Closed-Won in HubSpot, Apex automatically sends the real dollar amount back to LinkedIn Conversions API and Google Ads Data Manager API so your ads chase real buyers instead of free PDF downloaders.
How to set this up in 4 steps
Add Apex.js to your landing pages to save LinkedIn and Google click tags
Drop the Apex script onto your marketing site and demo pages so LinkedIn (
li_fat_id) and Google (gclid) click tags are saved automatically before anyone fills out a form.Link the visitor's work email when they submit a demo or guide form
Call
apex.identify(workEmail)on your forms so Apex connects each anonymous ad click straight to that buyer's HubSpot record.Connect HubSpot CRM, LinkedIn Ads, and Google Ads
Sign in to all three accounts inside Apex Integrations so ad spend, clicks, and won HubSpot deals live in one place.
Test the feed safely for 2 to 4 weeks before switching your ad bidding
Send Closed-Won deals as a Secondary goal first so you can confirm they match up inside LinkedIn Campaign Manager and Google Ads without changing live bids. Once the match rates look solid, promote Closed-Won to your Primary goal.
What you already have (and why form fills fool LinkedIn & Google)
Most B2B teams judge LinkedIn Ads and Google Search campaigns by how cheaply someone fills out a form or downloads a free guide. On paper, a free PDF checklist looks like a huge win at $62 a lead while a product demo ad costs $225 a lead. One or two months later, your sales team closes five paying contracts from the demo ad and almost zero from the free PDF, yet LinkedIn and Google keep pushing your budget toward whichever form gets the most clicks.
Downloading won HubSpot deals into spreadsheets and uploading CSVs to LinkedIn Campaign Manager and Google Ads every Friday works for a couple of weeks, then breaks as soon as deals take longer than a month or buyers switch between work laptops and phones.
How click IDs, HubSpot Closed-Won deals, and ad CAPI feeds connect

When a deal reaches Closed Won in HubSpot, Apex resolves the contact's original LinkedIn or Google click ID and pushes verified contract ACV back to each ad platform automatically.
Automatic click-ID capture + form
identify: Install the Apex Web SDK on your marketing site and landing pages (for example on a brandedtry.clearpathfleet.comlink or main domain) soli_fat_idandgclidparameters are captured automatically. Callapex.identify(workEmail)on every demo or content form submit.Connect HubSpot CRM once: Authorize HubSpot so Apex syncs contacts, companies, and deals continuously. Only deals that reach Closed Won with a real dollar amount count as verified revenue.
Stream verified Closed-Won conversions back to LinkedIn CAPI & Google Data Manager API: Apex matches the closed-won contact's work email (SHA-256 hashed) and stored
li_fat_id/gclidand pushes the actual deal amount back to LinkedIn Conversions API and Google Ads. Keep the Closed-Won conversion action as Secondary while verifying match rates, then promote it to Primary once volume stabilizes so Smart Bidding optimizes for revenue rather than cheap PDF downloads.
export async function onDemoRequest(lead: {
email: string;
name: string;
company: string;
fleetSize: number;
}) {
await createHubSpotContact(lead);
// Links captured li_fat_id and gclid parameters to the buyer's work email
window.apex?.identify(lead.email, {
name: lead.name,
company: lead.company,
});
window.apex?.track("form_submit", {
form_name: "dot_compliance_demo",
fleet_size: lead.fleetSize,
});
}
LinkedIn Conversions API matches conversions up to 90 days after the ad interaction, and Google Ads Data Manager API accepts offline click conversions within 90 days of the click. Review our HubSpot connector docs, LinkedIn Ads docs, and Google Ads docs for exact OAuth scopes and field mapping.
Worked monthly example (illustrative assumptions)
All figures below are illustrative assumptions for a fictional B2B fleet SaaS company (Clearpath Fleet) spending $13,200/month across LinkedIn Ads and Google Ads:
| Campaign | Spend | Leads (CPL) | Closed-Won | Closed ACV | ACV ROAS |
|---|---|---|---|---|---|
| DOT Compliance Demo · VP Fleet | $5,400 | 24 ($225) | 5 | $36,000 | 6.67x |
| 2026 Fuel Tax Checklist PDF | $3,600 | 58 ($62) | 1 | $4,800 | 1.33x |
| Fleet ELD Compliance Software · Exact | $4,200 | 31 ($135) | 4 | $24,800 | 5.9x |
| Total monthly (illustrative) | $13,200 | 113 ($117) | 10 | $65,600 | 4.97x |
Unit economics caveat: Gross ACV ROAS measures signed annual contract value against media spend before sales salaries, implementation costs, and gross margin. Use your target CAC payback period when deciding how much budget to shift out of low-intent whitepaper ads.
Live Apex pricing and campaign cost
The table below reads live from Apex's published rate card for 9,550 monthly events, 10 attributed HubSpot Closed-Won deals, and 10 outbound conversion sends to LinkedIn CAPI and Google Ads Data Manager API.
Live Apex pricing · Pay-as-you-go
Estimated Apex cost for $13,200/mo LinkedIn & Google Ads spend (10 HubSpot Closed-Won deals)
$0 / month
Fully inside Apex's free monthly allowances (resets every calendar month).
| Apex meter / schedule | Scenario volume | Free allowance / basis | Rate | Apex cost |
|---|---|---|---|---|
Events 1,620 ad click sessions, 480 return visits, and 10 HubSpot deal syncs | 9,550 / mo | 1M / month | $5 per 100K (per unit) | $0 |
Attribution 10 HubSpot Closed-Won deals attributed to LinkedIn Ads and Google Ads | 10 / mo | 1.5K / month | $0.05 per unit | $0 |
Ad platform activations 10 verified Closed-Won conversion sends to LinkedIn CAPI & Google Data Manager API | 10 / mo | 100K / month | $10 per 100K (per unit) | $0 |
HubSpot CRM, LinkedIn Ads, and Google Ads connectors and unlimited seats carry no extra Apex fee. Individual event history stays queryable for 13 months without a card, 3 years with a card on file, and 7 years once you've paid an invoice. See the live pricing page.
Third-party and campaign costs (not paid to Apex)
| Expense | Typical range | Notes |
|---|---|---|
| LinkedIn Ads & Google Ads media spend | $13,200 / mo illustrative | Paid directly to LinkedIn and Google; Apex never alters campaign budgets or bids. |
| HubSpot CRM subscription | Existing plan | Paid directly to HubSpot; Apex connects via standard OAuth. |
Limitations, prerequisites, and real-world edge cases
Sales cycles longer than 90 days: Both LinkedIn CAPI and Google offline click conversions enforce a 90-day lookback window for bidding feedback. Enterprise deals that close on day 120 still show inside Apex's attribution ledger, and you can send an earlier milestone (like SQL or Proposal Sent) to keep ad algorithms learning faster.
Buying-committee multi-contact deals: When an engineer clicks the ad and a VP signs the contract under a different email address, associating both contacts to the same HubSpot Company ensures Apex preserves account-level attribution.
Work email vs personal email: LinkedIn members frequently register with a personal email while filling out B2B forms with a work address. Capturing
li_fat_idon the landing page prevents match-rate loss when emails differ.




