File formats
Your snippets are yours. Every file Keyseal writes is described here, so you can read your data with or without Keyseal.
Plain exports
To take your snippets anywhere else, choose Import and Export › Export… in the toolbar of Keyseal's Snippets window, then JSON or CSV. Sensitive snippets and your records go in only if you say so, since these files aren't encrypted.
JSON
Everything a snippet holds. The top level has type (always keyseal.snippets), format (1), exported (ISO 8601, UTC), app (the Keyseal that wrote it), snippets and, if you chose them, records. sensitive, forms, bindings, source, folder, rtfd and scopes are left out when they'd be empty or false. Readers should ignore fields they don't know: later versions may add some, never rename them.
| Snippet field | What it holds |
|---|---|
trigger, name, text | The trigger, its name, and the text it types, placeholders such as {{cursor}} included. |
enabled | Whether it expands. |
sensitive | true if it asks for Touch ID. |
forms | What to type instead in a field that asks for one kind of thing: email, phone, givenName, familyName, fullName, street, city, postalCode, country, organization, username or url. |
bindings | Where it may expand: apps by bundle id (app, appName) and sites (host). |
source | Where its text comes from at the moment it's typed: onePassword (an op:// reference), file (a path) or contact (a field kind from your own card). |
folder | The name of the folder it's in. Importing puts it back in the folder with that name, made if there isn't one. |
rtfd | A formatted snippet's formatting and pictures: flat RTFD, as macOS writes it, in base64. text is then its plain text, without the pictures. |
A record has a key, a name and values, each with a kind, a label, the value and, optionally, scopes shaped like bindings.
{
"app" : "Keyseal 1.0.0 (1)",
"exported" : "2026-11-25T10:00:00Z",
"format" : 1,
"records" : [
{
"key" : "me",
"name" : "Me",
"values" : [
{
"kind" : "email",
"label" : "",
"value" : "sam@example.com"
},
{
"kind" : "phone",
"label" : "mobile",
"value" : "+1 555 0100"
},
{
"kind" : "email",
"label" : "proton",
"scopes" : [
{
"host" : "proton.me"
}
],
"value" : "sam@proton.me"
}
]
}
],
"snippets" : [
{
"enabled" : true,
"folder" : "Personal",
"name" : "Email",
"text" : "sam@example.com",
"trigger" : "@email"
},
{
"bindings" : [
{
"app" : "com.apple.mail",
"appName" : "Mail"
}
],
"enabled" : true,
"name" : "Signature",
"rtfd" : "cnRmZAAAAAADAAAAAgAAAAcAAABUWFQucnRmAQAAAC5SAQAAKwAAAAEAAABKAQAAe1xydGYxXGFuc2lcYW5zaWNwZzEyNTJcY29jb2FydGYyOTA4Clxjb2NvYXRleHRzY2FsaW5nMFxjb2NvYXBsYXRmb3JtMHtcZm9udHRibFxmMFxmbmlsXGZjaGFyc2V0MCBIZWx2ZXRpY2FOZXVlO30Ke1xjb2xvcnRibDtccmVkMjU1XGdyZWVuMjU1XGJsdWUyNTU7fQp7XCpcZXhwYW5kZWRjb2xvcnRibDs7fQpccGFyZFx0eDU2MFx0eDExMjBcdHgxNjgwXHR4MjI0MFx0eDI4MDBcdHgzMzYwXHR4MzkyMFx0eDQ0ODBcdHg1MDQwXHR4NTYwMFx0eDYxNjBcdHg2NzIwXHBhcmRpcm5hdHVyYWxccGFydGlnaHRlbmZhY3RvcjAKClxmMFxiXGZzMjYgXGNmMCBCZXN0LApcYjAgXApTYW19AQAAACMAAAABAAAABwAAAFRYVC5ydGYQAAAAxYEIa7YBAAAAAAAAAAAAAA==",
"text" : "Best,\nSam",
"trigger" : ";sig"
},
{
"enabled" : true,
"folder" : "Personal",
"forms" : [
{
"kind" : "street",
"text" : "1 Main St"
},
{
"kind" : "city",
"text" : "Springfield"
}
],
"name" : "Home address",
"text" : "1 Main St, Springfield",
"trigger" : ";home"
},
{
"bindings" : [
{
"host" : "github.com"
}
],
"enabled" : false,
"name" : "Reply to \"thanks\"",
"text" : "You're welcome!",
"trigger" : ";thx"
},
{
"enabled" : true,
"name" : "Account number",
"sensitive" : true,
"text" : "0123 4567",
"trigger" : ";acct"
},
{
"enabled" : true,
"name" : "Wi-Fi password",
"source" : {
"onePassword" : "op://Private/Wi-Fi/password"
},
"text" : "",
"trigger" : ";wifi"
}
],
"type" : "keyseal.snippets"
}
CSV
For spreadsheets and other text expanders. The columns are trigger,name,text,enabled,sensitive,folder, with folder empty for a snippet in none. Every field is in double quotes, a quote inside one is doubled, and line breaks inside a snippet's text stay as they are. Rows end with CRLF, and the file starts with a UTF-8 byte-order mark so spreadsheets read it as UTF-8. Snippets whose text comes from a source have no text to write, so they're left out. A formatted snippet goes in as its plain text.
"trigger","name","text","enabled","sensitive","folder" "@email","Email","sam@example.com","true","false","Personal" ";sig","Signature","Best, Sam","true","false","" ";home","Home address","1 Main St, Springfield","true","false","Personal" ";thx","Reply to ""thanks""","You're welcome!","false","false","" ";acct","Account number","0123 4567","true","true",""
Sealed exports
A .keysealexport file holds your whole library, sensitive snippets and records included, locked with a passphrase you choose. It's laid out the same way as the vault:
| Bytes | What they hold |
|---|---|
| 3 | KSX |
| 1 | The format: 1. |
| 4 | The header's length, big-endian. |
| as long as that | The header, as JSON: format, minimumReader, keyID, deviceID (empty here) and slots, with one passphrase slot. |
| the rest | The contents, sealed with AES-256-GCM: a 12-byte nonce, the ciphertext, then a 16-byte tag. Every byte before them is the authenticated data, so the header can't be changed on its own. |
The key is a random 256-bit key made for this export, in the passphrase slot. The contents are JSON with version, exported (seconds since 1 January 2001), app and contents, the library as the vault holds it (below), with sensitive values sealed with the export's key.
The passphrase slot
Sealed exports and the recovery file keep their key the same way. The slot has kind (passphrase), salt (16 bytes, base64), rounds (600,000) and wrappedKey (60 bytes, base64). To get the key:
- Derive a 32-byte key with PBKDF2-HMAC-SHA256 from the passphrase (UTF-8, in Unicode normal form C), the salt and the rounds.
- Open
wrappedKeywith it, as AES-256-GCM (12-byte nonce, the 32-byte key, a 16-byte tag), with the authenticated datakeyseal.passphrase-slot, a zero byte, and thekeyIDas text. - Check it:
keyIDis the first 8 bytes, in hex, of HMAC-SHA256 with the key over the textsigil.key-id.
The recovery file
A .keysealrecovery file holds your vault's key in a passphrase slot, so a new Mac, or a lost Keychain, never costs you your snippets. It's plain JSON: type (keyseal.recovery), format (1), keyID, slot, created and a note. The file and its passphrase together open your vault and every snapshot of it. Neither does alone.
The vault
vault.keyseal, and each snapshot in Backups, is laid out like a sealed export, with KSV and format 3. Its header names the key by keyID, and its one slot, device, says the key is in your login Keychain, as “Keyseal vault key”. The recovery file holds the same key.
The contents are Keyseal's own JSON, which may change between versions. Use the plain JSON export to move snippets. Inside, sensitive text and record values are sealed again with the same key, as {"sealed": …} in base64 (nonce, ciphertext, tag). The authenticated data is the snippet's id as 16 bytes, or for a record value the text sigil.record followed by the record's and the value's ids, 16 bytes each.
A header with a minimumReader higher than a Keyseal knows makes that Keyseal open the vault read-only, so an older version never saves over a newer file. From Keyseal 1.0, format 3 stays as it is: a version that adds something an older one would drop raises minimumReader.
Sync files
With sync on, each Mac writes vault.<id>.keyseal to the Keyseal folder in the folder you chose. The id is 16 hex characters, the start of a SHA-256 hash of the Mac's hardware id, so it's the same on every launch and can't be traced back to the Mac. Each Mac writes only its own file and reads the others'. Files with any other name, such as a sync service's conflict copies, are ignored.
The file is laid out like the vault, with KSY and format 1. Its header names the vault key by keyID and the Mac by deviceID, and its one slot is device: there's never a passphrase slot, so the file is only as easy to open as the random key. Inside is JSON with the Mac's name, when it was written, and the synced library: snippets, folders, records and deletions, as the vault holds them.
Each snippet, folder and record has a revision, raised by one at every save that changes it, and updated. A deletion keeps the id and the revision it was deleted at, for 365 days. Each Mac merges every file it reads: for each id the higher revision wins, then the later updated, so every Mac comes to the same library whatever order the files arrive in. A file that doesn't open is waited for, never taken to mean anything was deleted. A file whose minimumReader is higher than a Keyseal knows pauses sync on that Mac until it's updated.
Other files
emissions.keyseal (where expansions went), harvest.keyseal (suggestion counts) and messages.keyseal (learned replies) start with KSE, KSH or KSM and a version byte, followed by an AES-256-GCM box with those 4 bytes as the authenticated data. Each has its own key, derived from the vault's with HKDF-SHA256 (no salt, 32 bytes, info sigil.emissions, sigil.harvest or sigil.messages). What's inside is Keyseal's own and may change. What Keyseal stores says what each holds.
The license
A .keyseal-license file is plain text, signed, not encrypted: a line naming who it's for, then a token between -----BEGIN KEYSEAL LICENSE----- and -----END KEYSEAL LICENSE-----, wrapped at 64 characters. The token is KS1., the signing key's id, a dot, the payload, a dot and the signature, both in base64url without padding. The payload is JSON with v, kid, product, id, name, email, purchased and updatesUntil; the signature is Ed25519 over the payload's exact bytes. Keyseal checks it on your Mac, against public keys built into the app.
Files written before Keyseal was renamed start with SGL, SGH, SGE or SGM; Keyseal still reads them.