Facebook data source
Getting started
- Inside the admin panel navigate to the Data Sources page and click + NEW on the top right corner.
- Choose Facebook from the list.
- Click Authenticate with Facebook and go through the authentication flow.
- Select accounts which cost data you would like to import.
- Click Save.
UTM tagging best practices
The following setup will help improve cost data stitching and will allow seeing beautiful campaign name, ad set name and ad name inside the reports.
utm_source=facebook&
utm_medium=paid-social&
utm_campaign={{campaign.id}}&
utm_term={{adset.id}}&
utm_content={{ad.id}}
Please, avoid using name-based parameters like , or inside your UTM tags. If your campaign, ad set or ad names will be changed, the parameters will refer to the original names while SegmentStream will use new names. This will lead to a problem in cost allocation for your sessions. You can find more info about this here.
Supported dynamic URL parameters
By default Facebook allows to use a lot of dynamic URL tagging parameters to track campaigns.
SegmentStream supports the following parameters:
Name | Description |
---|---|
{{ad.id}} |
The unique ID of the ad. |
{{adset.id}} |
The unique ID of the ad set. An ad set is a group of ads that share the same budget, schedule, delivery optimization and targeting. |
{{campaign.id}} |
The unique ID number of the ad campaign. A campaign contains ad sets and ads. |
{{ad.name}} |
The name of the ad |
{{adset.name}} |
The name of the ad set. An ad set is a group of ads that share the same budget, schedule, delivery optimization and targeting. |
{{campaign.name}} |
The name of the ad campaign. A campaign contains ad sets and ads. |
{{site_source_name}} |
Depending on where the ad appeared this parameter has four possible values.fb - Facebookig - Instagrammsg - Messengeran - the Audience Network |
{{placement}} |
Depending on where the ad appeared this parameter has possible values.Facebook_Mobile_Feed Facebook_Right_Column Facebook_Instant_Articles Facebook_Instream_Video Facebook_Marketplace Instagram_Stories Instagram_Feed Instagram_Explore Messenger_Inbox Messenger_Stories Facebook_Desktop_Feed an (for Audience Network)Others (for all other placements) |
Default source/medium
Facebook allows running ads that do not lead directly to your website (for example Facebook page promo, Facebook post promo, events promo, etc). This means that these types of campaigns can not have UTM-params and it is not possible to import them into Google Analytics due to limitations that require all imported costs to have campaign source and medium defined.
As a workaround, you can define default UTM-source and UTM-medium for your Facebook data source to see costs for these campaigns inside your Google Analytics account.
This document was last updated on August 17, 2020. If you notice any gaps, outdated information or simply want to leave some feedback to help us improve our documentation, please let us know!