How to use CAPI in google ads and meta ads

How to Use Conversion API (CAPI) in Google Ads & Meta Ads

Conversion API (CAPI) is a server-side tracking solution that sends conversion data directly from your server to advertising platforms. It improves tracking accuracy, especially after cookie restrictions, iOS updates, and ad blockers.

1. Why Use CAPI in Google & Meta Ads?

  • Recover lost conversions
  • Improve attribution accuracy
  • Help ad algorithms optimize faster
  • Reduce CPA and improve ROAS
Best Practice: Always use Pixel + CAPI together with event deduplication.

2. Using Conversion API in Meta Ads (Facebook & Instagram)

Step 1: Prepare Requirements

  • Meta Business Manager access
  • Meta Pixel created
  • Access token generated
  • Backend or GTM Server-side

Step 2: Choose Setup Method

  • Direct Server Integration (Developer)
  • Google Tag Manager – Server Side (Recommended)
  • Partner Integrations (Shopify, WooCommerce)

Step 3: Send Events via Meta CAPI

POST https://graph.facebook.com/v18.0/PIXEL_ID/events?access_token=ACCESS_TOKEN { "data": [{ "event_name": "Lead", "event_time": 1700000000, "action_source": "website", "event_source_url": "https://example.com/thank-you", "user_data": { "em": ["HASHED_EMAIL"], "ph": ["HASHED_PHONE"] } }] }

Step 4: Enable Event Deduplication

  • Send same Event ID via Pixel & CAPI
  • Prevents double counting
  • Improves reporting accuracy

3. Using Conversion API in Google Ads (Enhanced Conversions)

Google Ads uses Enhanced Conversions, which works similar to CAPI by sending hashed first-party data to Google servers.

Step 1: Enable Enhanced Conversions

  • Go to Google Ads → Conversions
  • Select conversion action
  • Turn ON Enhanced Conversions

Step 2: Data Collection Methods

  • Google Tag Manager
  • Global Site Tag (gtag)
  • Server-side GTM

Step 3: Send User Data Securely

  • Email
  • Phone number
  • Name & address (optional)
Important: Google automatically hashes data using SHA-256.

4. Meta CAPI vs Google Enhanced Conversions

Feature Meta CAPI Google Enhanced Conversions
Tracking Type Server-side Server + Tag-based
Best For Social & visual ads Search & intent-based ads
Setup Complexity Medium–High Medium
Accuracy Boost Very High High

5. Recommended Setup Architecture

  • Website → GA4
  • GA4 → GTM Server Container
  • GTM Server → Meta CAPI
  • GTM Server → Google Enhanced Conversions

6. Events You Should Track with CAPI

  • PageView
  • Lead
  • AddToCart
  • Purchase
  • Subscribe

7. Common Mistakes to Avoid

  • No event deduplication
  • Sending unhashed user data
  • Wrong event mapping
  • Tracking low-quality events
Final Formula:
Pixel + Conversion API + Enhanced Conversions = Maximum Tracking Accuracy & Better ROAS

Comments

Popular posts from this blog

Perfomance marketing benchmark

What is CRO ?Learn CRO . Optimize for high CTR .

On Page SEO - Guide