Connecting Meta (Facebook)
Connect Meta to CleanClicks using a System User Access Token to send conversion events via the Conversions API.
CleanClicks sends conversion events to Meta via the Conversions API (CAPI). Meta requires a manually generated System User Access Token rather than OAuth.
Prerequisites
- A Meta Business Manager account
- A Meta Pixel created in Events Manager
- Admin access to Business Manager
Generating a System User Access Token
- Go to Meta Business Manager
- Navigate to Business Settings > Users > System Users
- Click Add to create a new system user (or use an existing one)
- Set the role to Admin
- Click Generate New Token
- Select your app (or create one if needed)
- Grant these permissions:
ads_managementads_read
- Set the token expiration to Never (recommended) or the longest available
- Copy the generated token
Important: System User Tokens are the recommended approach for server-to-server integrations. Personal access tokens expire and shouldn't be used.
Connecting in CleanClicks
- Go to Connections in your CleanClicks dashboard
- Select your domain
- Find Meta in the Token Entry section
- Click to expand
- Paste your Access Token
- Enter your Pixel ID (found in Meta Events Manager > your pixel > Settings)
- Click Save
Configuring the Vendor
After connecting:
- Go to Configuration > Vendors tab
- Enable Meta (Facebook)
- Verify the Pixel ID and Access Token are present
- Optionally add a Test Event Code for testing
- Save
Test Event Code
Meta provides a Test Event Code in Events Manager > Test Events tab. Adding this code to your CleanClicks vendor configuration sends events in test mode so you can verify they arrive correctly before they count as real data.
To use:
- Go to Meta Events Manager > your pixel > Test Events
- Copy the test code (e.g.,
TEST12345) - Paste it into the Test Event Code field in Configuration > Vendors > Meta
- Save
- Trigger a test conversion
- Verify it appears in Meta's Test Events tab
- Remove the test code when you're ready to go live
How It Works
When a visitor converts:
- CleanClicks captures the
fbclid(Facebook Click ID) from the landing page URL - The conversion event is sent server-side to Meta's Conversions API with the fbclid
- Meta matches the conversion to the original ad click
- Customer email is sent as a SHA-256 hash for Enhanced Matching
Meta's Conversions API also receives:
- Event name and value
- User agent and IP information
- Attribution parameters
CCPA / Limited Data Use
For visitors in jurisdictions where Limited Data Use applies, CleanClicks automatically sends data_processing_options: ["LDU"] to Meta. This tells Meta to restrict how it processes that visitor's data, in compliance with CCPA regulations.
Troubleshooting
| Issue | Solution |
|---|---|
| Token rejected | Verify the token has ads_management and ads_read permissions. Regenerate if needed. |
| Events not in Events Manager | Check the Pixel ID is correct. Use a Test Event Code to verify delivery. |
| "Invalid Pixel ID" error | The Pixel ID should be a numeric string (e.g., 123456789012345). No letters or dashes. |
| Events showing but no conversions | Make sure you have a matching conversion event configured in Meta Ads Manager. |
Next: TikTok
Last updated Apr 1, 2026
Built with Documentation.AI