Moodle SCORM progress resets past the halfway mark? suspend_data is truncated in two places, not one

The advice everyone repeats — “disable SCORM standards mode” — usually changes nothing, because that setting is already off by default. The bookmark can be cut in two places, the LMS and the package, but on a default Moodle it's the package doing it. Here's how to prove which, and fix it.

When a SCORM course in Moodle™ resets learners to the start after they've passed the halfway mark, the cause is almost always cmi.suspend_data being truncated past the SCORM 1.2 spec limit of 4,096 characters. That limit is enforced in two independent places: the authoring tool's own client-side API wrapper, which can trim the value before it leaves the browser, and Moodle's own cap, a site setting called SCORM standards mode. That setting ships off, and while it's off Moodle already allows up to 64,000 characters, so out of the box Moodle isn't the one enforcing 4,096 — turning it on is what would clamp Moodle to the strict limit. So on a default site the surviving cut is the one inside the package: if the package trimmed cmi.suspend_data in the browser first, the data was gone before Moodle ever saw it. This is a data-loss problem, not a status problem; if your course instead shows “incomplete” after a clean finish, that's a different failure with different fixes.
The cmi.suspend_data pathone string, two capsAuthoring toolcourse stateAPIWrapper.jsclient capLMSSetValue(cmi.suspend_data)Moodle serverenforces capscorm_elementDB rowSUSPEND_DATA STRING · AS AUTHOREDchars droppedcut 1 · packageAPIWrapper (client)cut 2 · serverSCORM 1.2 standard mode
Two independent limits chop cmi.suspend_data — the package's client-side cap and Moodle's SCORM 1.2 server cap — so lifting only one still loses the tail.

The ticket came in on a Thursday. A 214-slide bloodborne-pathogens refresher, built in Articulate Storyline 360, published to SCORM 1.2, sitting in Moodle 4.4, due for 340 warehouse and dock staff before an OSHA re-audit the next month.

Forty-one of them had gotten past slide 128, closed the tab for the night, came back, and landed on slide 1. Not “resume from where you were”: slide one, timer reset, quiz bank reshuffled.

The training coordinator had done her homework. She'd found the forum threads and done what they said: opened the SCORM Package settings, hunted down SCORM standards mode, and switched it off.

It made no difference; the same learners reset the next morning. By the time she called us she was three weekends deep and convinced Moodle was broken. It wasn't. The advice was just incomplete.

We measured it in twenty minutes. The course needed roughly 6,100 characters of suspend_data to describe a learner at slide 128; the value arriving in the database was 4,096 characters, flat, every time, cut mid-token with the closing brace of the state object missing.

Storyline read that back, couldn't parse the JSON, and threw the corrupt bookmark away. The tail describing the second half had never left the browser: the truncation happened in the package's own JavaScript, so toggling the Moodle setting couldn't have helped.

We do this repair often enough to have opinions about it, and the strongest is this: the popular fix targets the wrong end of the pipe about half the time.

First, which problem is this

Three symptoms that sound identical and aren't

Before you touch a single setting, name the symptom precisely: three very different failures get reported with the same five words, “it lost my progress.” Get this wrong and you spend a week republishing packages that were never the problem.

  • “It starts over from slide 1.” Progress from the current or a previous session is gone; the resume point is missing or wrong. That's truncation (gate one or gate two below), or a resume-versus-new-attempt setting. This is the article you're reading.
  • “An earlier section I finished reverted to 0% after I did a later one.” Recent progress holds, old progress reverts. That's advance overwriting, further down. It looks like a size problem and often isn't.
  • “The player said I finished but the LMS still shows incomplete.” The data arrived intact; the status word the package sent, or the completion condition Moodle checks, is the mismatch. That's a status problem with its own guide: why your SCORM course isn't tracking completions. Don't edit suspend_data for a status bug.

The distinguishing test takes thirty seconds. Have someone reach the halfway mark, close the tab, and reopen. If they resume where they left off but the course won't complete, you're in the status guide. If they resume to the beginning, or somewhere earlier than they'd reached, you're in the right place.

Symptom → cause → fixbrass = what this post fixesSYMPTOMCAUSEFIXLearner starts overfrom slide 1 on returnsuspend_data truncated —resume bookmark lostRESOLVED HERELift both caps;verify resume restores.Earlier sections revert to 0%after finishing later onesA later snapshot overwritesearlier completion flagsRESOLVED HERELift caps so full statepersists on every write.Shows 'incomplete' thoughthe player reported doneStatus / attempt handling —not a data-size problemROUTES OUT →Not a cap issue — readthe status postMatch the exact symptom before changing any setting.
Same-looking resume failures have different roots — confirm which symptom you actually have before touching a single SCORM setting.

The mechanism

What suspend_data is, and the two places it gets cut

When a learner opens a SCORM activity, the package and Moodle talk through a small run-time interface: the SCORM API object the LMS exposes in the browser. The package doesn't hand over a tidy “here's what they finished.”

It stores its entire private notion of the learner's state in one string, cmi.suspend_data, and calls LMSSetValue("cmi.suspend_data", "...") whenever that state changes. Storyline, Adobe Captivate, and Rise all lean on it heavily: branching paths, per-question responses, timeline positions.

The SCORM 1.2 spec caps that string at 4,096 characters, and most other CMI strings at 255. That was roomy in 2001 and cramped now; a long branching compliance course generates far more state than that.

When the string exceeds the cap, the excess is cut and the tail is lost silently: no error to the learner, no warning in the report.

That limit isn't enforced in one place. It's enforced in two, on opposite sides of the network, and clearing only the downstream one changes nothing if the upstream one is tighter.

  • Gate one, the client-side cut, inside the package. Every authoring tool ships its own SCORM API wrapper, and many enforce the 1.2 spec themselves. In one case on moodle.org (discussion 470344, a Moodle 4.5 site running a SCORM 1.2 package), the wrapper stored cmi.suspend_data as value.substring(0, 4096), a hard chop, alongside a separate per-tool size constant. Names and numbers vary by tool; the pattern doesn't. It happens in the browser, before LMSSetValue is called, so Moodle never receives the tail and no setting can bring it back.
  • Gate two, the server-side cut, inside Moodle. The value that does make it out is validated again on the way in. SCORM standards mode is a site-level setting under Site administration → Plugins → Activity modules → SCORM Package. It ships off, and while it's off Moodle extends these fields to 64,000 characters, the SCORM 2004 maximum. Tick it and Moodle clamps back to the strict SCORM 1.2 limits: 255 characters on most strings, 4,096 on suspend_data. So on a default site this gate is wide open at 64,000, and the only reason to look at it is to check that nobody has switched it on.

Don't conflate that site-wide setting with the per-activity Compatibility settings section (Auto-continue, Force completed, Auto-commit, Mastery score overrides status). Different screen, different job.

To raise the ceiling you have to clear both caps: the package must stop capping itself, and Moodle must leave the field alone.

suspend_data capacity by profileSCORM 1.24,096≈2,000 overSCORM 2004≈64,000xAPIunbounded02,0004,0006,0008,000your course needs ≈6,100* A package's APIWrapper.js may cap suspend_data below the 4,096 spec limit.axis capped at 8,000
SCORM 1.2 caps suspend_data at 4,096 characters — below this course's ~6,100 need — while SCORM 2004 and xAPI have room to spare; the package's own wrapper may cap lower still.

The advice that isn't the whole answer

Why disabling SCORM standards mode may not restore resume

The SCORM standards-mode setting is real and worth checking; it's a single site setting and instantly reversible. The mistake is treating it as the whole answer and concluding “Moodle is broken” when changing it does nothing.

Switch it off and Moodle will store a 10,000-character suspend_data. But if the package's wrapper still clips its output to 4,096 before calling LMSSetValue, Moodle stores that short string faithfully, as short as before.

This isn't hypothetical. In discussion 470344 the poster relaxes the strict SCORM 1.2 data limit and still hits the problem, because the cut was elsewhere: the package's own truncation, single-SCO behaviour, multi-session overwrite.

There's a second-order catch, too. It's a site-wide switch, so it touches every SCORM activity on the server, including ones authored by people who quietly depend on the 1.2 limits. On a shared or multi-tenant Moodle that's a managed-hosting judgment call, not a per-activity tweak.

So treat the setting as the first rung, not the ladder: confirm it's disabled, then re-measure the stored length. On a default site the number usually won't budge, which tells you the bottleneck is upstream in the package.

In the activity settings, note the per-activity levers that interact with all this. Use the exact labels:

  • Auto-commit commits data about 60 seconds after values are set, for packages that never call LMSCommit() themselves. Turn it on for anything that only saves on a clean exit.
  • Force new attempt — when every entry is a new attempt, a returning learner never resumes; the old attempt's data still exists but isn't what loads. For resume-sensitive courses, don't let this force a fresh attempt on re-entry.
  • Auto-continue auto-launches the next SCO in multi-SCO packages only; it does nothing for a single-SCO course.
  • Grading method — Learning Objects, Highest grade, Average grade, or Sum grade. Learning Objects counts completed/passed SCOs, the one you want when the package reports cmi.core.lesson_status but not cmi.core.score.raw.
  • Mastery score overrides status — if a mastery score is set and the raw score is below it at LMSFinish, Moodle forces lesson_status to failed, overriding what the package sent.
Site administration › Plugins › Activity modules › SCORM package SCORM package — default settings SCORM standards mode DEFAULT · OFF Off by default — Moodle allows 64,000 chars. Tick it to enforce the strict 4,096. Save changes Cancel Per-activity levers set on each activity, not site-wide LEVER SETTING Auto-commit Yes Force new attempt No Grading Learning objects Mastery score overrides status
The “SCORM standards mode” box ships off, so Moodle itself isn’t the thing capping SCORM runtime data at 4,096 characters.

The counter-intuitive one

Advance overwriting: an earlier completed section resets to 0%

This is the one that makes people think their LMS is haunted. The docs have no name for it, so we borrow the one that fits: advance overwriting.

The symptom is counter-intuitive. A learner completes an earlier section, moves on, completes a later section, and the earlier one reverts to 0%. Finishing more work destroys work already done. Discussion 470344 on moodle.org is full of people describing exactly this.

Often it's truncation wearing a costume. The package keeps its “sections completed” flags inside suspend_data. On a later session it resumes by reading the stored value back; if that value was truncated, it initializes from a picture missing the early-section flags.

The learner finishes the current section, the package serializes its now-current state, and Moodle overwrites the row with this fresh snapshot, one that no longer includes the early sections it never read back.

The tell that separates advance overwriting from plain truncation: with truncation you lose the tail, your newest and furthest progress; with advance overwriting you lose the head, old settled progress, while recent progress sticks.

So “the module I finished last week is back to zero but today's is fine” is not a size problem, and republishing to 2004 won't touch it. It's an order-of-operations problem between the package's snapshot logic and Moodle's attempt handling.

If your rows changed the day you replaced the package or bumped Moodle versions, that's more likely a data-migration issue; see grades gone after re-enrolment to recover those from history.

And if the erosion began right after a Moodle upgrade, suspect resume behaviour directly: there's a known Moodle 4.3 SCORM completion regression, MDL-79967, and packages that mix review and normal modes are the usual triggers.

Advance overwritingmoodle.org d=470344SESSION TIMELINE →Session 1completes Section ASession 2completes Section BSession 3opens C, player saves state››AFTER SESSION 1ABCSection A savedAFTER SESSION 2ABCA and B savedAFTER SESSION 3ABCA and B overwritten → 0%Session 3's snapshot omitted A and B — so Moodle stored them as incomplete.
A later session's write carries only its own view of progress — Session 3 reset Sections A and B to 0% because its snapshot never contained them.

Prove it yourself

Two diagnostics that name the cause in ten minutes

1. Read the live length in the console. Open the SCORM activity, press F12, and in the console's frame picker select the frame holding the actual course content, not the Moodle shell.

Because the content runs inside an iframe, the SCORM 1.2 API object usually lives a frame or two up. Walk the window chain to find it, then read the length of what the package currently holds:

// SCORM 1.2 — find the API, then measure the current suspend_data
function findAPI(w){ let n=0; while(w && !w.API && w.parent!==w && n++<10){ w=w.parent; } return w && w.API; }
const api = findAPI(window) || (window.opener && findAPI(window.opener));
if (!api) { console.warn('SCORM API not found — pick the course-content frame in the console frame dropdown'); }
api.LMSGetValue('cmi.suspend_data').length;
// SCORM 2004 uses window.API_1484_11 and api.GetValue('cmi.suspend_data')

Take the course to where it breaks and watch this number. If it climbs and then flatlines at exactly 4096, the package is capping itself client-side, gate one, upstream of Moodle.

If it climbs well past 4096 in the browser but the stored value (next query) is 4096, Moodle made the cut on write.

2. Read what actually landed, per learner, per attempt. The database is ground truth. Moodle changed these tables in 4.3, so the query depends on your version.

Check Site administration → Notifications first, and remember the mdl_ prefix is only the default; yours is whatever $CFG->prefix is set to.

Moodle 4.2 and earlier stored every CMI element in one flat table, scorm_scoes_track:

SELECT t.userid, t.attempt,
       CHAR_LENGTH(t.value) AS chars,   -- CHAR_LENGTH, not LENGTH: LENGTH counts bytes on MySQL/MariaDB
       t.value
FROM   mdl_scorm_scoes_track t
WHERE  t.scormid = 42            -- mdl_scorm.id, the activity INSTANCE id (not the cmid in view.php?id=)
  AND  t.element = 'cmi.suspend_data'
ORDER  BY t.userid, t.attempt;

Moodle 4.3 (MDL-46279) dropped scorm_scoes_track and normalised it into three tables, scorm_attempt, scorm_element, and scorm_scoes_value, so on a current site you join them (scorm_scoes_value.elementid to scorm_element.id, scorm_scoes_value.attemptid to scorm_attempt.id):

SELECT a.userid, a.attempt,
       CHAR_LENGTH(v.value) AS chars,
       v.value
FROM   mdl_scorm_scoes_value v
JOIN   mdl_scorm_element e ON e.id = v.elementid
JOIN   mdl_scorm_attempt  a ON a.id = v.attemptid
WHERE  a.scormid = 42            -- mdl_scorm.id, not the cmid
  AND  e.element = 'cmi.suspend_data'
ORDER  BY a.userid, a.attempt;

Read the chars column. A column full of 4096 across affected learners is a signed confession that something is enforcing the 1.2 limit. Cross it against the console number: browser also 4096 means the package; browser larger than stored means Moodle.

Values under 4096 that still fail to resume send you elsewhere: a missed commit, a new-attempt setting, or a broken package. But in our casework, when learners reset past the halfway mark, that column reads 4096 more often than not.

One migration note: on a site upgraded from 4.1 or 4.2, historical rows move in the background. If the 4.3+ join comes back empty for a learner you know took the course, check the legacy table first.

Reading the 4096 tell across the stack Browser API, network payload and database all report the same ceiling. CONSOLE > API.LMSGetValue('cmi.suspend_data').length .length 4096 NETWORK POST datamodel.php · LMSSetValue('cmi.suspend_data') 200 OK request body 4096 DATABASE SELECT LENGTH(value) FROM scorm_scoes_value · JOIN scorm_element (4.3+) LENGTH(value) 4096
When the browser API, the LMSSetValue request body, and the stored row all top out at exactly 4096, you are looking at the SCORM 1.2 cap, not a coincidence.

The fix, reversible first

How to fix it: the reversible-first remediation ladder

Once you know which cut is yours, fix it in order of blast radius. Start with changes you can undo in one click, and climb to content-touching ones only when the rungs above can't clear it. With an audit on the calendar, you want the fastest safe win, not the most thorough rebuild.

  1. Confirm SCORM standards mode is off, then re-measure. It's off by default, so most of the time there's nothing to change here; if an admin turned it on, turn it off, which lifts Moodle's own limit back to 64,000. If the stored length grows past 4096 and resume returns, that gate was the bottleneck and you're done. If it stays pinned at 4096, the cut is in the package; keep climbing. This is site-wide, so weigh it on shared servers.
  2. Set the per-activity levers. Turn on Auto-commit so a closed tab doesn't cost the last stretch. Make sure Force new attempt isn't forcing a fresh attempt on re-entry, so returning learners resume. Confirm the package launches in the current window, not a pop-up the browser can block.
  3. Republish the package, mindful that 2004 is not a clean drop-in. If the cap is inside the package, republishing to SCORM 2004 raises its suspend_data ceiling from 4,096 to roughly 64,000 characters, usually a single dropdown in Storyline or Captivate. But Moodle does not fully support SCORM 2004 (sequencing and navigation especially), so test the 2004 build first. Upload it as a new package (old attempts won't migrate), and plan the swap so nobody's mid-course when it lands.
  4. Reduce the state the course stores, or move to xAPI. If even 64,000 is tight (enormous branching, huge question banks), trim what the package remembers (“resume to slide” rather than full state) or split one giant SCO into several. For unbounded state, xAPI keeps it in a Learning Record Store instead of a size-capped string. The biggest change, and the last resort, because it's the least reversible.

On the OSHA course we wasted the first hour poking at attempt settings before the console number made it obvious the package was doing the cutting.

After that it went quickly. Rung one showed the stored length wouldn't move, rung two got Auto-commit and resume behaving, and rung three, republishing the same Storyline source, cleared it. Measured suspend_data afterward was about 6,150 characters, resuming cleanly at slide 128.

The re-audit passed. Start to fix was one business day, most of it spent confirming rather than guessing.

Fix ladder — reversible first Work top-down; each rung is harder to undo than the one above it. 1 Confirm SCORM standards mode is off It ships off by default — Moodle then allows 64,000 chars. REVERSIBLE 2 Set the per-activity levers Auto-commit on, Force new attempt off. REVERSIBLE 3 Republish to SCORM 2004 Lifts the limit to 64,000 — Moodle doesn’t fully support 2004 sequencing. HAS A CAVEAT 4 Reduce stored state, or move to xAPI Last resort: trim what the package stores, or re-author to xAPI. LAST RESORT
Climb only as far as you must — the reversible checks come before republishing or re-authoring.

The mobile path

The Moodle app hardcodes the 4,096 cap

Desktop and app can diverge. Disabling standards mode is honoured in a desktop browser, but it was reported not to apply in the Moodle mobile app, which hardcoded CMI_STRING_4096 in its SCORM 1.2 data model (src/addons/mod/scorm/classes/data-model-12.ts).

That's from moodle.org discussion 440176 and tracker MOBILE-4191, reported on app version 4.0.2 back in 2022, old enough that its resolution status isn't public. Treat it as a limitation to check, not a permanent fact, and verify against the app version your learners actually run.

Your console diagnostic measures the desktop path, so a learner resetting only in the app can have an intact stored value from web sessions. Confirm the app path separately, on a real device, before you close the ticket.

The app is also where a killed session, a backgrounded process, or a spotty connection strands the last stretch of progress that never committed, and where two devices syncing attempts that both moved on let one snapshot overwrite the other.

Persistent commit and sync failures are usually an ops problem, not a content one — hosting and ops territory. If your audience is meaningfully mobile, test mobile explicitly.

Quick answers

Questions people ask about this

I disabled SCORM standards mode and progress still resets. Why?

Because that setting is off by default, so disabling it changes nothing on most sites — Moodle already allows up to 64,000 characters. It's only one of two caps, and usually not the one biting. If the authoring package's own SCORM wrapper already trimmed cmi.suspend_data in the browser (some do, storing it as value.substring(0, 4096) to stay “1.2 compliant”), the string was shortened before Moodle ever saw it, so the server setting can't restore it. Measure the live length in the console: if it flatlines at 4096 in the browser, the package is the bottleneck and you republish, not reconfigure.

How do I know whether the package or Moodle is doing the truncating?

Compare two numbers. In the browser console, read the length of cmi.suspend_data as the learner progresses. In the database, read CHAR_LENGTH(value) for that learner's cmi.suspend_data row (use CHAR_LENGTH, not LENGTH, since LENGTH counts bytes on MySQL/MariaDB). If the browser value flatlines at 4096, the package cut it client-side. If the browser value climbs past 4096 but the stored value sits at 4096, Moodle cut it on write. That single comparison is the whole diagnosis.

Why does finishing a later section erase an earlier completed one?

That's advance overwriting, and it's usually truncation in disguise. The package keeps its “sections completed” flags inside cmi.suspend_data. If the stored string was truncated, the package resumes from an incomplete picture missing the early flags, then writes a fresh snapshot reflecting only its current view, overwriting the earlier completions as if they never happened. It's discussed on moodle.org at discussion 470344. Fix the underlying truncation and the erosion usually stops; if it started right after a Moodle upgrade, suspect the resume and attempt handling instead.

Does moving to SCORM 2004 actually fix it?

Often, when the cap is inside the package: SCORM 2004 raises cmi.suspend_data from 4,096 to 64,000 characters. But it isn't a clean drop-in: Moodle doesn't fully support SCORM 2004, especially sequencing and navigation, and you upload it as a new package so existing attempts don't carry over. Test the 2004 build before you commit a cohort to it. For unbounded state, xAPI stores progress in a Learning Record Store and removes the fixed ceiling.

My query errors on scorm_scoes_track. Is the table gone?

On Moodle 4.3 and later, yes. MDL-46279 dropped mdl_scorm_scoes_track and split it into three tables, mdl_scorm_attempt, mdl_scorm_element, and mdl_scorm_scoes_value, so you join value to element to attempt instead of reading one flat table. On 4.2 and earlier, query the single scorm_scoes_track table. Check your version at Site administration then Notifications, and remember mdl_ is only the default table prefix.

Learners reset in the Moodle app but not in a browser. Why?

Disabling the setting is honoured in the browser but was reported not to apply in the Moodle mobile app, which hardcoded CMI_STRING_4096 in its SCORM 1.2 data model (moodle.org discussion 440176, tracker MOBILE-4191, on app 4.0.2 in 2022). That report is a few years old and its current status isn't public, so verify against the app version your learners actually run rather than assuming it's still broken, and test the offline-capture-then-sync path on a real device before you close the ticket.

When you'd rather just have it fixed

Everything above is here so you can do it yourself, and plenty of teams do: measure the two lengths, find the cut, and work down the ladder. A lot of them have it fixed by lunch.

We publish the method because the method isn't the scarce part. The scarce part is the afternoon you don't have when there's an audit on the calendar and forty-one records that need to be true.

If you've compared browser length to stored length, tried the reversible rungs, and it's still cutting learners off past the halfway mark, that's what our SCORM tracking repair is for.

We find which cut is yours, fix it at the package, settings, or hosting layer, prove the stored length holds, and confirm resume on desktop and app before we call it done.

A fixed, flat per-package price, one business day, no retainer. It runs on Moodle, but you don't have to know Moodle; you just need the tracking to be real.

Fix my SCORM tracking Talk to an engineer

Not sure which cut is yours? Send the package or a test login and we'll tell you free, within one business day. Repair is a fixed, flat per-package price only if you want us to finish it, or talk it through first at (615) 396-7139.