Skip to content

Front Matter#

Every FoldNotes note begins with a YAML front matter block. This metadata is managed automatically — you never see it in the editor.

Schema#

---
id: 8A3F2B1C-1234-5678-9ABC-DEF012345678
created: 2026-04-03T10:30:00Z
title: Meeting Notes
favourite: true
daily: 2026-04-03
fn-tasks: 2:A1B2C3D4-...,7:E5F6A7B8-...
fn-hash: a1b2c3d4e5f6a7b8
status: draft
category: work
---

Fields#

System Fields (managed by FoldNotes)#

Field Type Description
id UUID Unique identifier. Auto-generated, never modify.
created ISO 8601 Creation timestamp
title String Display title (filename is canonical)
favourite Boolean Whether the note is marked as a favourite
daily Date Daily note date (YYYY-MM-DD). Present only on daily notes.
fn-tasks String Task paragraph UUIDs (internal, do not modify)
fn-hash String Content hash for corruption detection (internal)
fn-favourite Boolean Favourite status, persisted for cross-device sync
fn-name-locked Boolean The note has been named deliberately — stops its name following the first heading. See Naming Notes
fn-archived Boolean Whether the note is archived
fn-folded String Folded section state (internal)
fn-cursor String Cursor position for restore on reopen (internal)

Fields prefixed with fn- are FoldNotes-specific metadata. In compatible mode collections, these fields are stripped to keep files clean for other tools.

Custom Properties#

You can add any custom key-value pairs:

---
id: ...
created: ...
title: My Note
status: draft
category: work
priority: high
---

Custom properties show at the top of the note, where you can add them and change their values on the Mac, iPhone and iPad (see Properties). They can also be queried via the CLI (macOS):

fn list --property "status=draft"
fn show "My Note" --properties
fn edit "My Note" --set-property "status=done"
fn edit "My Note" --remove-property "draft"

How Front Matter Works#

  1. On load: FoldNotes reads the front matter, strips it from the text, and stores it separately. The editor only shows the note body.
  2. On save: FoldNotes re-serialises the front matter (with any updates) and prepends it to the body text before writing the file.
  3. Content hash: The fn-hash field is a SHA-256 hash of the body text (first 16 hex characters). It's recomputed on every save for corruption detection and recovery.

Editing Front Matter#

The recommended way to edit front matter is through:

  • The properties at the top of the note (for custom properties)
  • The CLI (fn edit --set-property, fn edit --remove-property)
  • The toolbar (for favourites, title)

Directly editing the YAML in the file is possible but not recommended — FoldNotes manages the system fields automatically.