Conversion Pixel
The Conversion Pixel records a conversion event — a sale, lead, signup, or custom action — and attributes it back to the click that brought the visitor in. Drives revenue, ROI, ROAS, EPC, and conversion-rate reports.
You install it on thank-you pages, order-confirmation pages, post-signup pages — anywhere you want to mark "this visitor completed the action."
How Conversions Are Attributed
The conversion pixel needs to know which click to attribute the conversion to. It looks for the click ID in three places, in priority order:
- URL query parameter —
?click_id=...or?_ct=...on the thank-you page's URL. sessionStorage._aida_cid— set by the Tracking Pixel earlier in the funnel. Works only if the thank-you page is on the same origin (same domain) as the landing page.data-click-idattribute — manual override on the script tag, when your server-side code can interpolate the click ID.
If none of these is present, the pixel logs a warning to the browser console and doesn't fire. (You'd see "no click_id found; conversion not recorded".)
How to Install
Option A: JavaScript pixel (recommended)
Easiest. Drops into any page, reads click_id automatically, no template variables.
- Open the link's edit page.
- Scroll to Pixels → Conversion Pixel.
- Pick the Action Type (sale / lead / signup / custom) and optional Revenue amount.
- Copy the snippet.
- Paste in the
<body>of your thank-you page (anywhere — no<head>requirement).
<script async src="https://click.yourdomain.com/embeds/conversion.js"
data-action-type="sale"
data-revenue="49.99"
data-transaction-id="ORD-12345"></script>
The script reads click_id from sessionStorage or URL. The conversion is recorded.
Option B: HTML img pixel (no JS)
Use when JavaScript isn't available, or when you can interpolate click_id server-side and want a no-JS solution.
In the Pixels section, expand Advanced: HTML pixel (no JavaScript). Copy:
<img src="https://click.yourdomain.com/api/clicktracking/conversions/pixel?click_id=YOUR_CLICK_ID&action_type=sale&revenue=49.99"
width="1" height="1" alt="" style="display:none" />
You'll need to replace YOUR_CLICK_ID with the actual click ID. Most likely your e-commerce platform or CMS lets you template it from a session variable.
Conversion Pixel Fields
The customizations on the Conversion Pixel form:
Action Type
What kind of conversion this is. Affects how the conversion is grouped in reports.
| Value | Use For |
|---|---|
| sale | Completed purchase / order |
| lead | Form submission, contact request, demo booking |
| signup | Free account creation, newsletter signup |
| custom | Anything else; pair with action_name to label it |
Revenue
The dollar value of this conversion. Used in revenue, ROI, EPC reports.
Set to 0 (or leave blank) if the conversion isn't directly revenue-bearing — e.g. a lead form that hasn't been valued yet. You can leave revenue blank in the pixel and update the click row later via API or postback.
Action Name
Optional human-readable label, especially useful with action_type=custom. Free-form text.
Examples: webinar_signup, whitepaper_download, consultation_booking.
Transaction ID
Optional unique transaction reference from your e-commerce or CRM system. Stored on the conversion row for cross-system reconciliation.
Examples: ORD-12345, STRIPE-pi_abc123, INVOICE-2026-001.
Use this to deduplicate conversions if your thank-you page can be refreshed (the pixel fires once per page load, but having a transaction_id lets you detect duplicate firings server-side).
Order ID
Optional separate order identifier when your e-commerce platform distinguishes orders from transactions. Stored alongside transaction_id.
What the Pixel Does
When the script runs:
- Find the script tag in the document.
- Read
data-action-type,data-revenue, etc. attributes from it. - Look for
click_id(URL → sessionStorage → data-attr). - If found, fire a 1×1 GIF request to:
https://click.yourdomain.com/api/clicktracking/conversions/pixel?click_id=...&action_type=...&revenue=...
- The server records a row in
clicktracking_conversions, then rolls totals onto the click row (revenue,conversions_count,first_conversion_at).
The pixel is fire-and-forget — the page doesn't wait for the response. If the request fails (network error, ad blocker), the conversion is missed but the page UX is unaffected.
Server-to-Server Postback (Alternative)
If you can't paste a pixel on the thank-you page (e.g. payment is processed externally and you only get a webhook), use a server-to-server postback instead.
In your link's advanced settings, set:
https://click.yourdomain.com/api/clicktracking/conversions/postback
Your backend POSTs to this URL after a conversion with JSON body:
{
"click_id": "550e8400-e29b-41d4-a716-446655440000",
"action_type": "sale",
"revenue": 49.99,
"transaction_id": "ORD-12345"
}
Same effect as the pixel, but server-driven.
Multiple Conversions per Click
A single click can have multiple conversions (e.g. a tripwire purchase, then an upsell, then a cross-sell). Each fires the conversion pixel separately, each gets its own row in clicktracking_conversions. The click row's revenue and conversions_count columns accumulate.
The first conversion's timestamp is stored as first_conversion_at; the time between click and first conversion is time_to_conversion (in seconds).
Reporting
Conversion data shows up in:
- Click Log — per-click columns:
revenue,conversions_count,first_conversion_at,time_to_conversion. - Reports — aggregate views: total conversions, total revenue, conversion rate (CR), revenue per click (EPC), return on ad spend (ROAS), profit (revenue − cost), ROI ((revenue − cost) / cost).
Group reports by source, country, device, etc., to find your highest-converting traffic.
Worked Example: E-Commerce Funnel
Your funnel: Facebook Ad → Landing Page → Add to Cart → Checkout → Order Confirmation.
Step 1: Tracking Pixel on Landing Page + Add-to-Cart + Checkout pages — captures engagement and stashes click_id in sessionStorage.
Step 2: Conversion Pixel on Order Confirmation:
<script async src="https://click.yourdomain.com/embeds/conversion.js"
data-action-type="sale"
data-revenue="{{ order.total }}"
data-transaction-id="{{ order.id }}"></script>
(Your platform's templating syntax substitutes order.total and order.id.)
Step 3: Watch your reports. After a few clicks/conversions you'll see:
- Per-click revenue
- Conversion rate (% of clicks that became sales)
- ROI per ad campaign (revenue − cost) / cost
- ROAS per source
- Average time-to-conversion (how long from click to sale)
If your post-purchase upsell page has its own conversion pixel with action_type=sale, its revenue stacks on the click row.
Troubleshooting
| Symptom | Cause | Fix |
|---|---|---|
| Console says "no click_id found" | The pixel can't find click_id in URL or sessionStorage | Pass ?click_id=... on the thank-you page URL OR ensure sessionStorage was set on the same-origin landing page earlier |
| Conversion fires but isn't on the click row | Click row was deleted (TTL hit, soft-delete) OR click_id is for a different tenant | Verify click_id matches a real click in the Click Log |
Revenue is 0 in reports despite conversions | data-revenue not set or set to non-numeric value | Confirm the script tag has a numeric data-revenue="..." |
| Duplicate conversions on a refresh | The thank-you page reloaded and re-fired the pixel | Use server-side postback OR check transaction_id server-side and dedupe |
Next Steps
- Tracking Pixel — Sets up
_aida_cidin sessionStorage so this pixel can read it - Click Log — See per-click revenue and conversion summaries
- Reports — Aggregate revenue, ROI, ROAS, EPC, conversion rate
- Links — Server-to-server postback URL configuration