Basic GA4 Web Data Stream Setup

Valid parameters for configurations settings

The following table lists pre-defined parameters and which products you can use them with (marked by an x).

NameTypeDefault valueDescriptionAdsGA4Merchant Center
ads_data_redactionbooleanfalseConsent mode parameter to redact ad-click identifiers (e.g. &gclid, &dclid, &wbraid, etc.) from all requests when consent is denied.x
allow_ad_personalization_signalsbooleantrueSet to false to disable advertising personalization
allow_google_signalsbooleantrueThe default value is true. To disable all advertising features, set allow_google_signals to false.xx
allow_interest_groupsbooleantrueA privacy sandbox API setting to allow opting out of storing interest group
campaign_contentstringundefinedUsed for A/B testing and content-targeted ads. Use campaign_content to differentiate ads or links that point to the same URL. Note: Setting this value will override the utm_content query parameter. xx
campaign_idstringundefinedUsed to identify which campaign this referral references. Use campaign_id to identify a specific campaign. Note: Setting this value will override the utm_id query parameter. xx
campaign_mediumstringundefinedUse campaign_medium to identify a medium such as email or cost-per-click. Note: Setting this value will override the utm_medium query parameter. xx
campaign_namestringundefinedUsed for keyword analysis. Use campaign_name to identify a specific product promotion or strategic campaign. Note: Setting this value will override the utm_name query parameter. xx
campaign_sourcestringundefinedUse campaign_source to identify a search engine, newsletter name, or other source. Note: Setting this value will override the utm_source query parameter. xx
campaign_termstringundefinedUsed for paid search. Use campaign_term to note the keywords for this ad. Note: Setting this value will override the utm_term query parameter. xx
client_idstringA randomly generated value for each user.Pseudonymously identifies a browser instance. By default, this value is stored as part of the first-party Analytics cookie with a two-year expiration. x
content_groupstringundefinedContent groups let you categorize pages and screens into custom buckets. Learn more about content groups. x
conversion_linkerbooleantrueUse this parameter to opt out of conversion linking for Ads and Floodlight. When set to false, you can opt-out of conversion linking.x
cookie_domainstring'auto'Specifies the domain used to store the analytics cookie. To set the cookie without specifying a domain, set to 'none'. Set to 'auto' (the default value) to set the cookie to the top level domain plus one subdomain (eTLD +1). For example if cookie_domain is set to 'auto' would use for the domain, and would also use for the
cookie_expiresnumber63072000Every time a hit is sent to Google Analytics, the cookie expiration time is updated to be the current time plus the value of the cookie_expires field. This means that if you use the default value time of two years (63072000 seconds), and a user visits your site every month, their cookie will never expire. If you set the cookie_expires time to 0 (zero) seconds, the cookie turns into a session based cookie and expires once the current browser session ends. Caution: If you set the cookie to expire too quickly, you will inflate your user count and decrease the quality of your
cookie_flagsstringundefinedAppends additional flags to the cookie when set. Flags must be separated by semicolons. See write a new cookie for some examples of flags to
cookie_pathstring'/'Specifies the subpath used to store the Google tag
cookie_prefixstringundefinedSpecifies a prefix to prepend to ads and analytics cookie names. For example, you can rename ads cookies starting with _gcl_awto <your-prefix>
cookie_updatebooleantrueWhen cookie_update is set to true:GA4 and Merchant Center update cookies on each page load. This will update the cookie expiration to be set relative to the most recent visit to the site. For example, if cookie expiration is set to one week, and a user visits using the same browser every five days, the cookie expiration will be updated on each visit and will effectively never expire.Ads and Floodlight update cookies with the original expiration date, so it is still relevant to the first visit.When set to false, cookies are not updated on each page load. This has the effect of cookie expiration being relative to the first time a user visited the
customer_lifetime_valuestringundefinedSpecifies a time frame in which a customer counts as a repeated customer.x
groupsstringundefinedYou can create a group of targets (e.g. products, accounts, and properties) and then route events to that group. To send events to a group, you need to set the send_to parameter in an event
ignore_referrerbooleanfalseSet to true to indicate to Analytics that the referrer shouldn't be displayed as a traffic source. Learn when to use this field. xx
languagestringnavigator.languageSpecifies the language preference of the
new_customerbooleanundefinedReports new customer acquisitions from your Ads campaigns. See the Google Ads help for implementation details.x
page_hostnamestringlocation.hostnameSets the hostname of your site. This parameter allows you to override the automatic value. xx
page_locationstringdocument.locationSpecifies the full URL of the page. This parameter allows you to override the automatic
page_pathstringlocation.pathnameSpecifies the page path (the string after /).This parameter allows you to override the automatic value. xx
page_referrerstringdocument.referrerSpecifies which referral source brought traffic to a page. This value is also used to compute the traffic source. This parameter allows you to override the automatic
page_titlestringdocument.titleThe title of the page or document. This parameter allows you to override the automatic
send_page_viewbooleantrueSet to false to prevent the default snippet from sending a page_viewevent. x
screen_resolutionstringwindow.screenSpecifies the resolution of the screen. Should be two positive integers separated by an x. For example, for an 800px by 600px screen, the value would be "800×600". Calculated from the user's window.screen value. xx
server_container_urlstringundefinedSpecifies the URL of a tagging server. Learn more about server-side
user_idstringundefinedSpecifies a known identifier for a user provided by the site owner/library user. It must not itself be PII (personally identifiable information). The value should never be persisted in Google Analytics cookies or other Analytics provided storage. Character limit = 256. x
user_propertiesobjectundefinedUser properties are attributes that can be used to describe segments of your user base, such as language preference or geographic location. Up to 25 additional user properties can be set per project. Learn how to set up user properties. x
Scroll to Top