Connecting Moodle to Amplitude
Moodle is self-hosted open-source learning management, used mostly by institutions where enrolment and payment are usually two different systems. Amplitude is built around behavioural cohorts, which makes the identity resolution and the event taxonomy load-bearing in a way they never are for an ad pixel. The join between them succeeds or fails on one thing: whether the user ID and device ID pair reaches the Moodle enrolment before the conversion happens, because Amplitude can only match a conversion it can tie back to a click it recognizes.
Free30 minutesNo obligation
Specific to this pair
Moodle in Amplitude: learning cohorts tied to the paid enrolment
Forward selected Moodle events, like enrolled, activity completed and course completed, server-side through an event observer plugin or scheduled export, using the Moodle user ID as user_id. Send paid enrolments with price only for payment-based methods, give free enrolments a different event type, and set insert_id from the record ID.
Amplitude suits a Moodle provider asking product questions: do learners from a given campaign finish the course, how fast, and do completers buy the next one. Moodle already raises those events internally (user enrolled, activity completed, course completed) through its event system, so the build is an event observer plugin or scheduled export that forwards selected events server-side, not a browser SDK bolted into Moodle's theme.
Identity is the decision. Use the Moodle user ID, or an idnumber you control, as Amplitude user_id, and pass a device ID from the public marketing site into account creation if you want pre-signup sessions merged with the learner. Single sign-on complicates this: an institutional login can create the Moodle user without ever passing through your site, so there is no device to merge. Send a paid enrolment event with price and quantity populated only for payment-based methods, and give free and cohort-synced enrolments a different event type so revenue charts are not diluted.
Set insert_id from the enrolment or completion record ID; scheduled exports re-run, and the same completion otherwise counts twice. Course completion arrives weeks or months after enrolment, so compare acquisition cohorts only after their course window has closed.
Moodle → Amplitude · what breaks
Why this join usually fails — Moodle → Amplitude
- 01
The user ID and device ID pair never reaches Moodle
Moodle is typically behind a login and often behind a separate marketing site, so the click identifier has to survive from a public page through registration into a user profile field. Institutional single sign-on frequently breaks that chain entirely.
- 02
Free enrolments outnumbering paid ones
Self-enrolment, cohort sync and manual enrolment all create the same record type as a paid one. Counting them teaches bidding to find people who join free courses.
- 03
Revenue events that carry no revenue
Amplitude will happily accept a purchase event with no price field. The event count looks correct, the funnel looks correct, and the revenue reporting stays at zero — which people usually discover a quarter later when someone asks what a cohort is worth.
- 04
Nothing reconciles afterwards
Amplitude shows the event in the user's activity stream with its properties expanded. Read the properties, because an event that arrives without its revenue fields still looks like a success.
Moodle → Amplitude · the fix
What working looks like — Moodle → Amplitude
The user ID and device ID pair on every enrolment
Conversions arriving in Amplitude
The event lands on the user, joins their behavioural history, and becomes available for cohorts, funnels and retention.
Reconciled against the source
Moodle → Amplitude · architecture
How Moodle and Amplitude actually connect
- 1
Moodle holds the truth
Moodle supports several enrolment methods at once — self-enrolment, manual, cohort sync, payment plugins — and most of them are free. Only the paid methods represent revenue and the others will swamp any blended count.
- 2
Amplitude needs a click to match
Amplitude needs a device or user identifier, an event type and its properties. Revenue events need the price and quantity fields specifically, or the revenue reporting stays empty while events flow normally.
- 3
The identifier is the bridge
The user ID and device ID pair, captured at the visit and carried into the Moodle enrolment.
- 4
The event source decides reliability
Send paid enrolments only, from the server. Free and cohort-synced enrolments must be excluded or the conversion feed is dominated by activity that is not revenue.
- 5
Deduplication at the destination
Amplitude deduplicates on insert_id. Omit it and a retried batch is counted twice, which shows up as a phantom spike that someone will eventually build a hypothesis on.
Moodle → Amplitude · normal or broken
Working vs. broken, side by side — Moodle → Amplitude
Normal, not a fault
The user ID and device ID pair present on the enrolment
Sent from the Moodle enrolment event via a webhook plugin or scheduled export
Deduplicated correctly
Amplitude deduplicates on insert_id. Omit it and a retried batch is counted twice, which shows up as a phantom spike that someone will eventually build a hypothesis on.
Reconciles with the source
Actually broken
The user ID and device ID pair missing on most records
Moodle is typically behind a login and often behind a separate marketing site, so the click identifier has to survive from a public page through registration into a user profile field. Institutional single sign-on frequently breaks that chain entirely.
Sent from the browser
Self-enrolment, cohort sync and manual enrolment all create the same record type as a paid one. Counting them teaches bidding to find people who join free courses.
Counted twice, or not at all
Amplitude will happily accept a purchase event with no price field. The event count looks correct, the funnel looks correct, and the revenue reporting stays at zero — which people usually discover a quarter later when someone asks what a cohort is worth.
Nobody has reconciled it
Moodle → Amplitude · diagnose
Diagnostic order — Moodle → Amplitude
- 01
Count enrolments carrying the user ID and device ID pair
- 02
Follow one real conversion end to end
- 03
Break down enrolments by enrolment method
If paid methods are a small minority, that minority is the only thing that should ever reach an ad platform.
- 04
Check a purchase event for the price and quantity fields specifically
Not whether the event arrived — whether the revenue fields are populated, in the exact names Amplitude expects.
- 05
Read the match rate, not the success message
Amplitude shows the event in the user's activity stream with its properties expanded. Read the properties, because an event that arrives without its revenue fields still looks like a success.
Moodle → Amplitude · prove
How it gets proven — Moodle → Amplitude
Source of truth
Moodle's enrolment records in your own database, filtered to paid enrolment methods.
- The user ID and device ID pair confirmed present on a live enrolment.
- Revenue reconciled per transaction against your billing system, with identity merge behaviour verified across signup.
- Paid enrolments confirmed separated from free and cohort-synced ones before anything is sent.
Moodle → Amplitude · free audit
What we check in the free audit
- Count enrolments carrying the user ID and device ID pair
- Follow one real conversion end to end
- Break down enrolments by enrolment method
- Check a purchase event for the price and quantity fields specifically
- Read the match rate, not the success message
Checked against
Moodle's enrolment records in your own database, filtered to paid enrolment methods.
Free30 minutesNo obligation
Moodle → Amplitude · when not to buy
When you don't need this — Moodle → Amplitude
- Measure identifier coverage yourself first — pull your last hundred enrolments and count how many carry the user ID and device ID pair.
- If your Moodle is purely internal training with no paid enrolment, there is no conversion here to measure.
- If nobody is building cohorts or retention analysis, this is a large amount of instrumentation for reporting a dashboard already gives you.
Moodle → Amplitude · what we deliver
What gets built — Moodle → Amplitude
Identifier capture into Moodle
Capture the identifier on the public site and write it to a Moodle user profile custom field at account creation, so later paid enrolments can be traced back.
Event source: the Moodle enrolment event via a webhook plugin or scheduled export
Send paid enrolments only, from the server. Free and cohort-synced enrolments must be excluded or the conversion feed is dominated by activity that is not revenue.
Dispatch to Amplitude
The Amplitude HTTP V2 API, posted server-side with the identity, event type and properties.
Reversals where they exist
Un-enrolments and refunds where a payment plugin is used should reduce the reported figure.
Written guarantee
95%+ tracking accuracy
Measured against Moodle's enrolment records in your own database, filtered to paid enrolment methods.. Miss it and we keep working at no cost.
From $400 · See packages
FAQ
Moodle → Amplitude questions, answered
Use a Moodle event observer plugin or a scheduled export to post selected events to the HTTP V2 API from the server, with the Moodle user ID as user_id. Check whether an existing plugin fits your Moodle version first.
Yes, as a separate event from paid enrolments, so engagement analysis sees them while revenue and campaign reporting do not.
Almost always because the user ID and device ID pair never reached the Moodle enrolment. Moodle is typically behind a login and often behind a separate marketing site, so the click identifier has to survive from a public page through registration into a user profile field. Institutional single sign-on frequently breaks that chain entirely. Measure coverage before debugging the dispatch.
Amplitude tracks both a device ID and a user ID and merges them when a user identifies. The merge rules decide who counts as one person, so a mistake here does not produce a small error — it changes every retention curve and cohort size in the account.
The Moodle enrolment event via a webhook plugin or scheduled export. Send paid enrolments only, from the server. Free and cohort-synced enrolments must be excluded or the conversion feed is dominated by activity that is not revenue.
Amplitude shows the event in the user's activity stream with its properties expanded. Read the properties, because an event that arrives without its revenue fields still looks like a success.
More on Moodle → Amplitude
- Moodle → Google AdsConnecting Moodle to Google Ads
- Moodle → MetaConnecting Moodle to Meta Conversions API
- Moodle → GA4Connecting Moodle to GA4
RELATED GUIDES
Where Moodle → Amplitude fits in the rest of your tracking
- Litmos → AmplitudeConnecting Litmos to Amplitude
- LifterLMS → AmplitudeConnecting LifterLMS to Amplitude
- LearnDash → AmplitudeConnecting LearnDash to Amplitude
- Moodle → PostHogConnecting Moodle to PostHog
- Moodle → GA4Connecting Moodle to GA4
- EducationConversion tracking for education providers, measured in enrollments
- LearnWorlds → AmplitudeConnecting LearnWorlds to Amplitude
- Canvas → AmplitudeConnecting Canvas LMS to Amplitude
Free · 30 min
Get Moodle and Amplitude joined properly
Free30 minutesNo obligation
