Which documents keep a version history
What you'll see
You open the History of a page or a script and the list is empty, or docly history answers that the document is not versioned. Or you expected to roll back a template you broke, and there is nothing to roll back to.
What's actually happening
Docly stores a version of a document each time it is saved, but only when both of these are true:
| Condition | Where it is set |
|---|---|
The document's schema has EnableVersioning turned on | The schema document |
| The workspace's subscription includes Revisions | The subscription (depends on the plan) |
Files without a schema have no history at all. That is most of a published site: .hash templates, .js and .css, .html, images and other uploads. Saving them overwrites the previous content.
The rule is the same for every way a document is written: the editor, the mapped drive, the docly CLI and MCP, the AI assistant, unzipping, package installs and your own scripts. None of them can create a version the rule does not allow, and none of them skips one it does.
Turning Revisions off stops new versions only. The versions that already exist are kept and can still be opened, compared and restored. The History dialog says when the subscription has turned versioning off, so an empty list is not mistaken for a document that never changed.
What to do
Read and compare versions
In the editor, open History on the document. From the command line:
docly history <document> # list the versions
docly history <document> --version 3 # print version 3
docly history <document> --version 3 --diff # what changed since version 3
docly history <document> --version 3 --label "before redesign"
docly history <document> --version 3 --out old.jsonTo restore an older version from the command line, write it to a file with --out and put it back with docly put. Restoring creates a new version; nothing in the history is removed.
Protect files that have no history
Templates and scripts are where a mistake takes a site down, and they are exactly the files without versions. Work on them in a docly CLI working copy, so you have docly diff before anything goes live and a local copy to go back to — see Use a docly CLI working copy instead of git and Work safely on a live site.
Turn versioning on for your own schemas
Set EnableVersioning on schemas whose documents people edit and may want to undo: content pages, settings, data records. Leave it off for documents that scripts rewrite constantly (counters, logs, caches) — every save is a stored copy.