Skip to main content
Doctolib → GA4Integration guide

Connecting Doctolib to GA4

Doctolib is a patient-facing marketplace as much as a booking system, so a large share of the appointments it produces were found by Doctolib rather than by you. GA4 is where the business goes to understand what happened, which makes an unattributed conversion there expensive in decisions rather than in ad spend. The join between them succeeds or fails on one thing: whether the GA4 client_id reaches the Doctolib appointment before the conversion happens, because GA4 can only match a conversion it can tie back to a click it recognizes.

Free30 minutesNo obligation

Specific to this pair

Doctolib and GA4: measure the hand-off, not the patient

GA4 can only see the click on your site's Doctolib booking button or widget, recorded as a booking hand-off event and optionally a key event. Do not send attended appointments through Measurement Protocol against a client_id; that ties patient visits to browsing history. Strip condition-revealing page paths, and keep attended counts outside GA4.

GA4 can see exactly one Doctolib moment: the click on your site's booking button or widget before the visitor leaves for Doctolib. Record it as an event named for the booking hand-off, mark it as a key event if you like, and that is the conversion GA4 can honestly report. GA4 cannot follow the visitor onto Doctolib's domain; cross-domain measurement needs your tag on the other side, and Doctolib's pages are not yours to tag.

Do not try to close the loop with Measurement Protocol. Sending attended appointments to GA4 against a client_id ties a known patient's visit to their browsing history inside an analytics tool, which is health data under GDPR, and nothing in a standard GA4 setup is built to hold that lawfully. If you want attended numbers next to GA4, keep them as a monthly count per practice in a spreadsheet or a Looker Studio blend, not as GA4 events.

Check what the booking-click event carries before marking it as a key event. The page path rides along with it, and a path like /dermatology/acne-treatment puts a condition next to the click. Consent applies too: in the EU, GA4 should set its cookies only after the visitor accepts analytics, so the booking-click count is the consented share of real clicks, not all of them.

Doctolib → GA4 · what breaks

Why this join usually fails — Doctolib → GA4

  1. 01

    The GA4 client_id never reaches Doctolib

    Booking happens on Doctolib's domain, and directory bookings never touch any property of yours at all.

  2. 02

    Marketplace demand read as campaign performance

    Doctolib's directory fills calendars independently of anything you spend. Pool the two and your advertising takes credit for the platform's own reach.

  3. 03

    Everything lands under (direct)/(none)

    The classic Measurement Protocol symptom, and it always means the same thing: the client_id was missing or wrong, so GA4 had no session to attach the event to and invented a new user.

  4. 04

    Nothing reconciles afterwards

    GA4 DebugView shows events arriving with their parameters, and Realtime confirms the user and session they attached to. Neither tells you whether you are double-counting — for that, compare GA4's conversion count against the source system's record for the same window.

Doctolib → GA4 · the fix

What working looks like — Doctolib → GA4

  • The GA4 client_id on every appointment

  • Conversions arriving in GA4

    Conversions appear in GA4 attributed to the original session's source and medium, so acquisition reporting reflects what actually drove revenue.

  • Reconciled against the source

Doctolib → GA4 · architecture

How Doctolib and GA4 actually connect

  1. 1

    Doctolib holds the truth

    Directory-sourced patients are real and are not evidence that your advertising worked. Under European rules the consent position on health data is also stricter than most advertisers assume.

  2. 2

    GA4 needs a click to match

    GA4 needs the client_id to attach a server event to the user and session that produced the click. Without it there is no attribution to inherit and the event is orphaned.

  3. 3

    The identifier is the bridge

    The GA4 client_id, captured at the visit and carried into the Doctolib appointment.

  4. 4

    The event source decides reliability

    Send attended appointments as a count, per practice, with no specialty or reason-for-visit field.

  5. 5

    Deduplication at the destination

    GA4 has no built-in deduplication for Measurement Protocol. If the browser also sends the event, it counts twice. The only reliable approach is to decide per event which side sends it, and enforce that decision — GA4 will not protect you from your own duplicates.

Doctolib → GA4 · normal or broken

Working vs. broken, side by side — Doctolib → GA4

Normal, not a fault

  • The GA4 client_id present on the appointment

  • Sent from your practice system

  • Deduplicated correctly

    GA4 has no built-in deduplication for Measurement Protocol. If the browser also sends the event, it counts twice. The only reliable approach is to decide per event which side sends it, and enforce that decision — GA4 will not protect you from your own duplicates.

  • Reconciles with the source

Actually broken

  • The GA4 client_id missing on most records

    Booking happens on Doctolib's domain, and directory bookings never touch any property of yours at all.

  • Sent from the browser

    Doctolib's directory fills calendars independently of anything you spend. Pool the two and your advertising takes credit for the platform's own reach.

  • Counted twice, or not at all

    The classic Measurement Protocol symptom, and it always means the same thing: the client_id was missing or wrong, so GA4 had no session to attach the event to and invented a new user.

  • Nobody has reconciled it

Doctolib → GA4 · diagnose

Diagnostic order — Doctolib → GA4

  1. 01

    Count appointments carrying the GA4 client_id

  2. 02

    Follow one real conversion end to end

  3. 03

    Split appointments by booking origin

    Own site versus directory. Without it the paid numbers cannot be interpreted in either direction.

  4. 04

    Check whether server events carry a session and a source

    In GA4 Realtime or DebugView, find the event and look at its session and traffic source. A brand-new user with no source on every server event is the missing-client_id signature.

  5. 05

    Read the match rate, not the success message

    GA4 DebugView shows events arriving with their parameters, and Realtime confirms the user and session they attached to. Neither tells you whether you are double-counting — for that, compare GA4's conversion count against the source system's record for the same window.

Doctolib → GA4 · prove

How it gets proven — Doctolib → GA4

Source of truth

Attended appointments in your own system, split by whether the patient came through your site or through Doctolib's directory.

  • The GA4 client_id confirmed present on a live appointment.
  • Server events confirmed in DebugView attaching to an existing session with the original traffic source intact.
  • Own-site attended appointments reconciled against imported conversions, with directory volume reported separately.

Doctolib → GA4 · free audit

What we check in the free audit

  • Count appointments carrying the GA4 client_id
  • Follow one real conversion end to end
  • Split appointments by booking origin
  • Check whether server events carry a session and a source
  • Read the match rate, not the success message

Checked against

Attended appointments in your own system, split by whether the patient came through your site or through Doctolib's directory.

Get my free conversion tracking audit

Free30 minutesNo obligation

Doctolib → GA4 · when not to buy

When you don't need this — Doctolib → GA4

  • Measure identifier coverage yourself first — pull your last hundred appointments and count how many carry the GA4 client_id.
  • If the directory fills your calendar already, the honest recommendation is to skip advertising rather than to measure it better.
  • GA4 is reporting, not bidding. If your problem is ad platform optimization, fix the ad platform destination first — GA4 will not change what any campaign does.

Doctolib → GA4 · what we deliver

What gets built — Doctolib → GA4

  • Identifier capture into Doctolib

    Attribute only bookings that began on your own site, and then only with a consented identifier and no clinical detail attached.

  • Event source: your practice system

    Send attended appointments as a count, per practice, with no specialty or reason-for-visit field.

  • Dispatch to GA4

    Measurement Protocol events with the client_id, session_id and the correct measurement ID and API secret, sent server-side.

  • Reversals where they exist

    Cancellations and no-shows reverse.

Written guarantee

95%+ tracking accuracy

Measured against Attended appointments in your own system, split by whether the patient came through your site or through Doctolib's directory.. Miss it and we keep working at no cost.

Get my free conversion tracking audit

From $400 · See packages

FAQ

Doctolib → GA4 questions, answered

Not the booking itself, which happens on Doctolib's domain. GA4 can track clicks on your Doctolib button or link, which is the closest honest proxy.

Free · 30 min

Get Doctolib and GA4 joined properly

Free30 minutesNo obligation