Is there an open specification of the .grist file format?

Hi, all.

Thanks for everyone’s hardwork in realising the promise and potential of Grist.

So far, I understand that .grist files are based on SQLite databases, but I would like to get into more of the details…

Where might I find a specification for the .grist file format?

Thanks

Hi @kks-rnl,

Grist files are SQLite databases, with user data stored as regular SQLite tables. Grist maintains a set of metadata tables, all starting with _grist_*, as defined here:

There is another batch of tables all starting with _gristsys_* storing data not needed by the “data engine” that handles formula evaluation:

Another way to approach this is to look at what is needed to make an SQLite database created outside of Grist readable by Grist. There is a utility for that (yarn run cli sqlite), implemented here:

The script has limits but it may give ideas.

2 Likes

Perfect, @paul-grist!

Thank you.