⚡
claimr
  • Getting started
    • Create an account
    • Sign in to your account
    • Reset password
    • Edit profile
  • ⚡️claimr core components
  • Team roles and management
  • Campaigns
    • Create new campaign
    • Campaign settings
  • Groups
    • Create new group
    • Group settings
  • Quests
    • Create new quest
    • Quest settings
  • Tasks
    • Create new task
    • Task settings
    • Telegram tasks
    • X (Twitter) tasks
    • TikTok tasks
    • Discord tasks
    • YouTube tasks
    • Web3 tasks
      • Connect a wallet
      • Transactions count
      • Wallet balance
      • Token balance
      • NFT balance
      • Link3 balance
      • Mint an NFT (721)
      • Mint an NFT (1155)
      • Verify transactions
    • PoW tasks
    • HTTP request tasks
    • Referral tasks
    • Form tasks
    • Poll tasks
    • Events tasks
    • API tasks
  • Widget
    • Publish campaign
    • Widget configurations
    • Widget attributes
    • Integrate claimr widget into your website
    • claimr widget integrations
      • Google Analytics integration
      • Google Analytics Client ID
      • Google Tag Manager integration
      • HotJar integration
  • Rewards
    • Reward settings
    • Custom rewards
  • Events
    • Daily check-ins
    • Challenges
    • Ranks
    • KOLs
  • Codes
    • Secret codes
    • Invite codes
      • Enter invite code task
      • Claim invite code task
    • Gift codes
  • Test users
  • Pop-ups
    • Into pop-up
    • Completion pop-up
  • API
    • API token
    • API methods
    • User token
  • Webhooks
    • Set up webhooks
    • Assign webhooks
    • Webhook scopes
  • SDK
  • Forms
    • Create forms
    • Form settings
    • Pages
    • Blocks
    • Quizzes
  • Data analytics
    • Activity
    • PoW analytics
    • User information
    • Failed actions
    • Issues analytics
  • How to
    • Create X campaign
    • Create Discord campaign
    • Integrate claimr widget into dApp
    • Integrating claimr widget into Telegram mini app
    • Customize user experience with tags and attributes
    • Add custom points to users
  • UX requirements
    • Campaign UX requirements
    • Group UX requirements
    • Quest card UX requirements
    • Quest UX requirements
    • Task UX requirements
    • User progress UX requirements
    • Pop-ups UX requirements
    • Interactive components UX requirements
Powered by GitBook
On this page
  • Why Client ID?
  • Automatic Client ID retrieval (recommended)
  • Manual Client ID passing (alternative)
  • Verification

Was this helpful?

  1. Widget
  2. claimr widget integrations

Google Analytics Client ID

Enhance your claimr widget's Google Analytics integration by passing the GA4 Client ID.

Why Client ID?

claimr can automatically retrieve the Google Analytics Client ID for more accurate user tracking within your widget. This provides a more complete picture of user behavior in your Google Analytics 4 reports.

  • Improved cross-session tracking: Accurately track user behavior even if they close and reopen the browser or switch devices.

  • More accurate user counts: Avoid counting the same user multiple times.

  • Richer data in Google Analytics: Get a complete picture of user engagement within your claimr widget.

Automatic Client ID retrieval (recommended)

Once you integrated your claimr widget with Google Analytics 4 (using either the data-ga4 attribute in your embed script or the ga4 URL parameter, as described in Google Analytics integration article), claimr usually finds the Client ID automatically.

How it works: claimr checks for the standard Google Analytics cookie (_ga). This cookie contains the Client ID in the format GA1.1.USER_ID. claimr extracts the USER_ID portion and uses it for tracking. You generally do not need to add any extra code.

Manual Client ID passing (alternative)

If the automatic retrieval doesn't work, or if you need more control, you can manually pass the Client ID using a URL parameter:

  • Add ?ga4cid=USER_ID to your claimr campaign URL, replacing USER_ID with the actual Client ID from the _ga cookie.

Example

https://campaign?ga4cid=123456789.987654321

Replace 123456789.987654321 with the actual Client ID and https://campaign with your base campaign URL).

Verification

To check the integration, you can use tools from Google Analytics.

PreviousGoogle Analytics integrationNextGoogle Tag Manager integration

Last updated 3 months ago

Was this helpful?