A template is a piece of Markdown. Everything you write in it is inserted as it is, except placeholders: markers in double curly braces that MarkNode replaces when you insert the template. You write and edit templates in the Templates & Extensions window (see Managing Templates). Click the ? button beside the body for a reminder of the syntax — see Syntax Help.
Placeholders
| Placeholder | What it does |
|---|---|
{{title}} | A text field named title. You type its value when you insert the template. |
{{difficulty|easy,medium,hard}} | A choice field: you pick one of the listed values. |
{{0}} | Where the cursor ends up after the template is inserted. |
{{selection}} | The text that was selected when you inserted the template, or nothing. |
{{clipboard}} | The text on the clipboard, or nothing when the clipboard can’t be read. |
{{date}} | Today’s date as year, month and day, such as 2026-03-14. |
{{date:FORMAT}} | The current date and time in your own format (see below). |
A field name can contain spaces, so {{slide title}} works. When the same name appears more than once, it is one field: you fill it in once and every occurrence gets the value.
For example, this template asks for a title and a speaker, and leaves the cursor below them:
## {{title}}
Speaker: {{speaker}}
{{0}}
Date Formats
{{date:FORMAT}} uses these tokens. They are replaced wherever they appear in the format, even inside a word — {{date:Due DD}} would turn the “D” of “Due” into the day — so keep words outside the placeholder and write Due {{date:DD}} instead. Punctuation and spaces, such as -, /, : and ., are kept as written.
| Token | Meaning | Example |
|---|---|---|
YYYY | Four-digit year | 2026 |
YY | Two-digit year | 26 |
MM / M | Month, with and without a leading zero | 03 / 3 |
DD / D | Day of the month, with and without a leading zero | 07 / 7 |
HH / H | Hour (24-hour clock), with and without a leading zero | 09 / 9 |
mm | Minutes | 05 |
ss | Seconds | 30 |
For example, {{date:YYYY-MM-DD HH:mm}} inserts 2026-10-07 09:05.
Writing Literal Braces
To insert {{ as text rather than start a placeholder, write \{{. Anything in double braces that isn’t a valid placeholder, such as {{}}, is also kept as written.
Template Settings
Besides its body, each template has a few settings. You set them in the Templates & Extensions window (see Managing Templates), and they are saved with the template:
- Name — the template’s name, shown in every template list.
- Description — a short line shown under the name in the template lists.
- Trigger — a short word you can type after
/in the editor to find the template quickly. Use letters, digits and underscores only: the/menu stops reading at a hyphen or a space. - Fields — one row for each field in the body, where you set its Type, a Label shown instead of the field name when you fill it in, a Default value, and for a choice field, its Choices.
The five field types are:
| Type | What you fill in |
|---|---|
| Text | One line of text. This is the type of every new field. |
| Multiline | A larger box that takes several lines. |
| Choice | One value from a list. Write the list in the placeholder, as in {{difficulty|easy,medium,hard}}, or in the field’s Choices. |
| Date | A date, filled in with today’s date as 2026-03-14 unless you set a Default. |
| Path | The location of a file, with a Browse… button and a place to drop a file. |
Path Fields
A field becomes a Path field in two ways:
- Automatically, when you use its placeholder as the destination of a link or an image:
[Handout]({{file}})makesfilea path field, andmakesimageone. A field used both as a destination and elsewhere in the text is a path field too. - By setting its type, so it works wherever you use it: in the template’s Fields, change the field’s Type to Path. It is saved as
type: pathin the template’s header, which you can also write yourself if you edit the file directly. A type you set yourself always wins over the automatic choice, so setting Text turns a link destination back into an ordinary field. A placeholder with a list of values, such as{{img|a.png,b.png}}, stays a choice field.
When you insert the template, a path field has a Browse… button, and you can drop a file on it. The inserted value is the file’s path relative to the document, and a file from outside the project is copied into the document’s image folder first. A path field used only for images offers image files in Browse…. See Path Fields for what you see when you insert.
The placeholders in the body decide which fields exist: type a placeholder in the Body, and its row appears in Fields.
For example, the Exercise starter template asks for a title, a difficulty and an estimated time. Its body includes:
## Exercise: {{title}}
Difficulty: {{difficulty}} · Estimated time: {{minutes}} minutes
In Fields, difficulty is a Choice of easy, medium and hard with the default medium, and minutes has the label “Estimated time (minutes)” and the default 10.
How Headings Are Re-levelled
When you insert a template, MarkNode moves all of its headings up or down by the same amount, so that its top heading lands at the right level for the place you insert it:
- In the editor, you choose the position in the Where step: as a child of the section you’re in (one level deeper than its heading), or after it or after one of the sections around it (at that section’s level). In a section under a level 2 heading, As child of gives a template whose top heading is
#or##a###top heading. Above the first heading of a document, the top heading becomes level 1. A template with no headings is inserted as it is. - From the editor’s right-click menu on a heading line, the position is the one you choose from the menu, as in the mind map.
- In the mind map and outline, a template inserted before, after or in place of a node gets that node’s level, and one inserted as a child goes one level deeper.
The other headings keep their place relative to the top heading. A heading that would go deeper than level 6 becomes a bullet point instead. Headings inside code blocks are never changed.
In the editor, you choose the position when you insert the template, in the Where step, which shows the level each choice gives its top heading. See Choosing Where It Goes.
Write your template’s top heading as #: where you insert the template sets its level, and the headings below it keep their offset from it.
Syntax Help
In the Templates & Extensions window, the ? button beside the Body (its tooltip is Template syntax help) opens a short cheat sheet:
- Placeholders —
{{name}}for a field,{{name|a,b,c}}for a choice,{{date:FORMAT}},{{selection}},{{clipboard}},{{0}}, and[text]({{file}})andfor path fields, each with a one-line explanation - Headings — the reminder to write your top heading as
#
Choose Learn more at the bottom to open this page in your browser. Press Escape or click outside the cheat sheet to close it.