The ACF Forms integration tracks submissions from front-end forms built with the acf_form() function in Advanced Custom Fields. These forms don't have a settings screen, so you turn on tracking right in your code by adding a conversion_bridge key to the settings you already pass to acf_form().
Only forms that include the conversion_bridge key are tracked. That way a profile edit form or any other form that isn't a conversion stays out of your reports.
Setup Instructions
Step 1: Enable the Integration
- In your WordPress admin, go to Settings > Conversion Bridge > Integrations
- Find ACF Forms in the list of available integrations
- Turn the integration on and click Save Changes
Step 2: Add Tracking to Your Form
Add a conversion_bridge key to the settings array for each form you want to track:
acf_form( array(
'post_id' => 'new_post',
'new_post' => array(
'post_type' => 'quote_request',
'post_status' => 'publish',
),
'conversion_bridge' => array(
'label' => 'Quote Request',
'value' => 50,
'googleads' => 'AbC123xyz',
),
) );
If you don't need a custom label, value, or ad platform IDs, you can set the key to true and the form is tracked with its defaults:
'conversion_bridge' => true,
The same key works with forms you register using acf_register_form():
add_action( 'acf/init', function () {
acf_register_form( array(
'id' => 'quote-form',
'post_id' => 'new_post',
'new_post' => array( 'post_type' => 'quote_request' ),
'conversion_bridge' => array(
'label' => 'Quote Request',
'value' => 50,
),
) );
} );
As with any ACF front-end form, acf_form_head() needs to run before your page outputs anything, or the form won't save.
Tracking Settings
Every setting inside conversion_bridge is optional:
| Setting | What it does |
|---|---|
label |
The conversion label sent to your platforms. Defaults to the form's id (acf-form if you didn't set one). |
value |
The conversion value. Use a number like 50 or a number with a currency like 50 USD. |
googleads |
Your Google Ads conversion label. Use only the part after the slash, not the AW- ID. |
linkedin |
Your LinkedIn Ads conversion ID. |
x |
Your X Ads conversion ID. |
fields |
Tells Conversion Bridge which fields hold the visitor's email, name, and so on. See Enhanced conversion data. |
The platform IDs only matter for platforms you have turned on in Conversion Bridge. Platforms like Meta and GA4 don't need an ID and record the form as a lead or form submission on their own. Learn more about conversion labels and values.
ACF encrypts your form settings before it adds them to the page, so visitors can't change the label, value, or IDs you set.
How It Works
- When a visitor submits a tracked form and ACF saves it, Conversion Bridge records the conversion.
- ACF sends the visitor back to the form page (or to the page you set in
return). The conversion is sent to your platforms when that page loads. - If you set
returnto an empty value, ACF doesn't redirect, and the conversion is sent on the same page load. - If
returnsends the visitor to a different website, the conversion is only sent if they come back to your site within an hour, so keepreturnon your own site for tracked forms. - When the form creates a new post, the new post ID is used as the transaction ID so a submission is never counted twice. Forms that edit an existing post don't send a transaction ID, because the ID would be the same on every edit.
Tracked Data
Every event includes a conversion label and conversion value. Learn more about conversion labels and values.
Form Submission
id-- The form'sidsettingtitle-- The form'sidsettinglabel-- Conversion labeltransaction_id--acf-plus the new post ID (only for forms that create a new post)
Enhanced conversion data
Conversion Bridge looks through the submitted fields for the visitor's contact details. Email fields are found by their field type. Other details are found by field label or name, such as "First Name", "Last Name", "Phone", "City", "State", "Zip", or "Country". This data is only used by platforms that support enhanced conversions.
_email-- Email address_first_name-- First name_last_name-- Last name_phone-- Phone number_city,_state,_zip,_country-- Address details
If your field names don't match these, point Conversion Bridge to the right fields with the fields setting. You can use the field name or the field key, and it works for fields inside a group or repeater too:
'conversion_bridge' => array(
'label' => 'Quote Request',
'fields' => array(
'_email' => 'contact_address',
'_first_name' => 'field_64f1a2b3c4d5e',
),
),
Pass UTM Parameters and Ad Click IDs
Each post created by a tracked form stores the visitor's campaign data as post meta. You can read these with get_post_meta() in your templates, exports, or any code that sends leads to a CRM:
_cb_utm_source,_cb_utm_medium,_cb_utm_campaign,_cb_utm_term,_cb_utm_content_cb_gclid,_cb_fbclid, and the other ad click IDs from the visitor's journey_cb_ad_platform-- The ad platform the click came from, such as "Google Ads"
You can also save a value into one of your own ACF fields. Set a text field's Default Value to a Conversion Bridge tag, such as {cb_utm_source} or {cb_gclid}, and Conversion Bridge fills in the real value when the form loads and again when it's submitted. To keep the field out of sight, add acf-hidden to the field's Wrapper Attributes > class setting. This works on fields at the top level of the form, not on fields inside a group or repeater.
Ad click IDAn ad click ID is a code an ad platform adds to your link when someone clicks your ad. It lets you connect a later conversion back to the exact ad. tags only fill in when the visitor has granted marketing consent. See Pass UTM Parameters and Ad Click IDs into Forms for the full list of tags.
Conversion Journey
Posts created by a tracked form are linked to the visitor's conversion journey, so you can see the pages they visited before they filled out the form. Open the post in your WordPress admin and scroll down to the Conversion Journey box.