How to exclude the fbclid parameter from Google Analytics reports?

In this article, we describe two ways to disconnect the fbclid parameter from Google Analytics reports — manually or automatically.

Measure CPO and ROAS in GA4

Automatically link your Ad Platforms cost data to Google Analytics 4 conversion data, so you can analyze your marketing KPIs and make fully informed decisions

Start Free Trial
Measure CPO and ROAS in GA4

What is fbclid and how does it interfere with Google Analytics reports?

The Facebook Click Identifier (fbclid) is used for analyzing outgoing traffic and collecting user data. The click identifier from Google Ads (gclid) is analogous. The main difference is that the fbclid parameter creates difficulties when working with standard reports in Google Analytics.

Though in the official help documentation there is no description of this parameter, most experts agree that Facebook uses it to bypass restrictions on collecting users’ personal information. You can find more details about it in articles on the Naked Security blog by Sophos. If you hover your cursor over any external link on Facebook, you’ll be able to see an fbclid in the URL address:

fbclid tag in the social network

It’s known that this parameter:

  • is transferred both with advertising links and with all external links from Facebook
  • does not prevent the work of UTM tags

With the appearance of this parameter, standard reports in Google Analytics have deteriorated. Whereas previously there was one line for the page, now there’s also a separate line for the fbclid.

To avoid duplication, it’s necessary to exclude the fbclid parameter in Google Analytics settings (instructions below).

How this parameter looks in a report:

fbclid tag in Google Analytics report

With OWOX BI Pipeline, you can collect complete statistics for your Facebook campaigns automatically. Combine your data from Facebook ad campaigns, Google and Bing ads, and other sources with a free trial.

bonus for readers

20 Steps to Successful Marketing Analytics

Download now

How to work with data from the previous period

Bad news: It’s impossible to remove a parameter from a previous period in Google Analytics. However, there’s a life hack for working with statistics for previous periods.

To filter all views of one page (with and without an fbclid parameter) from already collected data, we need to use advanced search features.

Site Content report in Google Analytics

Let’s look at how to receive a report on the homepage. We’ll choose “Matching RegExp” and enter the following formula in the search field:

^\/$|^\/\?fbclid

Regular Expressions field

After applying this expression, we can work with those reports from the previous period that we’ve applied this filter to. In the table, there will be lines only for the homepage, and it’s possible to have a look at the general statistics in the first line after table headings. 

Note: If you use additional parameters that are displayed in the report, regular expressions will need to be finished under these parameters.

How to clean Google Analytics reports of the fbclid parameter in future sessions

In Google Analytics, it’s possible to disconnect the fbclid parameter manually or automatically.

To remove it manually, go to View Settings in the admin panel:

URL Query Parameters

In the Exclude URL Query Parameters field, write “fbclid.” If the field was already filled, then add a comma followed by “fbclid” after the last value and save the changes. Now the fbclid parameter will not appear in future sessions of this view in reports.

If you use several views, you’ll need to repeat the procedure for each one.

Note: Don’t forget that it’s recommended to make a reserve view without filters and exceptions.

For automating this process, you can also use a Python script by Dmitry Osiyuk that you can download from his blog.

Key takeaways

The fbclid parameter creates difficulties in working with Google Analytics reports by duplicating lines. However, there’s a solution: you can filter parameters when working with historical data and exclude them from future sessions.
If you still have any questions, ask them in the comments below :)

Useful links

Review your analytics in real-time and act on it

FAQ

Expand all Close all
  • How does Facebook's FBCLID parameter affect Google Analytics tracking?

    The FBCLID parameter is added to URLs when users click on links shared on Facebook. This parameter can affect Google Analytics tracking by altering the source and medium information of the incoming traffic, making it difficult to accurately attribute the source of the traffic. To properly track FBCLID traffic in Google Analytics, it's recommended to use UTM parameters to overwrite the FBCLID source with the correct source information.
  • Are there any negative impacts of FBCLID on Google Analytics data?

    Yes, FBCLID can have negative impacts on Google Analytics data. Since FBCLID can alter the source and medium information, it may lead to incorrect tracking and attribution of traffic sources. This can cause confusion in understanding the performance of different marketing campaigns and channels. Therefore, it's crucial to properly handle FBCLID traffic through UTM parameters or other tracking methods to ensure accurate data analysis in Google Analytics.
  • How can I exclude FBCLID in Google Analytics reports and analysis?

    To exclude FBCLID traffic from Google Analytics reports and analysis, you can create a filter in your Google Analytics view. Utilizing a custom filter, you can remove or override the FBCLID parameter from the URL, allowing Google Analytics to attribute the traffic correctly. Additionally, using UTM parameters in your URLs instead of relying solely on FBCLID can also help in excluding FBCLID from the Google Analytics reports.