Connecting Moodle to AppsFlyer
Moodle is self-hosted open-source learning management, used mostly by institutions where enrolment and payment are usually two different systems. AppsFlyer exists because mobile app attribution is a different problem from web attribution, and on iOS a large share of it is now aggregated and delayed by design rather than by accident. The join between them succeeds or fails on one thing: whether the AppsFlyer device identifier, appsflyer_id reaches the Moodle enrolment before the conversion happens, because AppsFlyer can only match a conversion it can tie back to a click it recognizes.
Free30 minutesNo obligation
Specific to this pair
Moodle and AppsFlyer only work with an app you control
Only with an app you control; you can't add AppsFlyer's SDK to the standard Moodle app. Your app reports the appsflyer_id to your backend, which stores it in a Moodle custom profile field. When a paid enrollment completes, post it to AppsFlyer's server-to-server API with that ID, fee and currency.
AppsFlyer attributes events to app installs through its SDK, and the SDK has to be inside the app. The standard Moodle app is built and published by Moodle, and institutions cannot add their own measurement SDK to it. For most Moodle sites there is no AppsFlyer install to attribute anything to.
A branded Moodle app is built for you by Moodle, so check with them whether a third-party SDK can be included before planning any mobile attribution. If you have your own app instead, a companion app that links to Moodle courses for example, the chain has to run through it: the app reports the appsflyer_id to your backend, the backend stores it in a custom user profile field in Moodle, and when a paid enrollment completes, your server posts it to AppsFlyer's server-to-server events API with that ID, the course fee and the currency.
The break is the payment itself. Paid enrollments happen in a web browser through a payment plugin, often on a laptop, while the app install sits on a phone. A learner who installed on one device and paid on another can only be joined through their Moodle account, which is exactly why the device ID must be stored on the profile rather than read from a cookie. Free and cohort enrollments never belong in this event.
Moodle → AppsFlyer · what breaks
Why this join usually fails — Moodle → AppsFlyer
- 01
The AppsFlyer device identifier, appsflyer_id 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
Web conversions sent to a mobile attribution platform
This is the common error and it produces confident nonsense. A purchase made on your website has no device identifier and no install behind it. AppsFlyer will either discard it or attribute it to nothing, and the revenue disappears somewhere between the two systems without anyone noticing it went.
- 04
Nothing reconciles afterwards
AppsFlyer shows the event on the raw data export with its attributed media source. Check the raw export, not the aggregate dashboard, and confirm the event carries a device identifier rather than landing as organic.
Moodle → AppsFlyer · the fix
What working looks like — Moodle → AppsFlyer
The AppsFlyer device identifier, appsflyer_id on every enrolment
Conversions arriving in AppsFlyer
The event is attributed to the install source, forwarded to whichever networks are configured, and appears in the cohort reporting.
Reconciled against the source
Moodle → AppsFlyer · architecture
How Moodle and AppsFlyer 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
AppsFlyer needs a click to match
AppsFlyer needs the device identifier and an event name it recognizes, plus the revenue value for in-app purchases. A server event about a user with no linked device cannot be attributed to an install.
- 3
The identifier is the bridge
The AppsFlyer device identifier, appsflyer_id, 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
AppsFlyer deduplicates in-app events by its own event identifier. Sending the same purchase from both the SDK and your server produces two events and double-counts revenue in every dashboard downstream, including the ad networks AppsFlyer forwards to.
Moodle → AppsFlyer · normal or broken
Working vs. broken, side by side — Moodle → AppsFlyer
Normal, not a fault
The AppsFlyer device identifier, appsflyer_id present on the enrolment
Sent from the Moodle enrolment event via a webhook plugin or scheduled export
Deduplicated correctly
AppsFlyer deduplicates in-app events by its own event identifier. Sending the same purchase from both the SDK and your server produces two events and double-counts revenue in every dashboard downstream, including the ad networks AppsFlyer forwards to.
Reconciles with the source
Actually broken
The AppsFlyer device identifier, appsflyer_id 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
This is the common error and it produces confident nonsense. A purchase made on your website has no device identifier and no install behind it. AppsFlyer will either discard it or attribute it to nothing, and the revenue disappears somewhere between the two systems without anyone noticing it went.
Nobody has reconciled it
Moodle → AppsFlyer · diagnose
Diagnostic order — Moodle → AppsFlyer
- 01
Count enrolments carrying the AppsFlyer device identifier, appsflyer_id
- 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 what share of your revenue happens in the app at all
If most purchases are on the web, AppsFlyer is not your conversion destination and the work belongs somewhere else entirely.
- 05
Read the match rate, not the success message
AppsFlyer shows the event on the raw data export with its attributed media source. Check the raw export, not the aggregate dashboard, and confirm the event carries a device identifier rather than landing as organic.
Moodle → AppsFlyer · prove
How it gets proven — Moodle → AppsFlyer
Source of truth
Moodle's enrolment records in your own database, filtered to paid enrolment methods.
- The AppsFlyer device identifier, appsflyer_id confirmed present on a live enrolment.
- In-app revenue events reconciled per transaction against your billing system, with the organic share stated rather than assumed away.
- Paid enrolments confirmed separated from free and cohort-synced ones before anything is sent.
Moodle → AppsFlyer · free audit
What we check in the free audit
- Count enrolments carrying the AppsFlyer device identifier, appsflyer_id
- Follow one real conversion end to end
- Break down enrolments by enrolment method
- Check what share of your revenue happens in the app at all
- 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 → AppsFlyer · when not to buy
When you don't need this — Moodle → AppsFlyer
- Measure identifier coverage yourself first — pull your last hundred enrolments and count how many carry the AppsFlyer device identifier, appsflyer_id.
- If your Moodle is purely internal training with no paid enrolment, there is no conversion here to measure.
- If you have no mobile app, this is not a destination for you. If you have one but sell mostly on the web, send web conversions to your ad platforms directly and use AppsFlyer only for install and in-app events.
Moodle → AppsFlyer · what we deliver
What gets built — Moodle → AppsFlyer
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 AppsFlyer
The AppsFlyer server-to-server events API, posted from your billing system with the device identifier and revenue.
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 → AppsFlyer questions, answered
Not to the standard Moodle app, which Moodle publishes. For a branded app, check with Moodle whether a third-party SDK can be included.
Only if your own app stored its appsflyer_id on the learner's Moodle profile, so your server can post the paid enrollment against it.
Almost always because the AppsFlyer device identifier, appsflyer_id 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.
AppsFlyer assigns its own device ID and matches installs to clicks through referrer data on Android and Apple's frameworks on iOS. There is no durable cross-device identifier. On iOS without ATT consent, attribution falls back to SKAdNetwork, which returns aggregated conversion values on a delay with no user-level detail at all — so a share of your installs will be attributable only in aggregate, permanently.
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.
AppsFlyer shows the event on the raw data export with its attributed media source. Check the raw export, not the aggregate dashboard, and confirm the event carries a device identifier rather than landing as organic.
More on Moodle → AppsFlyer
- Moodle → Google AdsConnecting Moodle to Google Ads
- Moodle → MetaConnecting Moodle to Meta Conversions API
- Moodle → GA4Connecting Moodle to GA4
RELATED GUIDES
Where Moodle → AppsFlyer fits in the rest of your tracking
- iSpring → AppsFlyerConnecting iSpring Learn to AppsFlyer
- Restrict Content Pro → AppsFlyerConnecting Restrict Content Pro to AppsFlyer
- Tovuti → AppsFlyerConnecting Tovuti to AppsFlyer
- BootcampsConversion tracking for bootcamps, measured in started students
- Paid Memberships Pro → AppsFlyerConnecting Paid Memberships Pro to AppsFlyer
- LifterLMS → AppsFlyerConnecting LifterLMS to AppsFlyer
- TalentLMS → AppsFlyerConnecting TalentLMS to AppsFlyer
- Canvas → AppsFlyerConnecting Canvas LMS to AppsFlyer
Free · 30 min
Get Moodle and AppsFlyer joined properly
Free30 minutesNo obligation
