Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
docs(user): restore the space after inline icons
Elian Dorane15e4fdc3a21
diff --git a/apps/server/src/assets/help/help_content.json b/apps/server/src/assets/help/help_content.jsonindex 41dbfffa5c..59662d9d51 100644--- a/apps/server/src/assets/help/help_content.json+++ b/apps/server/src/assets/help/help_content.json@@ -153,7 +153,7 @@"_help_0vgWgxQAWj4a": "<aside class=\"admonition important\"><p>Sorting the selection is experimental, and it changes as it matures. To use it, turn on <em>Sort selection in text editor</em> in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Advanced</em> → <em>Experimental Options</em>.</p></aside><p>Trilium can sort the items of a list, a group of paragraphs or the rows of a table in a text note, comparing numbers, dates and times by their value.</p><h2>Sorting</h2><ul><li>To sort, place the cursor in a list or a table, or select the paragraphs to sort, then press the <span class=\"tn-icon bx bx-sort-alt-2\"></span> <em>Sort</em> button of the <a class=\"reference-link\" href=\"#root/_help_nRhnJkTT8cPs\">Formatting toolbar</a> to sort in ascending order. The arrow beside it offers <em>Ascending</em> and <em>Descending</em>. With the floating toolbar, the button is in the block-level popup.</li><li>When the selection covers several paragraphs, list items or table cells, the same choices are also in a submenu at the bottom of the menu of the block handle, the sequence of dots to the left of the block, and in the right-click menu of the selection. The submenu is named after what it sorts: <em>Sort blocks</em>, <em>Sort list items</em> or <em>Sort rows</em>.</li><li>On the <a class=\"reference-link\" href=\"#root/_help_RDslemsQ6gCp\">Mobile Frontend</a>, the button is in the main row of the toolbar and in the row of the <em>List ›</em> button.</li></ul><p>A sort can be undone with <kbd>Ctrl</kbd>+<kbd>Z</kbd>.</p><h2>What is sorted</h2><ul><li><strong>List items</strong>: with the cursor in a list, the items at its level are sorted. Nested items move with the item they belong to and keep their own order. To sort only some of the items, select them.</li><li><strong>Paragraphs and other blocks</strong>: select two or more paragraphs, headings, quotes, collapsible blocks or images. Each block is sorted by its first text: a collapsible block by its title, a quote by its first paragraph and an image by its caption. A selection that mixes a list with other blocks cannot be sorted.</li><li><strong>Table rows</strong>: the rows are sorted by the column of the cursor, as described in <em>Sorting rows</em> in <a class=\"reference-link\" href=\"#root/_help_NdowYOC1GFKS\">Tables</a>. Inside a table cell, a list or several selected paragraphs are sorted instead of the rows.</li></ul><p>Values are compared the same way as table rows, see <em>How values are compared</em> in <a class=\"reference-link\" href=\"#root/_help_NdowYOC1GFKS\">Tables</a>.</p><h2>Limitations</h2><ul><li>The lines of a code block, or of a paragraph split with <kbd>Shift</kbd>+<kbd>Enter</kbd>, are not sorted one by one. A <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> note can sort its lines, see <em>Transforming text</em> there.</li></ul>","_help_oBo3iHIZnbG2": "<p>Trilium supports spell checking for your notes. How it works depends on whether you're using the <strong>desktop application</strong> (Electron) or accessing Trilium through a <strong>web browser</strong>.</p><h2>Desktop</h2><p>The desktop app uses Chromium's built-in spellchecker. You can configure it from <em>Options</em> → <em>Spell Check</em>.</p><h3>Enabling spell check</h3><p>Toggle <em>Check spelling</em> to enable or disable the spellchecker. A restart is required for changes to take effect — use the restart button at the bottom of the section.</p><h3>Choosing languages</h3><p>When spell check is enabled, a <em>Spell Check Languages</em> section appears listing all languages available on your system. Select one or more languages by checking the boxes. The spellchecker will accept words that are valid in <em>any</em> of the selected languages.</p><p>The available languages depend on your operating system's installed language packs. For example, on Windows you can add languages through <em>Options</em> → <em>Time & Language</em> → <em>Language & Region</em> → <em>Add a language</em>.</p><aside class=\"admonition note\"><p>The changes take effect only after restarting the application.</p></aside><h3>Custom dictionary</h3><aside class=\"admonition tip\"><p>This function is available starting with Trilium v0.103.0.</p></aside><p>Words you add to the dictionary (e.g. via the right-click context menu → \"Add to dictionary\") are stored in a <strong>synced note</strong> inside Trilium. This means your custom dictionary automatically syncs across all your devices.</p><p>You can view and edit the dictionary directly from <em>Settings</em> → <em>Spell Check</em> → <em>Custom Dictionary</em> → <em>Edit dictionary</em>. This opens the underlying note, which contains one word per line. You can add, remove, or modify entries as you like.</p><aside class=\"admonition note\"><p>Changes to the custom dictionary (whether from the editor or the context menu) take effect after restarting the application.</p></aside><h4>How the custom dictionary works</h4><ul><li>When you right-click a misspelled word and choose \"Add to dictionary\", the word is saved both to Electron's local spellchecker and to the synced dictionary note.</li><li>On startup, Trilium loads all words from the dictionary note into the spellchecker session.</li><li>If Trilium detects words in Electron's local dictionary but the dictionary note is empty (e.g. on first use), it performs a <strong>one-time import</strong> of those words into the note.</li><li>Words that are in Electron's local dictionary but <em>not</em> in the note (e.g. you removed them manually) are cleaned up from the local dictionary on startup.</li></ul><h4>Known limitations</h4><p>On Windows and macOS, Electron delegates \"Add to dictionary\" to the operating system's user dictionary. This means:</p><ul><li>Words added via the context menu are also written to the OS-level dictionary (e.g. <code>%APPDATA%\\Microsoft\\Spelling\\<language>\\default.dic</code> on Windows).</li><li><strong>Removing a word</strong> from the Trilium dictionary note prevents it from being loaded into the spellchecker on next startup, but does <em>not</em> remove it from the OS dictionary. The word may still be accepted by the OS spellchecker until you remove it from the OS dictionary manually.</li></ul><h2>Web browser</h2><p>When accessing Trilium through a web browser, spell checking is handled entirely by the browser itself. Trilium does not control the browser's spellchecker — language selection, dictionaries, and all other settings are managed through your browser's preferences.</p><p>The <a class=\"reference-link\" href=\"#root/_help_jcQVxzYybYgz\">Note contextual menu</a> has a special behavior in which a right-clicked word (without selection) shows the browser's default contextual menu which allows the spellcheck to function.</p><p>The Spell Check settings page in Trilium will indicate that these options apply only to desktop builds.</p><h2>Frequently asked questions</h2><h3>Do I need to restart after every change?</h3><p>Yes. Spell check language selection and the custom dictionary are loaded once at startup. Any changes require a restart to take effect.</p><h3>Can I use multiple spell check languages at the same time?</h3><p>Yes. Select as many languages as you need from the checklist. The spellchecker will accept words from any of the selected languages.</p><h3>My custom words disappeared after syncing to a new device — what happened?</h3><p>On the first launch of a new device, Trilium may import existing local dictionary words into the note. If the note already has words from another device (via sync), those are preserved. Make sure sync completes before restarting the application on a new device.</p><h3>I removed a word from the dictionary note but it's still accepted</h3><p>This is likely due to the OS-level dictionary retaining the word (see <a href=\"#known-limitations\">Known limitations</a> above). You can manually remove it from your operating system's user dictionary.</p>","_help_BFvAtE74rbP6": "<aside class=\"admonition note\"><p>This page has been relocated to <a class=\"reference-link\" href=\"#root/_help_2dcGDhp9WFKb\">Outline tab</a>.</p></aside>",- "_help_NdowYOC1GFKS": "<p>Tables are a powerful feature for <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes, since editing them is generally easy.</p><figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:176/204;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/2_Tables_image.png\" width=\"176\" height=\"204\"></figure><p>To create a table, simply press the table button and select with the mouse the desired amount of columns and rows, as indicated in the adjacent figure.</p><p>Since v0.107.0, the same menu starts with an <em>Insert table…</em> item, for a table larger than the grid or to type its size instead:</p><ol><li>Click the <span class=\"tn-icon cke cke-table\"></span>button and select <em>Insert table…</em>. A small form opens at the cursor.</li><li>Enter the number of <em>Columns</em> (up to 100) and <em>Rows</em> (up to 1000). The table can have at most 5000 cells in total, for example 1000 rows of 5 columns.</li><li>Optionally, turn on <em>Use headers</em> and enter the number of <em>Header columns</em> and <em>Header rows</em>. A table cannot have more header columns or rows than it has columns or rows.</li><li>Press <em>Insert</em> or <kbd>Enter</kbd>.</li></ol><p>To close the form without inserting a table, press <kbd>Esc</kbd> or click outside it. From the keyboard, <kbd>Tab</kbd> moves between <em>Insert table…</em> and the grid while the menu is open.</p><p>On the <a class=\"reference-link\" href=\"#root/_help_RDslemsQ6gCp\">Mobile Frontend</a>, the table is inserted from the <span class=\"tn-icon cke cke-plus\"></span> button of the formatting toolbar: its <em>Insert table</em> tile lists common sizes, from 2 × 2 to 3 × 4 (rows × columns). Tap one to insert a table of that size; to make it larger, insert rows and columns afterwards.</p><h2>Formatting toolbar</h2><p>When a table is selected, a special formatting toolbar will appear:</p><img src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/3_Tables_image.png\" width=\"384\" height=\"100\"><p>On the <a class=\"reference-link\" href=\"#root/_help_RDslemsQ6gCp\">Mobile Frontend</a>, the toolbar does not float over the table. Instead, press the <span class=\"tn-icon cke cke-table\"></span> button after <em>Undo</em> and <em>Redo</em> in the formatting toolbar at the bottom of the screen to show the table's toolbar there.</p><h2>Context menu</h2><p>Since v0.106.0, right-clicking anywhere inside a table opens a context menu with the most common table operations:</p><ul><li><em>Insert row above</em> and <em>Insert row below</em> insert a blank row next to the row of the current cell. When the selection spans multiple rows, the same number of rows is inserted.</li><li><em>Insert column to the left</em> and <em>Insert column to the right</em> work the same way for columns.</li><li>Since v0.107.0, <em>Set as header</em> or <em>Set header up to this row</em>, depending on the selection, turns rows into header rows, which always start at the top of the table:<ul><li><em>Set as header</em> shows when the selection starts at the first row, and makes every selected row a header row.</li><li><em>Set header up to this row</em> shows when the selection is in a single row below the first, and makes that row and every row above it header rows.</li><li>Neither shows when the selection spans several rows below the first.</li><li>A check mark shows that the rows are already header rows. Choosing the item again turns them, and every header row below them, back into regular rows. For example, in a table with five header rows, choosing <em>Set header up to this row</em> on the third row leaves only the first two as header rows.</li></ul></li><li><em>Merge cells</em> merges the selected cells into one. The selected cells must form a rectangle.</li><li><em>Split cell</em> splits each selected cell in two, either <em>Vertically</em> or <em>Horizontally</em>. <em>Unmerge cells</em>, in the same submenu, turns each merged cell in the selection back into the single cells it covers, keeping its content in the top-left one; cells that are not merged stay as they are.</li><li><em>Distribute columns evenly</em> splits the combined width of the columns the selection touches equally between them. The other columns and the width of the table stay as they are. It needs a selection spanning at least two columns; a merged cell counts for every column it covers.</li><li><em>Cut</em>, <em>Copy</em> and <em>Copy as Markdown</em> act on the selected cells. Since v0.107.0, <em>Copy</em> and <em>Paste</em> open submenus with their variants, such as <em>Copy as Markdown</em> and <em>Paste as plain text</em>; clicking <em>Copy</em> or <em>Paste</em> itself still copies or pastes:<ul><li>Cutting or copying produces a smaller table holding just the selected cells. Pasting it over a cell selection replaces those cells; pasting elsewhere inserts it as a table of its own. Cutting clears the cells without removing rows or columns.</li><li><em>Copy as Markdown</em> converts the selected cells to a Markdown table. A selected header row becomes the Markdown header; without one, an empty header row is emitted, since Markdown tables require one.</li></ul></li><li>Since v0.107.0, <em>Paste rows above</em> and <em>Paste rows below</em>, in the <em>Paste</em> submenu, paste the clipboard as new rows next to the row of the current cell, instead of over the cells from the cursor on. They show only when the selection is in a single row, and, like <em>Paste</em>, only where the clipboard can be read:<ul><li>A copied table becomes one new row for each of its rows, filled from the first column. When it has more columns than the table, the table gains columns, as with a regular paste. Other content goes in the first cell of a single new row.</li><li>The new rows are selected afterwards.</li><li>When merged cells join the row to others, the new rows go above or below that whole block of rows.</li></ul></li><li><em>Sort</em>, below the clipboard section, sorts the rows by the column of the current cell, in <em>Ascending</em> or <em>Descending</em> order. See <a href=\"#sorting-rows\">Sorting rows</a>.</li><li><em>Delete row</em> and <em>Delete column</em>, below <em>Sort</em>, remove every row or column the selection touches, even when only some of their cells are selected.</li><li><em>Delete table</em> removes the whole table and leaves an empty paragraph in its place. In a table nested inside another, only the inner table is removed.</li><li>Since v0.107.0, <em>Select</em>, below <em>Delete table</em>, selects the cells of every row (<em>Row</em>) or column (<em>Column</em>) the selection touches, or every cell of the table (<em>Table</em>). Unlike the <span class=\"tn-icon cke cke-drag-handle\"></span>button, which selects the table as a whole, <em>Table</em> selects its cells, so cell operations such as <em>Merge cells</em> apply to all of them. In a table nested inside another, <em>Table</em> selects only the cells of the inner table.</li></ul><p>Right-clicking a cell that is not part of the current selection moves the cursor there first, so the menu always applies to the cell under the pointer.</p><aside class=\"admonition note\"><p>In the browser, Trilium's menu replaces the browser's own context menu inside tables. To reach the browser's menu (for example for its spell checking suggestions), hold <kbd>Shift</kbd> while right-clicking. The desktop application is unaffected, since its menu already includes the spelling suggestions. In the browser, the menu also offers <em>Paste</em> only when the page can read the clipboard, which requires a secure (HTTPS) context and your permission; otherwise, paste with <kbd>Ctrl</kbd>+<kbd>V</kbd>.</p></aside><h2>Navigating a table</h2><ul><li>Using the mouse:<ul><li>Click on a cell to focus it.</li><li>Click the <span class=\"tn-icon cke cke-return-arrow\"></span> button at the top or the bottom of a table to insert an empty paragraph near it.</li><li>Click the <span style=\"--tn-color:hsl(0,0%,60%);color:hsl(0,0%,60%);\"><span class=\"tn-icon cke cke-drag-handle\"></span></span> button at the top-left of the table to select it entirely (for easy copy-pasting or cutting) or drag and drop it to relocate the table.</li></ul></li><li>Using the keyboard:<ul><li>Use the arrow keys on the keyboard to easily navigate between cells.</li><li>It's also possible to use <kbd>Tab</kbd> to go to the next cell and Shift+Tab to go to the previous cell.</li><li>Unlike arrow keys, pressing <kbd>Tab</kbd> at the end of the table (last row, last column) will create a new row automatically.</li><li>To select multiple cells, hold <kbd>Shift</kbd> while using the arrow keys.</li></ul></li><li>Using touch:<ul><li>Since v0.107.0, touching a table outlines the cell with the cursor, or the selected cells, and shows a handle at each corner of the outline.</li><li>To select multiple cells, drag one of the handles across the table. The cell at the opposite corner stays selected, so the selection grows or shrinks as the finger moves. The note and wide tables scroll when the handle reaches the edge of the screen.</li></ul></li></ul><h2>Resizing cells</h2><ul><li>Columns can be resized by hovering the mouse over the border of two adjacent cells and dragging it.</li><li>To give several columns the same width, select cells across them and choose <em>Distribute columns evenly</em> from the <span class=\"tn-icon cke cke-table-column\"></span>button of the formatting toolbar or from the <a href=\"#context-menu\">context menu</a>.</li><li>By default, the row height is not adjustable using the mouse, but it can be configured from the cell settings (see below).</li><li>To adjust exactly the width (in pixels or percentages) of a cell, select the <span class=\"tn-icon cke cke-table-cell-properties\"></span> button.</li></ul><h3>Resizing with touch</h3><p>Since v0.107.0, touching a table shows a bar at the bottom of the note, above the formatting toolbar on mobile. The bar has a segment for each column of the table, with a divider at the end of each column. Only the divider of the column with the cursor is a handle that resizes; the other dividers only mark where the columns meet, so a swipe across them scrolls instead. When several cells are selected, each column they cover has a handle.</p><ul><li>To resize a column, place the cursor in one of its cells or tap its segment, then drag its handle. The table grows or shrinks with the column, and scrolls when the handle reaches the edge of the screen. The column snaps to its starting width and to the widths of the columns beside it.</li><li>To cancel a resize, drag the handle back to where it started, or touch the screen with a second finger.</li><li>To give a column and the next one the same width, double-tap the handle between them.</li><li>To select a column, tap its segment. To open the column menu, touch and hold the segment.</li><li>To scroll a wide table sideways, swipe along the bar.</li></ul><p>A wide table scrolls a little past its end, so the handle of its last column stays away from the edge of the screen, where a swipe navigates back.</p><h2>Wide tables</h2><p>Since v0.107.0, a table can be wider than the <a class=\"reference-link\" href=\"#root/_help_t596jLvPrqkS\">Content width</a>. Such a table scrolls sideways, while the rest of the note keeps its width.</p><ul><li>A new table is as wide as the content. To make it wider, drag the right border of its last column past the edge of the content. The border snaps to the edge and holds there briefly, so the table is easy to bring back to the width of the content.</li><li>To set an exact width, enter a percentage above <code>100%</code> or a width in pixels in the <span class=\"tn-icon cke cke-table-properties\"></span> <a href=\"#table-properties\">table properties</a>.</li><li>A table whose content needs more room than the note, such as a pasted table with many columns, also scrolls instead of stretching the note.</li><li>Wide tables scroll the same way in read-only notes and on shared pages.</li><li>When printing or exporting to PDF, a wide table is shrunk to fit the page.</li></ul><p>Tables inside other blocks, such as block quotes, admonitions, collapsible blocks, columns or tabs, are limited to the width of their block and do not scroll.</p><h3>Mobile support</h3><p>On the <a class=\"reference-link\" href=\"#root/_help_RDslemsQ6gCp\">Mobile Frontend</a>, a table keeps the width it has on a desktop and scrolls sideways, instead of squeezing its columns into the width of the screen. The full width of a table is the <em>Max content width</em> set in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Appearance</em> → <em>Content Width</em> on the mobile device, 1200 pixels by default. For example, a table set to <code>50%</code> is 600 pixels wide.</p><p>To resize columns on mobile, use the bar described in <a href=\"#resizing-with-touch\">Resizing with touch</a>.</p><h2>Long tables</h2><p>Since v0.107.0, the header rows of a table stay visible at the top of the note while you scroll through the rest of the table, and leave with the end of the table. This also works in read-only notes, on shared pages and in wide tables.</p><p>To turn rows into header rows, use <em>Set as header</em> in the <a href=\"#context-menu\">context menu</a>, or <em>Header row</em> in the <span class=\"tn-icon cke cke-table-row\"></span> button of the formatting toolbar.</p><p>To let header rows scroll away with the rest of the table, turn off <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Text Notes</em> → <em>Features</em> → <em>Use sticky header rows for tables</em>. The setting applies to the current device only, and shared pages keep their sticky header rows.</p><h2>Inserting new rows and new columns</h2><ul><li>To insert a new column, click on a desired location, then press the <span class=\"tn-icon cke cke-table-column\"></span> button from the formatting toolbar and select <em>Insert column left or right.</em></li><li>To insert a new row, click on a desired location, then press the <span class=\"tn-icon cke cke-table-row\"></span> button and select <em>Insert row above</em> or <em>below</em>.<ul><li>A quicker alternative to creating a new row while at the end of the table is to press the <kbd>Tab</kbd> key.</li></ul></li><li>Both operations are also available in the <a href=\"#context-menu\">context menu</a>, which inserts as many rows or columns as the selection spans.</li></ul><h2>Moving rows and columns</h2><p>Since v0.106.0, rows and columns can be reordered with the keyboard:</p><ul><li><kbd>Alt</kbd>+<kbd>Up</kbd> and <kbd>Alt</kbd>+<kbd>Down</kbd> move the rows touched by the selection up or down.</li><li><kbd>Alt</kbd>+<kbd>Left</kbd> and <kbd>Alt</kbd>+<kbd>Right</kbd> move the columns touched by the selection left or right.</li></ul><p>Merged cells are never split by a move. The rows or columns held together by a merged cell travel as one block, and moving toward such a block jumps over it entirely.</p><p>When the table has a header row, a header row moved below the header area becomes a regular row, and a regular row moved into the header area becomes a header row. Header columns behave the same way.</p><p>Outside of tables, <kbd>Alt</kbd>+<kbd>Left</kbd> and <kbd>Alt</kbd>+<kbd>Right</kbd> keep navigating the note history, and <kbd>Alt</kbd>+<kbd>Up</kbd> and <kbd>Alt</kbd>+<kbd>Down</kbd> keep moving the current paragraph.</p><h2>Sorting rows</h2><p>Since v0.107.0, the rows of a table can be sorted by the values of one column:</p><ul><li>To sort all the rows, place the cursor in any cell of the column to sort by, then select <em>Sort</em> → <em>Ascending</em> or <em>Descending</em> from the <a href=\"#context-menu\">context menu</a>. The same items are in the <span class=\"tn-icon bx bx-sort-alt-2\"></span>button of the formatting toolbar.</li><li>To sort only some of the rows, select their cells in the column to sort by, then sort the same way. Sorting is not available while the selection spans more than one column.</li></ul><p>Header rows always stay at the top of the table and are never sorted. A sort can be undone with <kbd>Ctrl</kbd>+<kbd>Z</kbd>.</p><h3>How values are compared</h3><p>Each cell is read as plain text, so formatting does not affect the order. Trilium then detects what kind of value the cell holds:</p><figure class=\"table\"><table><thead><tr><th>Kind</th><th>Examples</th><th>Compared by</th></tr></thead><tbody><tr><td>Time</td><td><code>15:02</code>, <code>15:02:38</code>, <code>3:02 PM</code></td><td>The time of day.</td></tr><tr><td>Date</td><td><code>2026-09-30</code>, <code>2026-09-30 15:02</code>, <code>30 September 2026</code>, <code>Wednesday, 30 September 2026</code>, <code>2026-09-30T15:02:38+03:00</code></td><td>The date and time.</td></tr><tr><td>Number</td><td><code>12</code>, <code>-3.5</code>, <code>1,234.56</code>, <code>$ 12.04</code>, <code>21 RON</code>, <code>24.5m</code></td><td>The numeric value.</td></tr><tr><td>Text</td><td>Anything else.</td><td>Alphabetically, ignoring case, with numbers inside the text in numeric order (<code>Item 9</code> before <code>Item 10</code>). Accents count, so <code>a</code> and <code>á</code> differ.</td></tr><tr><td>Empty</td><td>An empty cell, or one holding only spaces.</td><td>Not compared. Empty cells always go last.</td></tr></tbody></table></figure><p>Ascending order puts times first, then dates, numbers and text. Descending order reverses it. Empty cells go last in both directions.</p><p>Numbers, dates and times with the same value are ordered by their text, so <code>5 apples</code> comes before <code>5 pears</code>. Rows whose cells hold the same text, ignoring case, keep their relative order.</p><ul><li>Dates are also recognized in the formats of the note's language, such as <code>30.09.2026</code> or <code>30. September 2026</code> for German, and in the format chosen in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Text Notes</em> → <em>Editor</em> → <em>Date/time format</em> for <a href=\"#root/_help_CohkqWQC1iBv\">inserting the date and time</a>.</li><li>A number can start with a currency symbol, such as <code>$</code>, <code>€</code> or <code>£</code>. Whatever follows the number, such as a unit, is ignored, so units are not converted: <code>1 km</code> sorts before <code>500 m</code>. A cell that starts with letters, such as <code>RON 21</code>, is text.</li><li>The decimal separator follows the language of the note: <code>1.500</code> is one and a half in English, but one thousand five hundred in German. A comma or period that is not followed by exactly three digits is always read as a decimal separator, so <code>1,5</code> is one and a half in either language.</li><li>The language of the note set in the <a class=\"reference-link\" href=\"#root/_help_AlJ73vBCjWDw\">Status bar</a> via the <span class=\"tn-icon bx bx-globe\"></span> icon, or else the default content language. See <a class=\"reference-link\" href=\"#root/_help_veGu4faJErEM\">Content language & Right-to-left support</a>.</li></ul><h3>Merged cells</h3><p>Rows joined by a merged cell are kept together and move as one block. The block is sorted by the value in its first row. When the block has more than one cell in the sorted column, the other cells do not affect the order, and a message says so: <em>Some rows were sorted together because merged cells tie them to each other</em>.</p><p>When the selection covers only part of such a block, the whole block is sorted.</p><h2>Merging cells</h2><p>To merge two or more cells together, simply select them via drag & drop and press the <span class=\"tn-icon cke cke-table-merge-cell\"></span> button from the formatting toolbar.</p><p>More options are available by pressing the arrow next to it:</p><ul><li>Click on a single cell and select Merge cell up/down/right/left to merge with an adjacent cell.</li><li>Select <em>Merge selected cells</em> to merge the selected cells, the same as pressing the button itself.</li><li>Select <em>Split cell vertically</em> or <em>horizontally</em>, to split a cell into multiple cells (can also be used to undo a merge).</li><li>Select <em>Unmerge cells</em> to turn each merged cell in the selection back into the single cells it covers, keeping its content in the top-left one.</li></ul><p><em>Merge selected cells</em> and <em>Unmerge cells</em> are available since v0.107.0. Merging and splitting are also available by right-clicking the selected cells, via the <a href=\"#context-menu\">context menu</a>, where <em>Unmerge cells</em> is in the <em>Split cell</em> submenu.</p><h2>Table properties</h2><figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:312/311;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/Tables_image.png\" width=\"312\" height=\"311\"></figure><p>The table properties can be accessed via the <span class=\"tn-icon cke cke-table-properties\"></span> button and allows for the following adjustments:</p><ul><li>Border (not the border of the cells, but the outer rim of the table), which includes the style (single, double), color and width.</li><li>The background color, with none set by default.</li><li>The width and height of the table in percentage (must end with <code>%</code>) or pixels (must end with <code>px</code>).</li><li>The alignment of the table.<ul><li>Left or right-aligned, case in which the text will flow next to it.</li><li>Centered, case in which text will avoid the table, regardless of the table width.</li></ul></li></ul><p>The table will immediately update to reflect the changes, but the <em>Save</em> button must be pressed for the changes to persist.</p><h2>Cell properties</h2><figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:320/386;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/1_Tables_image.png\" width=\"320\" height=\"386\"></figure><p>Similarly to table properties, the <span class=\"tn-icon cke cke-table-cell-properties\"></span> button opens a popup which adjusts the styling of one or more cells (based on the user's selection).</p><p>The following options can be adjusted:</p><ul><li>The border style, color and width (same as table properties), but applying to the current cell only.</li><li>The background color, with none set by default.</li><li>The width and height of the cell in percentage (must end with <code>%</code>) or pixels (must end with <code>px</code>).</li><li>The padding (the distance of the text compared to the cell's borders).</li><li>The alignment of the text, both horizontally (left, centered, right, justified) and vertically (top, middle or bottom).<ul><li>In a centered or right-aligned cell, each item of a bulleted, numbered or to-do list moves together with its bullet, number or checkbox.</li></ul></li></ul><p>The cell will immediately update to reflect the changes, but the <em>Save</em> button must be pressed for the changes to persist.</p><h2>Border and background colors</h2><p>The border and background colors of tables and cells adapt to the <a href=\"#root/_help_Wy267RK4M69c\">theme</a>, the same way as <a href=\"#root/_help_Gr6xFaF6ioJ5\">text colors</a> do. A color picked from the palette, chosen with the color picker or typed in is shown in a lighter or darker shade that suits the current theme, so borders stay visible and text stays readable on the background. The hue stays the same, and the table keeps the color as it was picked.</p><p>Colors applied with older versions of Trilium are shown exactly as they were picked, until the note is next edited.</p><p>Older browsers that can't adapt colors show them exactly as they were picked.</p><h2>Caption</h2><p>Press the <span class=\"tn-icon cke cke-caption\"></span> button to insert a caption or a text description of the table, which is going to be displayed above the table.</p><h2>Table borders</h2><p>By default, tables come with a gray border that is lighter or darker to suit the current <a href=\"#root/_help_Wy267RK4M69c\">theme</a>, so it stays discreet on a dark background.</p><p>To change the default border of every table, set the <code>--text-note-table-border-color</code> variable in a <a href=\"#root/_help_7NfNr5pZpVKV\">custom theme</a> or in <a href=\"#root/_help_AlhDUqhENtH7\">custom app-wide CSS</a>, for example <code>:root { --text-note-table-border-color: #555; }</code>. Set it to <code>transparent</code> to hide the borders of all the tables that don't have a border of their own.</p><p>To adjust the borders, follow these steps:</p><ol><li>Select the table.</li><li>In the floating panel, select the <em>Table properties</em> option (<span class=\"tn-icon cke cke-table-properties\"></span>).<ol><li>Look for the <em>Border</em> section at the top of the newly opened panel.</li><li>This will control the outer borders of the table.</li><li>Select a style for the border. Generally <em>Single</em> is the desirable option.</li><li>Select a color for the border.</li><li>Select a width for the border, expressed in pixels.</li></ol></li><li>Select all the cells of the table and then press the <em>Cell properties</em> option (<span class=\"tn-icon cke cke-table-cell-properties\"></span>).<ol><li>This will control the inner borders of the table, at cell level.</li><li>Note that it's possible to change the borders individually by selecting one or more cells, case in which it will only change the borders that intersect these cells.</li><li>Repeat the same steps as from step (2).</li></ol></li></ol><h3>Tables with invisible borders</h3><p>Tables can be set to have invisible borders in order to allow for basic layouts (columns, grids) of text or <a href=\"#root/_help_mT0HEkOsz6i1\">images</a> without the distraction of their border:</p><ol><li>First insert a table with the desired number of columns and rows.</li><li>Select the entire table.</li><li>In <em>Table properties</em>, set:<ol><li><em>Style</em> to <em>Single</em></li><li><em>Color</em> to <code>transparent</code></li><li>Width to <code>1px</code>.</li></ol></li><li>In Cell Properties, set the same as on the previous step.</li></ol><h2>Table indentation</h2><p>Since v0.104.1, tables can be indented as a block (the whole table moves, rather than just the content of a cell).</p><ol><li>Click the <span style=\"--tn-color:hsl(0,0%,60%);color:hsl(0,0%,60%);\"><span class=\"tn-icon cke cke-drag-handle\"></span></span> button to select the entire table. Otherwise, the indentation applies only to the current cell's content.</li><li>Press <kbd>Tab</kbd> to increase the indent, or <kbd>Shift</kbd>+<kbd>Tab</kbd> to decrease it. Alternatively, use the indentation buttons in the formatting toolbar.</li></ol><p>Markdown does not support indented tables, so the indentation is lost when converting to Markdown.</p><h2>Markdown import/export</h2><p>Simple tables are exported in GitHub-flavored Markdown format (e.g. a series of <code>|</code> items). If the table is found to be more complex (it contains HTML elements, has custom sizes or images), the table is converted to a HTML one instead.</p><p>Generally formatting loss should be minimal when exported to Markdown due to the fallback to HTML formatting.</p>",+ "_help_NdowYOC1GFKS": "<p>Tables are a powerful feature for <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes, since editing them is generally easy.</p><figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:176/204;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/2_Tables_image.png\" width=\"176\" height=\"204\"></figure><p>To create a table, simply press the table button and select with the mouse the desired amount of columns and rows, as indicated in the adjacent figure.</p><p>Since v0.107.0, the same menu starts with an <em>Insert table…</em> item, for a table larger than the grid or to type its size instead:</p><ol><li>Click the <span class=\"tn-icon cke cke-table\"></span> button and select <em>Insert table…</em>. A small form opens at the cursor.</li><li>Enter the number of <em>Columns</em> (up to 100) and <em>Rows</em> (up to 1000). The table can have at most 5000 cells in total, for example 1000 rows of 5 columns.</li><li>Optionally, turn on <em>Use headers</em> and enter the number of <em>Header columns</em> and <em>Header rows</em>. A table cannot have more header columns or rows than it has columns or rows.</li><li>Press <em>Insert</em> or <kbd>Enter</kbd>.</li></ol><p>To close the form without inserting a table, press <kbd>Esc</kbd> or click outside it. From the keyboard, <kbd>Tab</kbd> moves between <em>Insert table…</em> and the grid while the menu is open.</p><p>On the <a class=\"reference-link\" href=\"#root/_help_RDslemsQ6gCp\">Mobile Frontend</a>, the table is inserted from the <span class=\"tn-icon cke cke-plus\"></span> button of the formatting toolbar: its <em>Insert table</em> tile lists common sizes, from 2 × 2 to 3 × 4 (rows × columns). Tap one to insert a table of that size; to make it larger, insert rows and columns afterwards.</p><h2>Formatting toolbar</h2><p>When a table is selected, a special formatting toolbar will appear:</p><img src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/3_Tables_image.png\" width=\"384\" height=\"100\"><p>On the <a class=\"reference-link\" href=\"#root/_help_RDslemsQ6gCp\">Mobile Frontend</a>, the toolbar does not float over the table. Instead, press the <span class=\"tn-icon cke cke-table\"></span> button after <em>Undo</em> and <em>Redo</em> in the formatting toolbar at the bottom of the screen to show the table's toolbar there.</p><h2>Context menu</h2><p>Since v0.106.0, right-clicking anywhere inside a table opens a context menu with the most common table operations:</p><ul><li><em>Insert row above</em> and <em>Insert row below</em> insert a blank row next to the row of the current cell. When the selection spans multiple rows, the same number of rows is inserted.</li><li><em>Insert column to the left</em> and <em>Insert column to the right</em> work the same way for columns.</li><li>Since v0.107.0, <em>Set as header</em> or <em>Set header up to this row</em>, depending on the selection, turns rows into header rows, which always start at the top of the table:<ul><li><em>Set as header</em> shows when the selection starts at the first row, and makes every selected row a header row.</li><li><em>Set header up to this row</em> shows when the selection is in a single row below the first, and makes that row and every row above it header rows.</li><li>Neither shows when the selection spans several rows below the first.</li><li>A check mark shows that the rows are already header rows. Choosing the item again turns them, and every header row below them, back into regular rows. For example, in a table with five header rows, choosing <em>Set header up to this row</em> on the third row leaves only the first two as header rows.</li></ul></li><li><em>Merge cells</em> merges the selected cells into one. The selected cells must form a rectangle.</li><li><em>Split cell</em> splits each selected cell in two, either <em>Vertically</em> or <em>Horizontally</em>. <em>Unmerge cells</em>, in the same submenu, turns each merged cell in the selection back into the single cells it covers, keeping its content in the top-left one; cells that are not merged stay as they are.</li><li><em>Distribute columns evenly</em> splits the combined width of the columns the selection touches equally between them. The other columns and the width of the table stay as they are. It needs a selection spanning at least two columns; a merged cell counts for every column it covers.</li><li><em>Cut</em>, <em>Copy</em> and <em>Copy as Markdown</em> act on the selected cells. Since v0.107.0, <em>Copy</em> and <em>Paste</em> open submenus with their variants, such as <em>Copy as Markdown</em> and <em>Paste as plain text</em>; clicking <em>Copy</em> or <em>Paste</em> itself still copies or pastes:<ul><li>Cutting or copying produces a smaller table holding just the selected cells. Pasting it over a cell selection replaces those cells; pasting elsewhere inserts it as a table of its own. Cutting clears the cells without removing rows or columns.</li><li><em>Copy as Markdown</em> converts the selected cells to a Markdown table. A selected header row becomes the Markdown header; without one, an empty header row is emitted, since Markdown tables require one.</li></ul></li><li>Since v0.107.0, <em>Paste rows above</em> and <em>Paste rows below</em>, in the <em>Paste</em> submenu, paste the clipboard as new rows next to the row of the current cell, instead of over the cells from the cursor on. They show only when the selection is in a single row, and, like <em>Paste</em>, only where the clipboard can be read:<ul><li>A copied table becomes one new row for each of its rows, filled from the first column. When it has more columns than the table, the table gains columns, as with a regular paste. Other content goes in the first cell of a single new row.</li><li>The new rows are selected afterwards.</li><li>When merged cells join the row to others, the new rows go above or below that whole block of rows.</li></ul></li><li><em>Sort</em>, below the clipboard section, sorts the rows by the column of the current cell, in <em>Ascending</em> or <em>Descending</em> order. See <a href=\"#sorting-rows\">Sorting rows</a>.</li><li><em>Delete row</em> and <em>Delete column</em>, below <em>Sort</em>, remove every row or column the selection touches, even when only some of their cells are selected.</li><li><em>Delete table</em> removes the whole table and leaves an empty paragraph in its place. In a table nested inside another, only the inner table is removed.</li><li>Since v0.107.0, <em>Select</em>, below <em>Delete table</em>, selects the cells of every row (<em>Row</em>) or column (<em>Column</em>) the selection touches, or every cell of the table (<em>Table</em>). Unlike the <span class=\"tn-icon cke cke-drag-handle\"></span> button, which selects the table as a whole, <em>Table</em> selects its cells, so cell operations such as <em>Merge cells</em> apply to all of them. In a table nested inside another, <em>Table</em> selects only the cells of the inner table.</li></ul><p>Right-clicking a cell that is not part of the current selection moves the cursor there first, so the menu always applies to the cell under the pointer.</p><aside class=\"admonition note\"><p>In the browser, Trilium's menu replaces the browser's own context menu inside tables. To reach the browser's menu (for example for its spell checking suggestions), hold <kbd>Shift</kbd> while right-clicking. The desktop application is unaffected, since its menu already includes the spelling suggestions. In the browser, the menu also offers <em>Paste</em> only when the page can read the clipboard, which requires a secure (HTTPS) context and your permission; otherwise, paste with <kbd>Ctrl</kbd>+<kbd>V</kbd>.</p></aside><h2>Navigating a table</h2><ul><li>Using the mouse:<ul><li>Click on a cell to focus it.</li><li>Click the <span class=\"tn-icon cke cke-return-arrow\"></span> button at the top or the bottom of a table to insert an empty paragraph near it.</li><li>Click the <span style=\"--tn-color:hsl(0,0%,60%);color:hsl(0,0%,60%);\"><span class=\"tn-icon cke cke-drag-handle\"></span></span> button at the top-left of the table to select it entirely (for easy copy-pasting or cutting) or drag and drop it to relocate the table.</li></ul></li><li>Using the keyboard:<ul><li>Use the arrow keys on the keyboard to easily navigate between cells.</li><li>It's also possible to use <kbd>Tab</kbd> to go to the next cell and Shift+Tab to go to the previous cell.</li><li>Unlike arrow keys, pressing <kbd>Tab</kbd> at the end of the table (last row, last column) will create a new row automatically.</li><li>To select multiple cells, hold <kbd>Shift</kbd> while using the arrow keys.</li></ul></li><li>Using touch:<ul><li>Since v0.107.0, touching a table outlines the cell with the cursor, or the selected cells, and shows a handle at each corner of the outline.</li><li>To select multiple cells, drag one of the handles across the table. The cell at the opposite corner stays selected, so the selection grows or shrinks as the finger moves. The note and wide tables scroll when the handle reaches the edge of the screen.</li></ul></li></ul><h2>Resizing cells</h2><ul><li>Columns can be resized by hovering the mouse over the border of two adjacent cells and dragging it.</li><li>To give several columns the same width, select cells across them and choose <em>Distribute columns evenly</em> from the <span class=\"tn-icon cke cke-table-column\"></span> button of the formatting toolbar or from the <a href=\"#context-menu\">context menu</a>.</li><li>By default, the row height is not adjustable using the mouse, but it can be configured from the cell settings (see below).</li><li>To adjust exactly the width (in pixels or percentages) of a cell, select the <span class=\"tn-icon cke cke-table-cell-properties\"></span> button.</li></ul><h3>Resizing with touch</h3><p>Since v0.107.0, touching a table shows a bar at the bottom of the note, above the formatting toolbar on mobile. The bar has a segment for each column of the table, with a divider at the end of each column. Only the divider of the column with the cursor is a handle that resizes; the other dividers only mark where the columns meet, so a swipe across them scrolls instead. When several cells are selected, each column they cover has a handle.</p><ul><li>To resize a column, place the cursor in one of its cells or tap its segment, then drag its handle. The table grows or shrinks with the column, and scrolls when the handle reaches the edge of the screen. The column snaps to its starting width and to the widths of the columns beside it.</li><li>To cancel a resize, drag the handle back to where it started, or touch the screen with a second finger.</li><li>To give a column and the next one the same width, double-tap the handle between them.</li><li>To select a column, tap its segment. To open the column menu, touch and hold the segment.</li><li>To scroll a wide table sideways, swipe along the bar.</li></ul><p>A wide table scrolls a little past its end, so the handle of its last column stays away from the edge of the screen, where a swipe navigates back.</p><h2>Wide tables</h2><p>Since v0.107.0, a table can be wider than the <a class=\"reference-link\" href=\"#root/_help_t596jLvPrqkS\">Content width</a>. Such a table scrolls sideways, while the rest of the note keeps its width.</p><ul><li>A new table is as wide as the content. To make it wider, drag the right border of its last column past the edge of the content. The border snaps to the edge and holds there briefly, so the table is easy to bring back to the width of the content.</li><li>To set an exact width, enter a percentage above <code>100%</code> or a width in pixels in the <span class=\"tn-icon cke cke-table-properties\"></span> <a href=\"#table-properties\">table properties</a>.</li><li>A table whose content needs more room than the note, such as a pasted table with many columns, also scrolls instead of stretching the note.</li><li>Wide tables scroll the same way in read-only notes and on shared pages.</li><li>When printing or exporting to PDF, a wide table is shrunk to fit the page.</li></ul><p>Tables inside other blocks, such as block quotes, admonitions, collapsible blocks, columns or tabs, are limited to the width of their block and do not scroll.</p><h3>Mobile support</h3><p>On the <a class=\"reference-link\" href=\"#root/_help_RDslemsQ6gCp\">Mobile Frontend</a>, a table keeps the width it has on a desktop and scrolls sideways, instead of squeezing its columns into the width of the screen. The full width of a table is the <em>Max content width</em> set in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Appearance</em> → <em>Content Width</em> on the mobile device, 1200 pixels by default. For example, a table set to <code>50%</code> is 600 pixels wide.</p><p>To resize columns on mobile, use the bar described in <a href=\"#resizing-with-touch\">Resizing with touch</a>.</p><h2>Long tables</h2><p>Since v0.107.0, the header rows of a table stay visible at the top of the note while you scroll through the rest of the table, and leave with the end of the table. This also works in read-only notes, on shared pages and in wide tables.</p><p>To turn rows into header rows, use <em>Set as header</em> in the <a href=\"#context-menu\">context menu</a>, or <em>Header row</em> in the <span class=\"tn-icon cke cke-table-row\"></span> button of the formatting toolbar.</p><p>To let header rows scroll away with the rest of the table, turn off <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Text Notes</em> → <em>Features</em> → <em>Use sticky header rows for tables</em>. The setting applies to the current device only, and shared pages keep their sticky header rows.</p><h2>Inserting new rows and new columns</h2><ul><li>To insert a new column, click on a desired location, then press the <span class=\"tn-icon cke cke-table-column\"></span> button from the formatting toolbar and select <em>Insert column left or right.</em></li><li>To insert a new row, click on a desired location, then press the <span class=\"tn-icon cke cke-table-row\"></span> button and select <em>Insert row above</em> or <em>below</em>.<ul><li>A quicker alternative to creating a new row while at the end of the table is to press the <kbd>Tab</kbd> key.</li></ul></li><li>Both operations are also available in the <a href=\"#context-menu\">context menu</a>, which inserts as many rows or columns as the selection spans.</li></ul><h2>Moving rows and columns</h2><p>Since v0.106.0, rows and columns can be reordered with the keyboard:</p><ul><li><kbd>Alt</kbd>+<kbd>Up</kbd> and <kbd>Alt</kbd>+<kbd>Down</kbd> move the rows touched by the selection up or down.</li><li><kbd>Alt</kbd>+<kbd>Left</kbd> and <kbd>Alt</kbd>+<kbd>Right</kbd> move the columns touched by the selection left or right.</li></ul><p>Merged cells are never split by a move. The rows or columns held together by a merged cell travel as one block, and moving toward such a block jumps over it entirely.</p><p>When the table has a header row, a header row moved below the header area becomes a regular row, and a regular row moved into the header area becomes a header row. Header columns behave the same way.</p><p>Outside of tables, <kbd>Alt</kbd>+<kbd>Left</kbd> and <kbd>Alt</kbd>+<kbd>Right</kbd> keep navigating the note history, and <kbd>Alt</kbd>+<kbd>Up</kbd> and <kbd>Alt</kbd>+<kbd>Down</kbd> keep moving the current paragraph.</p><h2>Sorting rows</h2><p>Since v0.107.0, the rows of a table can be sorted by the values of one column:</p><ul><li>To sort all the rows, place the cursor in any cell of the column to sort by, then select <em>Sort</em> → <em>Ascending</em> or <em>Descending</em> from the <a href=\"#context-menu\">context menu</a>. The same items are in the <span class=\"tn-icon bx bx-sort-alt-2\"></span> button of the formatting toolbar.</li><li>To sort only some of the rows, select their cells in the column to sort by, then sort the same way. Sorting is not available while the selection spans more than one column.</li></ul><p>Header rows always stay at the top of the table and are never sorted. A sort can be undone with <kbd>Ctrl</kbd>+<kbd>Z</kbd>.</p><h3>How values are compared</h3><p>Each cell is read as plain text, so formatting does not affect the order. Trilium then detects what kind of value the cell holds:</p><figure class=\"table\"><table><thead><tr><th>Kind</th><th>Examples</th><th>Compared by</th></tr></thead><tbody><tr><td>Time</td><td><code>15:02</code>, <code>15:02:38</code>, <code>3:02 PM</code></td><td>The time of day.</td></tr><tr><td>Date</td><td><code>2026-09-30</code>, <code>2026-09-30 15:02</code>, <code>30 September 2026</code>, <code>Wednesday, 30 September 2026</code>, <code>2026-09-30T15:02:38+03:00</code></td><td>The date and time.</td></tr><tr><td>Number</td><td><code>12</code>, <code>-3.5</code>, <code>1,234.56</code>, <code>$ 12.04</code>, <code>21 RON</code>, <code>24.5m</code></td><td>The numeric value.</td></tr><tr><td>Text</td><td>Anything else.</td><td>Alphabetically, ignoring case, with numbers inside the text in numeric order (<code>Item 9</code> before <code>Item 10</code>). Accents count, so <code>a</code> and <code>á</code> differ.</td></tr><tr><td>Empty</td><td>An empty cell, or one holding only spaces.</td><td>Not compared. Empty cells always go last.</td></tr></tbody></table></figure><p>Ascending order puts times first, then dates, numbers and text. Descending order reverses it. Empty cells go last in both directions.</p><p>Numbers, dates and times with the same value are ordered by their text, so <code>5 apples</code> comes before <code>5 pears</code>. Rows whose cells hold the same text, ignoring case, keep their relative order.</p><ul><li>Dates are also recognized in the formats of the note's language, such as <code>30.09.2026</code> or <code>30. September 2026</code> for German, and in the format chosen in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Text Notes</em> → <em>Editor</em> → <em>Date/time format</em> for <a href=\"#root/_help_CohkqWQC1iBv\">inserting the date and time</a>.</li><li>A number can start with a currency symbol, such as <code>$</code>, <code>€</code> or <code>£</code>. Whatever follows the number, such as a unit, is ignored, so units are not converted: <code>1 km</code> sorts before <code>500 m</code>. A cell that starts with letters, such as <code>RON 21</code>, is text.</li><li>The decimal separator follows the language of the note: <code>1.500</code> is one and a half in English, but one thousand five hundred in German. A comma or period that is not followed by exactly three digits is always read as a decimal separator, so <code>1,5</code> is one and a half in either language.</li><li>The language of the note set in the <a class=\"reference-link\" href=\"#root/_help_AlJ73vBCjWDw\">Status bar</a> via the <span class=\"tn-icon bx bx-globe\"></span> icon, or else the default content language. See <a class=\"reference-link\" href=\"#root/_help_veGu4faJErEM\">Content language & Right-to-left support</a>.</li></ul><h3>Merged cells</h3><p>Rows joined by a merged cell are kept together and move as one block. The block is sorted by the value in its first row. When the block has more than one cell in the sorted column, the other cells do not affect the order, and a message says so: <em>Some rows were sorted together because merged cells tie them to each other</em>.</p><p>When the selection covers only part of such a block, the whole block is sorted.</p><h2>Merging cells</h2><p>To merge two or more cells together, simply select them via drag & drop and press the <span class=\"tn-icon cke cke-table-merge-cell\"></span> button from the formatting toolbar.</p><p>More options are available by pressing the arrow next to it:</p><ul><li>Click on a single cell and select Merge cell up/down/right/left to merge with an adjacent cell.</li><li>Select <em>Merge selected cells</em> to merge the selected cells, the same as pressing the button itself.</li><li>Select <em>Split cell vertically</em> or <em>horizontally</em>, to split a cell into multiple cells (can also be used to undo a merge).</li><li>Select <em>Unmerge cells</em> to turn each merged cell in the selection back into the single cells it covers, keeping its content in the top-left one.</li></ul><p><em>Merge selected cells</em> and <em>Unmerge cells</em> are available since v0.107.0. Merging and splitting are also available by right-clicking the selected cells, via the <a href=\"#context-menu\">context menu</a>, where <em>Unmerge cells</em> is in the <em>Split cell</em> submenu.</p><h2>Table properties</h2><figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:312/311;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/Tables_image.png\" width=\"312\" height=\"311\"></figure><p>The table properties can be accessed via the <span class=\"tn-icon cke cke-table-properties\"></span> button and allows for the following adjustments:</p><ul><li>Border (not the border of the cells, but the outer rim of the table), which includes the style (single, double), color and width.</li><li>The background color, with none set by default.</li><li>The width and height of the table in percentage (must end with <code>%</code>) or pixels (must end with <code>px</code>).</li><li>The alignment of the table.<ul><li>Left or right-aligned, case in which the text will flow next to it.</li><li>Centered, case in which text will avoid the table, regardless of the table width.</li></ul></li></ul><p>The table will immediately update to reflect the changes, but the <em>Save</em> button must be pressed for the changes to persist.</p><h2>Cell properties</h2><figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:320/386;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/1_Tables_image.png\" width=\"320\" height=\"386\"></figure><p>Similarly to table properties, the <span class=\"tn-icon cke cke-table-cell-properties\"></span> button opens a popup which adjusts the styling of one or more cells (based on the user's selection).</p><p>The following options can be adjusted:</p><ul><li>The border style, color and width (same as table properties), but applying to the current cell only.</li><li>The background color, with none set by default.</li><li>The width and height of the cell in percentage (must end with <code>%</code>) or pixels (must end with <code>px</code>).</li><li>The padding (the distance of the text compared to the cell's borders).</li><li>The alignment of the text, both horizontally (left, centered, right, justified) and vertically (top, middle or bottom).<ul><li>In a centered or right-aligned cell, each item of a bulleted, numbered or to-do list moves together with its bullet, number or checkbox.</li></ul></li></ul><p>The cell will immediately update to reflect the changes, but the <em>Save</em> button must be pressed for the changes to persist.</p><h2>Border and background colors</h2><p>The border and background colors of tables and cells adapt to the <a href=\"#root/_help_Wy267RK4M69c\">theme</a>, the same way as <a href=\"#root/_help_Gr6xFaF6ioJ5\">text colors</a> do. A color picked from the palette, chosen with the color picker or typed in is shown in a lighter or darker shade that suits the current theme, so borders stay visible and text stays readable on the background. The hue stays the same, and the table keeps the color as it was picked.</p><p>Colors applied with older versions of Trilium are shown exactly as they were picked, until the note is next edited.</p><p>Older browsers that can't adapt colors show them exactly as they were picked.</p><h2>Caption</h2><p>Press the <span class=\"tn-icon cke cke-caption\"></span> button to insert a caption or a text description of the table, which is going to be displayed above the table.</p><h2>Table borders</h2><p>By default, tables come with a gray border that is lighter or darker to suit the current <a href=\"#root/_help_Wy267RK4M69c\">theme</a>, so it stays discreet on a dark background.</p><p>To change the default border of every table, set the <code>--text-note-table-border-color</code> variable in a <a href=\"#root/_help_7NfNr5pZpVKV\">custom theme</a> or in <a href=\"#root/_help_AlhDUqhENtH7\">custom app-wide CSS</a>, for example <code>:root { --text-note-table-border-color: #555; }</code>. Set it to <code>transparent</code> to hide the borders of all the tables that don't have a border of their own.</p><p>To adjust the borders, follow these steps:</p><ol><li>Select the table.</li><li>In the floating panel, select the <em>Table properties</em> option (<span class=\"tn-icon cke cke-table-properties\"></span>).<ol><li>Look for the <em>Border</em> section at the top of the newly opened panel.</li><li>This will control the outer borders of the table.</li><li>Select a style for the border. Generally <em>Single</em> is the desirable option.</li><li>Select a color for the border.</li><li>Select a width for the border, expressed in pixels.</li></ol></li><li>Select all the cells of the table and then press the <em>Cell properties</em> option (<span class=\"tn-icon cke cke-table-cell-properties\"></span>).<ol><li>This will control the inner borders of the table, at cell level.</li><li>Note that it's possible to change the borders individually by selecting one or more cells, case in which it will only change the borders that intersect these cells.</li><li>Repeat the same steps as from step (2).</li></ol></li></ol><h3>Tables with invisible borders</h3><p>Tables can be set to have invisible borders in order to allow for basic layouts (columns, grids) of text or <a href=\"#root/_help_mT0HEkOsz6i1\">images</a> without the distraction of their border:</p><ol><li>First insert a table with the desired number of columns and rows.</li><li>Select the entire table.</li><li>In <em>Table properties</em>, set:<ol><li><em>Style</em> to <em>Single</em></li><li><em>Color</em> to <code>transparent</code></li><li>Width to <code>1px</code>.</li></ol></li><li>In Cell Properties, set the same as on the previous step.</li></ol><h2>Table indentation</h2><p>Since v0.104.1, tables can be indented as a block (the whole table moves, rather than just the content of a cell).</p><ol><li>Click the <span style=\"--tn-color:hsl(0,0%,60%);color:hsl(0,0%,60%);\"><span class=\"tn-icon cke cke-drag-handle\"></span></span> button to select the entire table. Otherwise, the indentation applies only to the current cell's content.</li><li>Press <kbd>Tab</kbd> to increase the indent, or <kbd>Shift</kbd>+<kbd>Tab</kbd> to decrease it. Alternatively, use the indentation buttons in the formatting toolbar.</li></ol><p>Markdown does not support indented tables, so the indentation is lost when converting to Markdown.</p><h2>Markdown import/export</h2><p>Simple tables are exported in GitHub-flavored Markdown format (e.g. a series of <code>|</code> items). If the table is found to be more complex (it contains HTML elements, has custom sizes or images), the table is converted to a HTML one instead.</p><p>Generally formatting loss should be minimal when exported to Markdown due to the fallback to HTML formatting.</p>","_help_pwc194wlRzcH": "<figure class=\"image image-style-align-right\"><img style=\"aspect-ratio:265/108;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/Text%20Snippets_image.png\" width=\"265\" height=\"108\"></figure><p>Text Snippets are closely related to <a class=\"reference-link\" href=\"#root/_help_KC1HB96bqqHX\">Templates</a>, but instead of defining the content of an entire note, text snippets are pieces of formatted text that can easily be inserted in a text note.</p><h2>Creating a text snippet</h2><p>In the <a class=\"reference-link\" href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a>: </p><ol><li>Right click a note where to place the text snippet.</li><li>Select <em>Insert child note</em>.</li><li>Select <em>More</em> → <em>Text snippet</em>.</li></ol><p>Afterwards, simply type in the content of the note the desired text. The text can be formatted in the same manner as a normal text note.</p><p>The title of the note will become the title of the template. Optionally, a description can be added in the <a class=\"reference-link\" href=\"#root/_help_OFXdgB2nNk1F\">Promoted Attributes</a> section.</p><h2>Inserting a snippet</h2><p>Once a snippet is created, there are two options to insert it:</p><ol><li>From the <a class=\"reference-link\" href=\"#root/_help_nRhnJkTT8cPs\">Formatting toolbar</a>, by looking for the <span class=\"tn-icon cke cke-trilium-template\"></span> button.</li><li>Using <a class=\"reference-link\" href=\"#root/_help_ZlN4nump6EbW\">Slash Commands</a>: <ol><li>To look for a specific template, start typing the name of the template (its title).</li><li>To look for all the templates, type <code>template</code>.</li></ol></li></ol><aside class=\"admonition tip\"><p>A newly created snippet doesn't appear? Generally it takes up to a few seconds to refresh the list of templates once you make a change.</p><p>If this doesn't happen, <a href=\"#root/_help_s8alTXmpFR61\">reload the application</a> and <a href=\"#root/_help_wy8So3yZZlH9\">report the issue</a>to us. </p></aside><h2>Limitations</h2><ul><li>Whenever a snippet is created, deleted or its title/description are modified, all the open text notes will need to be refreshed. This causes a slight flash for usually under a second, but it can cause some discomfort.</li><li>Unlike <a class=\"reference-link\" href=\"#root/_help_KC1HB96bqqHX\">Templates</a>, the snippets cannot be limited to a particular <a href=\"#root/_help_9sRHySam5fXb\">workspace</a>.</li></ul>","_help_fASfBrYnquKU": "<h2>Extended task states</h2><figure class=\"image image-style-align-left\"><img style=\"aspect-ratio:303/264;\" src=\"{{helpAssets}}/User%20Guide/Note%20Types/Text/To-do%20Lists_image.png\" width=\"303\" height=\"264\"></figure><p>In Trilium, to-do items aren't limited to a simple \"done\" or \"not done.\" Tasks can also be marked as <em>in progress</em> (\"doing\"), <em>under consideration</em> (\"maybe\"), or <em>cancelled</em> (\"won't do\"), thus giving a more accurate picture of where things actually stand.</p><p>Right-click the checkbox and select the desired state. Alternatively, press <kbd>Ctrl</kbd>+<kbd>Shift</kbd>+<kbd>Enter </kbd> to cycle through the task states. Tapping or left-clicking the checkbox will always toggle between \"None\" and \"Done\". On the <a class=\"reference-link\" href=\"#root/_help_RDslemsQ6gCp\">Mobile Frontend</a>, the states are buttons in the row of the <em>List ›</em> button, which shows while the cursor is in the list.</p><p>Task states are fully preserved when converting between <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> and <a class=\"reference-link\" href=\"#root/_help_6RM1Q7ppFVoj\">Markdown</a> notes, in both directions.</p><h3>Customizing the extended task states</h3><p>Task states are customizable: you can reorder them, create new ones with different colors and symbols, or delete the ones you don't need. See <a class=\"reference-link\" href=\"#root/_help_i16PM6A7GXdU\">Customizing to-do task states</a> for more details.</p><h2>Keyboard shortcuts</h2><p>When at the beginning on an empty paragraph, type the following to insert a to-do list:</p><ul><li><code>[ ]</code> for an unchecked item</li><li><code>[x]</code> for a checked item</li></ul><p>Extended task states are supported as well, using its corresponding <em>Markdown symbol</em>. These are the defaults but they can be changed if needed (see <a class=\"reference-link\" href=\"#root/_help_i16PM6A7GXdU\">Customizing to-do task states</a>):</p><ul><li><code>[/]</code> for “Doing”.</li><li><code>[?]</code> for “Maybe”.</li><li><code>[-]</code> for “Cancelled”.</li></ul><p>To reorder the item under the cursor, press <kbd>Alt</kbd>+<kbd>Up</kbd> or <kbd>Alt</kbd>+<kbd>Down</kbd>. To reorder multiple items, select them first.</p><h2>See also</h2><ul><li>To-do lists are meant for small task lists. For more complicated, day-to-day task tracking consider using a <a class=\"reference-link\" href=\"#root/_help_CtBQqbwXDx1w\">Kanban Board</a> collection instead.</li></ul>","_help_6f9hih2hXXZk": "<p>Trilium supports creating \"code\" notes, i.e. notes which contain some sort of formal code - be it programming language (C++, JavaScript), structured data (JSON, XML) or other types of codes (CSS etc.).</p><p>This can be useful for a few things:</p><ul><li>computer programmers can store code snippets as notes with syntax highlighting</li><li>JavaScript code notes can be executed inside Trilium for some extra functionality<ul><li>we call such JavaScript code notes \"scripts\" – see <a class=\"reference-link\" href=\"#root/_help_CdNpE2pqjmI6\">Scripting</a></li></ul></li><li>JSON, XML etc. can be used as storage for structured data (typically used in conjunction with scripting)</li></ul><p>For shorter snippets of code that can be embedded in <a href=\"#root/_help_iPIMuisry3hd\">Text</a> notes, see <a href=\"#root/_help_QxEyIjRBizuC\">Code blocks</a>.</p><p><img src=\"{{helpAssets}}/User%20Guide/Note%20Types/Code_image.jpg\"></p><h2>Creating a code note</h2><p>In the <a href=\"#root/_help_oPVyFC7WL2Lp\">Note Tree</a>, right-click a note and select <em>Insert child note</em> or <em>Insert note after</em>, then:</p><ul><li>To create a plain text code note, select <em>Code</em>.</li><li>To create a code note in a given language, hover <em>Code</em> and select the language. The list shows the languages enabled in the options (see below), and ends with <em>Configure code notes...</em>, which opens them.</li></ul><h2>Adjusting the language of a code note</h2><p>To change the language of a code note, look for the <span class=\"tn-icon bx bx-code\"></span> icon in the <a class=\"reference-link\" href=\"#root/_help_AlJ73vBCjWDw\">Status bar</a>. When clicked it will reveal the list of available languages (which can be customized according to the section below). The menu also features a search bar to quickly filter, and icons to visually distinguish some of the programming languages.</p><p>On the <a class=\"reference-link\" href=\"#root/_help_RDslemsQ6gCp\">Mobile Frontend</a>, the same list is available in the <a class=\"reference-link\" href=\"#root/_help_8YBEPzcpUgxw\">Note menu</a> → <em>Note settings</em> → <em>Change language mode</em>.</p><h2>Adjusting the list of languages</h2><p>Trilium supports syntax highlighting for many languages, but by default displays only some of them. To change which languages are offered, go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Code Notes</em> and find <em>Available MIME types in the dropdown</em>. Here you can:</p><ul><li>Add a language by pressing the <span class=\"tn-icon bx bx-plus\"></span> <em>Add another language</em> button, which also shows how many languages are left, and then selecting it. While picking, hover a language to see where it is syntax highlighted.</li><li>Press the <span class=\"tn-icon bx bx-x\"></span> button beside a language, or select it and press <kbd>Delete</kbd>, to remove it from the list. <em>Plain text</em> cannot be removed.</li><li>See where each language is syntax highlighted: the <em>Code blocks</em> badge stands for code blocks in text notes, the <em>Code notes</em> badge for code notes.</li></ul><p>The languages are listed in the same order wherever you choose one: the language menu in the <a class=\"reference-link\" href=\"#root/_help_AlJ73vBCjWDw\">Status bar</a>, the <em>Code</em> submenu when creating a note, and the language of a code block. By default, the list is sorted alphabetically, with <em>Plain text</em> first. To use an order of your own:</p><ol><li>Turn off the <em>Sort alphabetically</em> switch at the top of the section.</li><li>Hold the <strong>=</strong> handle shown beside a language, and then drag it up or down. Alternatively, select a language and press <kbd>Ctrl</kbd>+<kbd>↑</kbd> or <kbd>Ctrl</kbd>+<kbd>↓</kbd>.</li></ol><p>Turning <em>Sort alphabetically</em> back on does not discard your order: it is used again the next time the switch is turned off.</p><p>Note that the list of languages is not immediately refreshed, you'd have to manually <a href=\"#root/_help_s8alTXmpFR61\">refresh the application</a>.</p><p>The list of languages is also shared with the <a href=\"#root/_help_QxEyIjRBizuC\">Code blocks</a> feature of <a href=\"#root/_help_iPIMuisry3hd\">Text</a> notes.</p><h2>Word wrap</h2><p>Long lines can be displayed on multiple lines:</p><ul><li>Globally for all code notes, from <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Code Notes.</em></li><li>For a particular note, by going to the menu in <a class=\"reference-link\" href=\"#root/_help_8YBEPzcpUgxw\">Note menu</a> and selecting <em>Word wrap</em> and selecting the appropriate option:<ul><li><em>Auto</em>, to respect the global word wrap for code notes.</li><li><em>On</em> or <em>Off</em>, to change the state of the word wrap for this note regardless of the global option.</li></ul></li></ul><aside class=\"admonition note\"><p>Word wrapping can also be adjusted at note level through the <code>#wrapLines</code> <a href=\"#root/_help_HI6GBBIduIgv\">label</a>, which can also be inherited.</p></aside><h2>Line numbers</h2><p>The numbers at the start of each line can be hidden from <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Code Notes</em> → <em>Editor</em> → <em>Line numbers</em>. The setting applies to every code editor, such as the source of a <a href=\"#root/_help_6RM1Q7ppFVoj\">Markdown</a> note, and to code shown without its editor (see <em>Color schemes</em> below).</p><p>An included code note or an embedded code file can show or hide them on its own through the <em>Line numbers</em> submenu of its <em>More actions</em> menu, see <a class=\"reference-link\" href=\"#root/_help_nBAXQFj20hS1\">Include Note</a>. Its <em>Auto</em> entry follows the setting.</p><h2>Adjusting options using the status bar</h2><p>The status bar at the bottom of the editor shows the position of the cursor, the current indentation settings and language.</p><p>The cursor position is shown as <em>Ln</em> (the line) and <em>Col</em> (the column), both counted from 1. A tab counts as many columns as the display width of tabs, so the column matches where the cursor appears on screen. While text is selected, <em>Selected</em> shows the number of selected characters, counting each line break as one.</p><p>Clicking on the indentation indicator opens a menu with three sections:</p><ol><li><em>Indent Using</em> — switch between Spaces and Tabs (<code>#indentWithTabs</code>). If a per-note override is active, a \"Reset to default\" option appears.</li><li><em>Display Width</em> — choose from preset widths (1, 2, 3, 4, 6, 8). Changes are saved as a per-note <code>#tabWidth</code> label.</li><li><em>Re-indent Content To</em> — convert existing indentation to a different style. For example, re-indent a file from 4 spaces to 2 spaces, or from spaces to tabs. This rewrites the leading whitespace on every line while preserving alignment remainders.</li></ol><p>Clicking the language indicator lets you change the note's MIME type. As in the <em>Note type</em> selector, typing narrows the list of languages.</p><p>The same two menus are in the toolbar of a code note or a code file included in a text note, see <a class=\"reference-link\" href=\"#root/_help_nBAXQFj20hS1\">Include Note</a>.</p><h3>Re-indentation</h3><p>When you re-indent content, the editor:</p><ul><li>Measures the visual column width of each line's leading whitespace using the current style</li><li>Calculates indent levels and any alignment remainder</li><li>Rebuilds the leading whitespace in the target style</li><li>Preserves non-leading whitespace, blank lines, and content without indentation</li></ul><h2>Transforming text</h2><p>To change the selected lines or text, right-click the selection and open <em>Transform</em>. Its commands come in three groups:</p><ul><li><em>Sort ascending</em>, <em>Sort descending</em>, <em>Shuffle lines</em>, <em>Reverse line order</em> and <em>Deduplicate lines</em>, which keeps the first copy of each line.</li><li><em>Trim leading</em>, <em>Trim trailing</em> and <em>Trim both</em> remove the whitespace at the start, at the end or at both ends of each line. <em>Remove blank lines</em> also removes the lines that hold only whitespace.</li><li><em>To uppercase</em>, <em>To lowercase</em>, <em>To sentence case</em>, <em>To title case</em> and <em>Remove diacritics</em>.</li></ul><p>The commands of the first two groups change every line that the selection touches, even partly. Those of the third group change only the selected text. Each change is undone in one step with <kbd>Ctrl</kbd>+<kbd>Z</kbd>.</p><ul><li>Sorting reads numbers, dates and times by their value, as sorting a table does (see <a class=\"reference-link\" href=\"#root/_help_NdowYOC1GFKS\">Tables</a>), and ignores the case of letters and the indentation. Blank lines go last.</li><li><em>To sentence case</em> lowercases the text and capitalizes the first word of each sentence and of each line. <em>To title case</em> capitalizes every word except minor words such as \"of\" and \"the\", which stay lowercase unless they start or end a sentence.</li><li><em>Remove diacritics</em> turns letters such as <code>é</code>, <code>ș</code> and <code>ł</code> into <code>e</code>, <code>s</code> and <code>l</code>, and removes the vowel points of Hebrew and Arabic. Letters such as <code>ß</code> and <code>æ</code> stay as they are.</li><li>Sorting and the case changes follow the language set in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>Language & Region</em> → <em>Default content language</em>. In Turkish, for example, an uppercase <code>i</code> is <code>İ</code>.</li></ul><h2>Color schemes</h2><p>Since Trilium 0.94.0 the colors of code notes can be customized by going <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → Code Notes and looking for the <em>Appearance</em> section.</p><p>A code note or a code file shown without its editor, such as in an <a class=\"reference-link\" href=\"#root/_help_nBAXQFj20hS1\">Include Note</a>, on the cards of <a class=\"reference-link\" href=\"#root/_help_GTwFsgaA0lCt\">Collections</a> or in a tooltip, uses the same colors and line numbers as the editor does. A printout uses the <em>Light theme</em>. A <a href=\"#root/_help_R9pX4DGra2Vt\">shared page</a> uses the VS Code light or dark theme, following the mode of the page.</p><aside class=\"admonition note\"><p><strong>Why are there only a few themes whereas the code block themes for text notes have a lot?</strong><br>The reason is that Code notes use a different technology than the one used in Text notes, and as such there is a more limited selection of themes. If you find a CodeMirror 6 (not 5) theme that you would like to use, let us know and we might consider adding it to the set of default themes. There is no possibility of adding new themes (at least for now), since the themes are defined in JavaScript and not at CSS level.</p></aside><h2>Programming ligatures</h2><p>If you see <code>!=</code> displayed as <code>≠</code> or <code>-></code> as <code>→</code> inside a code note, those are <em>font ligature</em>: the default monospace font draws certain character pairs as a single symbol. The underlying text is not changed by Trilium (unlike text notes which have <a class=\"reference-link\" href=\"#root/_help_oI7GoyilXXAr\">Automatic replacements</a>), and copying it out gives you back <code>!=</code> and <code>-></code>.</p><p>This can be turned off with <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a><em>→ Appearance → Fonts → Programming ligatures</em>.</p><h2>Virtual keyboard behavior</h2><p>When using a virtual keyboard, keyboard suggestions and corrections are controlled as follows:</p><ul><li>For <a class=\"reference-link\" href=\"#root/_help_6RM1Q7ppFVoj\">Markdown</a> and plain text code notes, the autocorrect is <strong>on</strong>, as well as automatic capitalization.</li><li>For all the other code notes, the autocorrect is off in order to avoid issues when typing code.</li></ul><aside class=\"admonition note\"><p>Not all browsers and platforms respect this value, so the keyboard suggestions might appear without autocorrecting or the browser might disregard this and autocorrect anyway.</p></aside>",@@ -243,7 +243,7 @@"_help_HAIOFBoYIIdO": "<p>Nightly releases are versions built every day, containing the latest improvements and bugfixes, directly from the main development branch. These versions are generally useful in preparation for a release, to ensure that there are no significant bugs that need to be addressed first, or they can be used to confirm whether a particular bug is fixed or feature is well implemented.</p><h2>Regarding the stability</h2><p>Despite being on a development branch, generally the main branch is pretty stable since PRs are tested before they are merged. If you notice any issues, feel free to report them either via a ticket or via the Matrix.</p><h2>Downloading the nightly release manually</h2><p>Go to <a href=\"https://github.com/TriliumNext/Trilium/releases/tag/nightly\">github.com/TriliumNext/Trilium/releases/tag/nightly</a> and look for the artifacts starting with <code>TriliumNotes-main</code>. Choose the appropriate one for your platform (e.g. <code>windows-x64.zip</code>).</p><p>Depending on your use case, you can either test the portable version or even use the installer.</p><aside class=\"admonition note\"><p>If you choose the installable version (e.g. the .exe on Windows), it will replace your stable installation.</p></aside><aside class=\"admonition important\"><p>By default, the nightly uses the same database as the production version. Generally you could easily downgrade if needed. However, if there are changes to the database or sync version, it will not be possible to downgrade without having to restore from a backup.</p></aside><h2>Automatically download and install the latest nightly</h2><p>This is pretty useful if you are a beta tester that wants to periodically update their version:</p><div class=\"trilium-tabs\"><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bxl-tux\"></span> Ubuntu (Bash)</p><div class=\"trilium-tab-panel\"><pre><code class=\"language-text-x-sh\">#!/usr/bin/env bash\n\nname=TriliumNotes-linux-x64-nightly.deb\nrm -f $name*\nwget https://github.com/TriliumNext/Trilium/releases/download/nightly/$name\nsudo apt-get install ./$name\nrm $name</code></pre></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bxl-windows\"></span> Windows (PowerShell)</p><div class=\"trilium-tab-panel\"><pre><code class=\"language-application-x-powershell\">if ($env:PROCESSOR_ARCHITECTURE -eq \"ARM64\") {\n $arch = \"arm64\";\n} else {\n $arch = \"x64\";\n}\n\n$exeUrl = \"https://github.com/TriliumNext/Trilium/releases/download/nightly/TriliumNotes-main-windows-$($arch).exe\";\nWrite-Host \"Downloading $($exeUrl)\"\n\n# Generate a unique path in the temp dir\n$guid = [guid]::NewGuid().ToString()\n$destination = Join-Path -Path $env:TEMP -ChildPath \"$guid.exe\"\n\ntry {\n $ProgressPreference = 'SilentlyContinue'\n Invoke-WebRequest -Uri $exeUrl -OutFile $destination\n $process = Start-Process -FilePath $destination\n} catch {\n Write-Error \"An error occurred: $_\"\n} finally {\n # Clean up\n if (Test-Path $destination) {\n Remove-Item -Path $destination -Force\n }\n}</code></pre></div></section></div>","_help_ZmT9ln8XJX2o": "<aside class=\"admonition warning\"><p>This functionality is still in preview, expect possible issues or even the feature disappearing completely.<br>Feel free to <a href=\"#root/_help_wy8So3yZZlH9\">report</a> any issues you might have.</p></aside><p>The read-only database is an alternative to <a class=\"reference-link\" href=\"#root/_help_R9pX4DGra2Vt\">Sharing</a> notes. Although the share functionality works pretty well to publish pages to the Internet in a wiki, blog-like format it does not offer the full functionality behind Trilium (such as the advanced <a class=\"reference-link\" href=\"#root/_help_eIg8jdvaoNNd\">Search</a> or the interactivity behind <a class=\"reference-link\" href=\"#root/_help_GTwFsgaA0lCt\">Collections</a> or the various <a class=\"reference-link\" href=\"#root/_help_KSZ04uQ2D1St\">Note Types</a>).</p><p>When the database is in read-only mode, the Trilium application can be used as normal, but editing is disabled and changes are made in-memory only.</p><h2>What it does</h2><ul><li>All notes are read-only, without the possibility of editing them.</li><li>Features that would normally alter the database such as the list of recent notes are disabled.</li></ul><h2>Limitations</h2><ul><li>Some features might “slip through” and still end up creating a note, for example.<ul><li>However, the database is still read-only, so all modifications will be reset if the server is restarted.</li><li>Whenever this occurs, <code>ERROR: read-only DB ignored</code> will be shown in the logs.</li></ul></li></ul><h2>Setting a database as read-only</h2><p>First, make sure the database is initialized (e.g. the first set up is complete). Then modify the <a href=\"#root/_help_Gzjqa934BdH4\">config.ini</a> by looking for the <code>[General]</code> section and adding a new <code>readOnly</code> field:</p><pre><code class=\"language-text-x-trilium-auto\">[General]\nreadOnly=true</code></pre><p>If your server is already running, restart it to apply the changes.</p><p>Similarly, to disable read-only remove the line or set it to <code>false</code>.</p>","_help_TiQbQDgP8L5t": "<p>Optical Character Recognition is the process in which the text from images or PDFs is extracted.</p><h2>Built-in support</h2><p>Since v0.103.0, Trilium has built-in support for OCR. The extracted text can be:</p><ul><li>Integrated with <a class=\"reference-link\" href=\"#root/_help_eIg8jdvaoNNd\">Search</a>, to quickly find the image or file based on snippets of text.</li><li>Integrated with the <a class=\"reference-link\" href=\"#root/_help_GBBMSlVSOIGP\">AI</a> feature, which allows the agent to access the content of a non-text note.</li><li>Manually accessed for other purposes (e.g. copying into a note or sending it somewhere else).</li></ul><h2>Supported formats</h2><p>OCR in Trilium supports the following formats:</p><h3>Images</h3><ul><li>Both <a href=\"#root/_help_W8vYD3Q1zjCR\">individual image notes</a> and <a href=\"#root/_help_mT0HEkOsz6i1\">attachments in text files</a> are supported.</li><li>Supported formats:<ul><li>JPEG</li><li>PNG</li><li>GIF (only non-animated)</li><li>BMP</li><li>WebP</li></ul></li><li>Note that this feature works best for computer-rendered text rather than handwriting.</li><li>The underlying technology is Tesseract.js.</li></ul><h3>PDFs</h3><p>The PDF extraction supports:</p><ul><li>PDFs with text information (e.g. a PDF created by a browser or a word processing application), in which the text is extracted.</li><li>Scanned PDFs, and other PDFs whose text cannot be selected (such as documents whose text was converted to outlines), in which the text is extracted through an OCR process.</li><li>Mixed PDFs, containing both text and images with text content.</li></ul><p>Note that OCR extraction is limited to 50 pages per PDF, pages containing text information (not as an image) are not subject to this limitation.</p><aside class=\"admonition note\"><p>Text extraction for scanned PDFs using OCR was introduced in v0.106.0. If a scanned PDF was already processed by an earlier version, reprocess it individually via <em>Process OCR</em>; batch processing only handles files that haven't been OCR'd yet.</p></aside><h3>Office documents</h3><p>The text will be extracted from the following file formats:</p><ul><li>Microsoft Word documents</li><li>Microsoft Excel documents<ul><li>Only the raw text information, the cell structure is not maintained.</li><li>Values are extracted raw, so searching for dates will not work. The OpenDocument alternative will actually extract the properly formatted value.</li></ul></li><li>Microsoft PowerPoint documents</li><li>The OpenDocument alternatives to the previous formats (Text, Spreadsheet, Presentation), created by editors such as LibreOffice and OpenOffice.</li><li><a href=\"https://en.wikipedia.org/wiki/Rich_Text_Format\">Rich Text Format (RTF)</a>, since v0.104.0.</li><li><a href=\"https://en.wikipedia.org/wiki/EPUB\">EPUB</a>, since v0.104.1.</li></ul><h2>Configuring and triggering OCR</h2><p>The OCR can be configured by going to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <a class=\"reference-link\" href=\"#root/_hidden/_options/_optionsMedia\">Media</a> and looking for the <em>Text Extraction (OCR)</em> section.</p><p>There are three ways to trigger the OCR:</p><ul><li>By enabling <em>Auto-process new files</em> which will process only the notes or attachments created after enabling the option, existing files will remain unprocessed.</li><li>By pressing <em>Start Batch Processing</em> which will process all the existing notes.</li><li>By manually requesting for an image or file to have its text extracted, regardless of whether the automatic processing is enabled or not.</li></ul><h3>Minimum confidence</h3><p>When extracting text from an image, there is a certain level of confidence which indicates whether the extracted text appears relevant.</p><p>When the minimum confidence is set to a low percentage, the text extraction can interpret symbols and drawings incorrectly resulting in garbled text.</p><p>If the extracted text for a note or an attachment quality is lower than the minimum confidence, the OCR is disregarded.</p><h2>Language management</h2><p>OCR needs to be aware of the language of the content in order for it to work correctly. The reason is that each language has its own data which needs to be downloaded, and accents or other symbols will not be supported by the default language.</p><p>To configure the languages that are supported by the OCR, simply go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <a class=\"reference-link\" href=\"#root/_hidden/_options/_optionsLocalization\">Language & Region</a> and adjust the <em>Content languages</em>.</p><p>When there are no content languages defined, the user interface <em>Language</em> is used instead.</p><p>After making this change, the automatic processing or manual reprocessing will take into consideration the new languages.</p><p>To enforce the detection in a particular language for a given note, use the <code>language</code> <a href=\"#root/_help_zEY4DaJG4YT5\">attribute</a>, similar to <a href=\"#root/_help_veGu4faJErEM\">text content language</a>. For <a class=\"reference-link\" href=\"#root/_help_0vhv7lsOLy82\">Attachments</a>, it's not possible to manually adjust the language.</p><aside class=\"admonition note\"><p>The trained data for each language is not packaged with Trilium, as that would require a significant amount of space that might not be otherwise needed. As such, when the trained data will be downloaded automatically via <a href=\"https://github.com/naptha/tesseract.js/\">Tesseract.js</a>.</p><p>The downloaded trained data is located in the <a class=\"reference-link\" href=\"#root/_help_tAassRL4RSQL\">Data directory</a>, in the <code>ocr-cache</code> directory.</p></aside><h2>Viewing extracted content for a single note</h2><p>To access the extracted content of a note:</p><ul><li>For <a class=\"reference-link\" href=\"#root/_help_W8vYD3Q1zjCR\">File</a> notes, go to the <a class=\"reference-link\" href=\"#root/_help_8YBEPzcpUgxw\">Note menu</a> → <em>Advanced</em> → <em>View OCR Text</em>.</li><li>For <a class=\"reference-link\" href=\"#root/_help_0vhv7lsOLy82\">Attachments</a> (e.g. <a class=\"reference-link\" href=\"#root/_help_mT0HEkOsz6i1\">Images</a> in <a class=\"reference-link\" href=\"#root/_help_iPIMuisry3hd\">Text</a> notes), double-click the attachment to view the details, press the […] button at the left and select <em>View extracted text (OCR)</em>.</li></ul><p>This section allows:</p><ul><li>Viewing the extracted text, which can be copied elsewhere if needed or just to check the quality of the extraction.</li><li>If the note has not been extracted yet, pressing <em>Process OCR</em> will process it in the background. If the extraction confidence is lower than the minimum confidence, there will be a notification.</li><li>Similarly, if the minimum confidence was changed in settings, it is possible to press the <em>Process OCR</em> button again to extract the text again.</li></ul>",- "_help_GBBMSlVSOIGP": "<p>Trilium can connect to a large language model and use it as an assistant that works directly on your notes: ask questions about the note you're reading, have it draft or restructure content, or get it to write scripts and widgets for you.</p><p>The integration is off by default and does nothing until you enable it and configure a provider; Trilium ships no model of its own. The provider you pick decides how your notes travel: a cloud API billed per use, a subscription you already pay for, or a model running on your own hardware, in which case nothing leaves the machine. See <a class=\"reference-link\" href=\"#root/_help_bkPZAMT7d2sR\">Providers</a> for what each involves, and <a class=\"reference-link\" href=\"#root/_help_cRRrdZjgyhNc\">Privacy</a> for exactly what gets sent.</p><p>Once enabled, the assistant is available as:</p><ul><li>As a dedicated note type, it can read and modify notes through tools, which you can switch off per conversation if you would rather it only saw what you type.</li><li>A panel in the right sidebar, which acts similarly to the dedicated note type but it also has optional access to the current note.</li><li>An <a class=\"reference-link\" href=\"#root/_help_VRoP0g1uHHc2\">In-editor AI assistant</a> which comes with builtin actions that operate over selected text (such as proof-reading, summarizing), as well as <a class=\"reference-link\" href=\"#root/_help_mVEYwt20exhO\">Custom AI quick actions</a>.</li></ul><h2>Feature highlights</h2><ul><li>Chat-based interface with live streaming of the messages.</li><li>Provides the AI context with the note currently being looked at.</li><li>Tools to alter note content, create new notes, etc.</li><li>Statistics regarding context window use and pricing per message.</li><li>Attachments for multi-modal chat (images, text files, PDFs).</li><li>Optional MCP to allow external chat tools (e.g. Claude Code) to operate on notes within Trilium.</li></ul><h2>Sample use-cases</h2><ul><li>Create any type of <a class=\"reference-link\" href=\"#root/_help_MgibgPcfeuGz\">Custom Widgets</a>.</li><li>Easily create a <a class=\"reference-link\" href=\"#root/_help_HcABDtFCkbFN\">Render Note</a>, e.g. <em>Create for me a render note which allows me to play tic-tac-toe. Make sure to use Preact instead of the legacy jQuery.</em></li><li>Create widgets for a <a class=\"reference-link\" href=\"#root/_help_IF7Q6I9x7zuw\">Dashboard</a>, such as a calculator, a stopwatch, a pomodoro timer.</li></ul><aside class=\"admonition note\"><p>Claude Sonnet is known to produce very good frontend or backend scripts with little guidance, as the AI has been instructed in how to produce them.</p></aside><h2>LLM Providers</h2><p>Trilium supports four different types of providers:</p><div class=\"trilium-tabs\"><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-cloud\"></span> Cloud</p><div class=\"trilium-tab-panel\"><p>Pay-per use with an API key which is billed separately from any subscription you might already have.</p><ul><li><span class=\"tn-icon tn-brand tn-brand-anthropic\"></span> Anthropic Claude</li><li><span class=\"tn-icon tn-brand tn-brand-openai\"></span> OpenAI GPT</li><li><span class=\"tn-icon tn-brand tn-brand-gemini\"></span> Google Gemini</li><li><span class=\"tn-icon tn-brand tn-brand-deepseek\"></span> DeepSeek</li><li><span class=\"tn-icon tn-brand tn-brand-openrouter\"></span> OpenRouter, which reaches the models of most labs with one key</li></ul></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-coin\"></span> Subscription-based</p><div class=\"trilium-tab-panel\"><p>Reuses an existing subscription instead of paying per use.</p><ul><li><span class=\"tn-icon tn-brand tn-brand-claude\"></span> <a href=\"#root/_help_eFhxp9laTW1S\">Claude Code</a></li><li><span class=\"tn-icon tn-brand tn-brand-github-copilot\"></span> <a href=\"#root/_help_eFhxp9laTW1S\">GitHub Copilot</a></li><li><span class=\"tn-icon tn-brand tn-brand-antigravity\"></span> <a href=\"#root/_help_eFhxp9laTW1S\">Google Antigravity</a></li><li><span class=\"tn-icon tn-brand tn-brand-codex\"></span> <a href=\"#root/_help_eFhxp9laTW1S\">OpenAI Codex</a></li></ul></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-network-chart\"></span> Local/self-hosted</p><div class=\"trilium-tab-panel\"><ul><li><span class=\"tn-icon tn-brand tn-brand-ollama\"></span> Ollama</li><li><span class=\"tn-icon tn-brand tn-brand-lmstudio\"></span> LM Studio</li></ul></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-code-curly\"></span> Custom endpoints</p><div class=\"trilium-tab-panel\"><p>For other providers that are not directly supported by Trilium, either local or hosted (e.g. Groq, Mistral, Together).</p></div></section></div><aside class=\"admonition tip\"><p>For more information about each provider, see <a class=\"reference-link\" href=\"#root/_help_bkPZAMT7d2sR\">Providers</a>. See the dedicated <a class=\"reference-link\" href=\"#root/_help_cRRrdZjgyhNc\">Privacy</a> to better understand what data is sent to providers.</p></aside><h2>Enabling the AI integration</h2><p>To enable the AI integration, simply go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>AI / LLM</em> and press the toggle in the top-right of the dialog and configure a provider.</p><h2>Creating a new chat</h2><p>There are two different chat interfaces:</p><ul><li>One in the sidebar.</li><li>A dedicated note type.</li></ul><h3>The sidebar interface</h3><h3>The dedicated note type</h3><p>The dedicated chat note is similar to the sidebar interface, but it makes longer conversations more comfortable to read.</p><p>Unlike the sidebar, the AI will not be aware of the current note it's in.</p><h3>Templates</h3><p>Chat notes can be set as <a class=\"reference-link\" href=\"#root/_help_KC1HB96bqqHX\">Templates</a> to make them easily reusable. The entire conversation history is kept, allowing a basic form of specialization for the LLM with the existing chat acting like a system prompt. </p><h3>Model selection</h3><p>When a provider is configured in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a>, the next step is to select the models that will be available for the chat.</p><p>The models are retrieved dynamically from the provider, only when the model selection list is visible. To alter the list of models, simply press the Edit button in the model selection box.</p><p>Pricing information is displayed for known models. The pricing information (price per million tokens) is embedded in the application (using a subset of LiteLLM's data) and is updated with new versions of Trilium. Local providers are considered free, whereas custom endpoint providers don't offer any pricing information.</p><h2>Features</h2><h3>Web search</h3><p>The AI can optionally search the web to find more information about a specific topic. </p><p>Where the search comes from is chosen in the <em>Web search</em> submenu of the <span class=\"tn-icon bx bx-shield-quarter\"></span><em>Tools</em> menu next to the model selector at the bottom of the chat, whose row shows the source in use:</p><ul><li><em>Disabled</em> turns web search off for this chat.</li><li><em>Use the model's built-in search</em>, the default, lets the model search with its provider's own search. Anthropic, OpenAI, Google Gemini and DeepSeek models have one, as do Claude Code, Google Antigravity and OpenAI Codex. OpenRouter, Ollama, LM Studio and custom endpoints don't, so this choice is disabled for their models. DeepSeek's search is billed per search on your DeepSeek account and works only with DeepSeek's own endpoint, not with a custom base URL.</li><li>A search provider (Brave Search, Tavily, Exa, Serper, Perplexity or SearXNG) searches through that service instead, whichever model is answering. Search providers are added in the <em>Search Providers</em> section of the AI settings, which <em>Manage search providers</em> at the bottom of the submenu opens. The browser version can't use Brave Search, Exa or Perplexity, whose services refuse requests made from a web page, so they're shown disabled there.</li></ul><p>To use SearXNG, enable its JSON output by adding <code>json</code> to the search formats in the instance's <code>settings.yml</code>. SearXNG turns JSON off by default, and without it every search fails.</p><pre><code class=\"language-text-x-yaml\">search:\n formats:\n - html\n - json</code></pre><p>SearXNG doesn't use API keys, so leave the API key empty. Fill it in only if your instance sits behind a proxy that requires a token; Trilium sends it as a bearer token in the <code>Authorization</code> header.</p><p>Whether web search is on is kept per chat; the search source is shared by all chats. A choice the current model can't use stays in the menu, disabled; hover the <span class=\"tn-icon bx bx-info-circle\"></span>icon next to it to see why. Claude Code, GitHub Copilot, Google Antigravity and OpenAI Codex run their own tools, so they can't use a search provider.</p><p>In the chat, a search run through a search provider shows that provider's logo at the start of its line instead of the <span class=\"tn-icon bx bx-search\"></span>magnifier; hover the logo to see the provider's name.</p><p>With a search provider, the model can also read the pages it finds, or a link you give it, as text: Trilium fetches the page itself and hands the model up to its first 20,000 characters. Addresses on your own machine or network are refused. In the browser version most sites don't allow being read this way, so reading a page there usually fails.</p><h3>Thinking</h3><p>Some models reason before they answer. While the model is thinking, its reasoning is shown in full under a spinner; once it is done, it folds into a collapsible <em>Thought process</em> line above the reply.</p><p>How much a model thinks is set per chat, in one of two ways depending on the model:</p><ul><li>Most models have an <span class=\"tn-icon bx bx-brain\"></span><em>Extended thinking</em> button, next to the <span class=\"tn-icon bx bx-shield-quarter\"></span><em>Tools</em> button.</li><li>Models that offer several levels of reasoning (DeepSeek V4, OpenRouter models that reason, OpenAI Codex, Antigravity) have a <span class=\"tn-icon bx bx-brain\"></span>reasoning effort dropdown next to the model selector instead. <em>None</em>, where offered, turns thinking off; higher levels give better answers to hard questions, but take longer and cost more.</li></ul><aside class=\"admonition note\"><p>The effort dropdown only appears once Trilium knows the model's levels. For a DeepSeek provider set up with an earlier version of Trilium, edit the provider in the model selection box and press <em>Save</em> once.</p></aside><h3>Note access (tools)</h3><p>Tools allow the agentic AI to understand and operate on notes directly within your Trilium instance.</p><p>This feature is on by default. To turn it off, press the <span class=\"tn-icon bx bx-shield-quarter\"></span><em>Tools</em> button next to the model selector at the bottom of the chat and switch off <em>Note access</em>. The <em>Tools</em> button is highlighted while note access or web search is on.</p><p>Here are a few tools that Trilium provides for the LLM:</p><ul><li>At note level:<ul><li>Search for notes</li><li>Get the metadata or content of a note.</li><li>Edit a note<ul><li>There are multiple mechanism for the LLM to edit a note: completely by re-writing it, find/replace of a text sequence or append.</li><li>When re-writing a note, the LLM can also change its type (for example from a text note to a code note) or the language of a code note, rewriting the content to match.</li><li>Whenever the AI makes a change, a <a href=\"#root/_help_vZWERwf8U3nx\">revision</a> is saved to be able to revert any unwanted changes.</li></ul></li><li>Create a new note<ul><li>Asked for a drawing, the LLM can create an SVG image note, or turn an existing note into one. It can write only SVG images, not other formats such as PNG.</li></ul></li><li>Rename or delete a note.</li></ul></li><li>At attribute level:<ul><li>Get the full list of attributes, or a specific attribute.</li><li>Set the value of an attribute, or add another value next to the existing ones (such as a second <code>#tag</code>). When setting a value replaces an existing one, the AI is told which value it replaced.<ul><li>An attribute that runs code, such as <code>#run</code>, <code>#widget</code> or <code>~renderNote</code>, is saved with a <code>disabled:</code> prefix (for example <code>#disabled:widget</code>), the same way a safe import disables it (see <a class=\"reference-link\" href=\"#root/_help_YzMcWlCVeW09\">Active content</a>). If the note already had that attribute enabled and the AI sets rather than adds the value, the AI removes the enabled one, so none of it runs until you enable the new value. The AI tells you which note it is on; review the code, then enable it with the toggle next to the active content badge beside the note's title or, for a <a class=\"reference-link\" href=\"#root/_help_HcABDtFCkbFN\">Render Note</a>, the <em>Enable render note</em> button in the note.</li></ul></li><li>Delete an attribute.</li></ul></li><li>At tree level:<ul><li>Get the direct children of a note.</li><li>Get the entire subtree of a note.</li><li>Move or clone a note somewhere else.</li></ul></li><li>For <a class=\"reference-link\" href=\"#root/_help_0vhv7lsOLy82\">Attachments</a>:<ul><li>Get metadata for an attachment.</li><li>Get the content of an attachment.</li></ul></li><li>Skills (see the dedicated section).</li></ul><p>Each tool the AI uses appears in the chat as a single line naming the tool and the note or query it worked on; a renamed note shows its previous title struck through, a deleted note its title struck through, a moved note where it was moved from and to, an attribute the AI read, set, added or deleted as a pill (struck through once deleted), an attachment by its title, note and size, and a web page the AI read as a link. A line folds open only when there is something to read inline: the notes a search found, the pages a web search found, the icons an icon search found, the type, attributes or start of the content of a note the AI read, all the attributes of a note, the text of an attachment or of a web page, the User Guide pages the AI looked up or its table of contents (both open in the help panel), the children or the whole subtree of a note, what the AI wrote into a note it created, rewrote or added to, the changes of an edit, or the reason a tool failed. A search names on its line the part of the tree it is confined to, if any, and also shows how many notes it found and how many of the matches the AI asked for; each note it lists opens with a click. To see exactly what the AI sent to a tool and what it got back, hover the line and press the <span class=\"tn-icon bx bx-code-alt\"></span>button next to it; on touch screens the button is always shown.</p><p>When the reply stops moving for a couple of seconds while the AI is still at work, for example while it reads what a tool returned, a <em>Still working…</em> line appears under it until the next part of the reply arrives.</p><h4>Approving tool calls</h4><p>Before the AI runs a tool, the chat asks whether to allow it. The tool's line is marked with a <span class=\"tn-icon bx bxs-hand\"></span>icon and has <em>Allow</em> and <em>Deny</em> buttons below it. When the call would write to a note, the line opens on the text it would write or the changes of an edit. The reply waits until you answer.</p><ul><li>To let the call run, press <em>Allow</em>.</li><li>To stop asking about a tool for the rest of the chat, open the menu next to <em>Allow</em> and choose to always allow that tool for this chat. The call runs, and so do the other calls of that tool still waiting and every later one in this chat. Other tools keep asking, and a new chat asks again.</li><li>To refuse it, press <em>Deny</em>. The AI is told that you declined, and its reply carries on without the call, which is marked <em>denied</em>.</li><li>Stopping the reply denies every call that is still waiting.</li></ul><p>To make a chat ask about a tool again, open the <span class=\"tn-icon bx bx-shield-quarter\"></span><em>Tools</em> menu at the bottom of the chat and, under <em>Allowed in this chat</em>, press the tool. The submenu is shown once the chat has allowed a tool.</p><p>Which calls ask depends on the chat's permission mode, chosen in the <span class=\"tn-icon bx bx-shield-quarter\"></span><em>Tools</em> menu under <em>Permissions</em>:</p><ul><li><em>Always ask</em>: every call asks, including the ones that only read (searching notes, or reading a note or an attachment).</li><li><em>Ask before changes</em>: the calls that only read run on their own, and the ones that change your notes (creating, editing, renaming, moving or deleting a note, and setting, adding or deleting an attribute) ask.</li><li><em>Don't ask</em>: every call runs without asking, changes included.</li></ul><p>A new chat starts in the mode you picked last, in any chat, or in <em>Ask before changes</em> until you pick one. Picking <em>Don't ask</em> therefore carries over to the next chat too.</p><p>A tool allowed for the chat runs without asking in every mode. So does looking something up in what ships with Trilium (its User Guide, the skill sheets that teach the AI Trilium's search syntax and note types, and the icons), since it reads none of your notes. Searching the web and reading a web page never ask either: turning on web search in the <em>Tools</em> menu is what allows them, whether the model searches on its own or through a search provider.</p><aside class=\"admonition note\"><p>The <a class=\"reference-link\" href=\"#root/_help_eFhxp9laTW1S\">Subscription-based providers</a> (Claude Code, GitHub Copilot, Google Antigravity and OpenAI Codex) ask like any other provider.</p></aside><aside class=\"admonition note\"><p>Most changes you allow can be undone: a deleted note can be restored, and an edit reverted from its revision. Setting an attribute is harder to undo, since attributes have no history.</p></aside><aside class=\"admonition note\"><p>Gemini can't use its built-in search while note access is on. While it is, the built-in search choice in the <em>Tools</em> menu is disabled and says why; a search provider works with note access on.</p></aside><h3>Attachments</h3><p>Since Trilium v0.140.0, <a class=\"reference-link\" href=\"#root/_help_0vhv7lsOLy82\">Attachments</a> allow for multi-modal chat:</p><ul><li>Raster image (sent as vision input, except for SVGs) with the following supported formats: PNG, JPEG, GIF, WebP.</li><li>PDFs, sent natively to the provider (supported by Anthropic, OpenAI and Google).</li><li>SVG images (sent as raw HTML).</li><li>Text files.</li></ul><p>Not every model reads every kind of attachment: DeepSeek reads no PDFs, and images only with its vision models; OpenAI Codex, GitHub Copilot and Google Antigravity read images but no PDFs. For such a model:</p><ul><li>The attach button offers only the kinds the model reads, and a pasted or dropped file it can't read is not attached.</li><li>After switching to such a model, an attachment it can't read is marked with a <span class=\"tn-icon bx bx-error\"></span>warning, and the message can't be sent until the attachment is removed or another model is selected.</li><li>An attachment sent in an earlier message reaches the model as its name only, such as <code>[attached file: report.pdf]</code>, so it can tell you it doesn't see the content.</li></ul><p>To upload an attachment:</p><ul><li>Press the dedicated <em>Attach</em> button (paperclip icon) underneath the text box.</li><li>Paste an image directly from clipboard using Ctrl+V.</li></ul><p>Once one or more attachments are uploaded, they will appear directly above the text box:</p><ul><li>Images have a small thumbnail for easy identifications.</li><li>Every attachment can be deleted by pressing their corresponding X button.</li></ul><p>Clicking an image or a PDF, either its chip above the text box or where it appears in a sent message, opens it in a viewer: an image can be zoomed and panned there, a PDF read page by page. The button next to the viewer's close button opens the original file in a new browser tab. <kbd>Ctrl</kbd>-clicking instead opens an image in a new browser tab, and a PDF as an attachment in a new Trilium tab.</p><p>When an attachment is present, the LLM is instructed to consider the attachment with priority, even if it has access to the current note.</p><aside class=\"admonition note\"><p>Currently Trilium doesn't pre-process the attachments (e.g. via <a class=\"reference-link\" href=\"#root/_help_TiQbQDgP8L5t\">Text Extraction (OCR)</a>) before sending them to the LLM provider.</p></aside><h3>Mentions</h3><p>Mentions are a way to insert references to notes other than the current note, using the same mechanism as <a class=\"reference-link\" href=\"#root/_help_hrZ1D00cLbal\">Internal (reference) links</a>. To refer to another note, simply type @ followed by the name of the note to reference.</p><p>This feature is mostly helpful when note tools are enabled, otherwise the LLM will have no way to access the given note.</p><h3>Skills</h3><p>Skills in Trilium are specialized instruction sets that help the AI be more productive by understanding how Trilium.</p><p>These skills are not loaded by default to avoid an increased consumption of tokens, but the AI can load them on-demand if <em>Note tools</em> are enabled.</p><p>The following skills are built-in:</p><ul><li>Search syntax: understands the full syntax of <a class=\"reference-link\" href=\"#root/_help_eIg8jdvaoNNd\">Search</a>.</li><li>Backend scripting: to be able to write proper <a class=\"reference-link\" href=\"#root/_help_SPirpZypehBG\">Backend scripts</a>.</li><li>Frontend scripting: to be able to write proper <a href=\"#root/_help_yIhgI5H7A2Sm\">front-end scripts</a> (basic scripts, widgets, <a class=\"reference-link\" href=\"#root/_help_HcABDtFCkbFN\">Render Note</a>).</li><li>Dashboards: to build a <a class=\"reference-link\" href=\"#root/_help_IF7Q6I9x7zuw\">Dashboard</a> and its widgets, including interactive ones made with a <a class=\"reference-link\" href=\"#root/_help_HcABDtFCkbFN\">Render Note</a>.</li></ul><p>When <em>Note tools</em> are enabled the skills will automatically be made available to the AI, so no user interaction is required.</p><aside class=\"admonition note\"><p>Custom skills are currently not supported but they are planned.</p></aside><h3>MCP</h3><p>Trilium comes with a built-in MCP server which allows you to use an external agent such as Claude Code have access to your database. See the dedicated <a class=\"reference-link\" href=\"#root/_help_KOWBFgsZXJAD\">MCP</a> page for more details.</p><h2>History</h2><h3>Removal in v0.102.0</h3><p>Starting with version v0.102.0, AI/LLM integration has been removed from the Trilium Notes core.</p><p>While a significant amount of effort went into developing this feature, maintaining and supporting it long-term proved to be unsustainable.</p><p>When upgrading to v0.102.0, your Chat notes will be preserved, but instead of the dedicated chat window they will be turned to a normal <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> note, revealing the underlying JSON of the conversation.</p><h3>Reintroduction in v0.103.0</h3><p>Given the recent advancements of the AI scene, we decided to give the LLM integration another try. v0.103.0 introduces a completely new chat system.</p><p>One of the key changes that lead to the reimplementation is that now we are using a library (<a href=\"https://github.com/vercel/ai\">Vercel AI</a>) to manage the inner mechanism and the differences between LLM providers instead of having to implement it on our own.</p>",+ "_help_GBBMSlVSOIGP": "<p>Trilium can connect to a large language model and use it as an assistant that works directly on your notes: ask questions about the note you're reading, have it draft or restructure content, or get it to write scripts and widgets for you.</p><p>The integration is off by default and does nothing until you enable it and configure a provider; Trilium ships no model of its own. The provider you pick decides how your notes travel: a cloud API billed per use, a subscription you already pay for, or a model running on your own hardware, in which case nothing leaves the machine. See <a class=\"reference-link\" href=\"#root/_help_bkPZAMT7d2sR\">Providers</a> for what each involves, and <a class=\"reference-link\" href=\"#root/_help_cRRrdZjgyhNc\">Privacy</a> for exactly what gets sent.</p><p>Once enabled, the assistant is available as:</p><ul><li>As a dedicated note type, it can read and modify notes through tools, which you can switch off per conversation if you would rather it only saw what you type.</li><li>A panel in the right sidebar, which acts similarly to the dedicated note type but it also has optional access to the current note.</li><li>An <a class=\"reference-link\" href=\"#root/_help_VRoP0g1uHHc2\">In-editor AI assistant</a> which comes with builtin actions that operate over selected text (such as proof-reading, summarizing), as well as <a class=\"reference-link\" href=\"#root/_help_mVEYwt20exhO\">Custom AI quick actions</a>.</li></ul><h2>Feature highlights</h2><ul><li>Chat-based interface with live streaming of the messages.</li><li>Provides the AI context with the note currently being looked at.</li><li>Tools to alter note content, create new notes, etc.</li><li>Statistics regarding context window use and pricing per message.</li><li>Attachments for multi-modal chat (images, text files, PDFs).</li><li>Optional MCP to allow external chat tools (e.g. Claude Code) to operate on notes within Trilium.</li></ul><h2>Sample use-cases</h2><ul><li>Create any type of <a class=\"reference-link\" href=\"#root/_help_MgibgPcfeuGz\">Custom Widgets</a>.</li><li>Easily create a <a class=\"reference-link\" href=\"#root/_help_HcABDtFCkbFN\">Render Note</a>, e.g. <em>Create for me a render note which allows me to play tic-tac-toe. Make sure to use Preact instead of the legacy jQuery.</em></li><li>Create widgets for a <a class=\"reference-link\" href=\"#root/_help_IF7Q6I9x7zuw\">Dashboard</a>, such as a calculator, a stopwatch, a pomodoro timer.</li></ul><aside class=\"admonition note\"><p>Claude Sonnet is known to produce very good frontend or backend scripts with little guidance, as the AI has been instructed in how to produce them.</p></aside><h2>LLM Providers</h2><p>Trilium supports four different types of providers:</p><div class=\"trilium-tabs\"><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-cloud\"></span> Cloud</p><div class=\"trilium-tab-panel\"><p>Pay-per use with an API key which is billed separately from any subscription you might already have.</p><ul><li><span class=\"tn-icon tn-brand tn-brand-anthropic\"></span> Anthropic Claude</li><li><span class=\"tn-icon tn-brand tn-brand-openai\"></span> OpenAI GPT</li><li><span class=\"tn-icon tn-brand tn-brand-gemini\"></span> Google Gemini</li><li><span class=\"tn-icon tn-brand tn-brand-deepseek\"></span> DeepSeek</li><li><span class=\"tn-icon tn-brand tn-brand-openrouter\"></span> OpenRouter, which reaches the models of most labs with one key</li></ul></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-coin\"></span> Subscription-based</p><div class=\"trilium-tab-panel\"><p>Reuses an existing subscription instead of paying per use.</p><ul><li><span class=\"tn-icon tn-brand tn-brand-claude\"></span> <a href=\"#root/_help_eFhxp9laTW1S\">Claude Code</a></li><li><span class=\"tn-icon tn-brand tn-brand-github-copilot\"></span> <a href=\"#root/_help_eFhxp9laTW1S\">GitHub Copilot</a></li><li><span class=\"tn-icon tn-brand tn-brand-antigravity\"></span> <a href=\"#root/_help_eFhxp9laTW1S\">Google Antigravity</a></li><li><span class=\"tn-icon tn-brand tn-brand-codex\"></span> <a href=\"#root/_help_eFhxp9laTW1S\">OpenAI Codex</a></li></ul></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-network-chart\"></span> Local/self-hosted</p><div class=\"trilium-tab-panel\"><ul><li><span class=\"tn-icon tn-brand tn-brand-ollama\"></span> Ollama</li><li><span class=\"tn-icon tn-brand tn-brand-lmstudio\"></span> LM Studio</li></ul></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bx-code-curly\"></span> Custom endpoints</p><div class=\"trilium-tab-panel\"><p>For other providers that are not directly supported by Trilium, either local or hosted (e.g. Groq, Mistral, Together).</p></div></section></div><aside class=\"admonition tip\"><p>For more information about each provider, see <a class=\"reference-link\" href=\"#root/_help_bkPZAMT7d2sR\">Providers</a>. See the dedicated <a class=\"reference-link\" href=\"#root/_help_cRRrdZjgyhNc\">Privacy</a> to better understand what data is sent to providers.</p></aside><h2>Enabling the AI integration</h2><p>To enable the AI integration, simply go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>AI / LLM</em> and press the toggle in the top-right of the dialog and configure a provider.</p><h2>Creating a new chat</h2><p>There are two different chat interfaces:</p><ul><li>One in the sidebar.</li><li>A dedicated note type.</li></ul><h3>The sidebar interface</h3><h3>The dedicated note type</h3><p>The dedicated chat note is similar to the sidebar interface, but it makes longer conversations more comfortable to read.</p><p>Unlike the sidebar, the AI will not be aware of the current note it's in.</p><h3>Templates</h3><p>Chat notes can be set as <a class=\"reference-link\" href=\"#root/_help_KC1HB96bqqHX\">Templates</a> to make them easily reusable. The entire conversation history is kept, allowing a basic form of specialization for the LLM with the existing chat acting like a system prompt. </p><h3>Model selection</h3><p>When a provider is configured in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a>, the next step is to select the models that will be available for the chat.</p><p>The models are retrieved dynamically from the provider, only when the model selection list is visible. To alter the list of models, simply press the Edit button in the model selection box.</p><p>Pricing information is displayed for known models. The pricing information (price per million tokens) is embedded in the application (using a subset of LiteLLM's data) and is updated with new versions of Trilium. Local providers are considered free, whereas custom endpoint providers don't offer any pricing information.</p><h2>Features</h2><h3>Web search</h3><p>The AI can optionally search the web to find more information about a specific topic. </p><p>Where the search comes from is chosen in the <em>Web search</em> submenu of the <span class=\"tn-icon bx bx-shield-quarter\"></span><em>Tools</em> menu next to the model selector at the bottom of the chat, whose row shows the source in use:</p><ul><li><em>Disabled</em> turns web search off for this chat.</li><li><em>Use the model's built-in search</em>, the default, lets the model search with its provider's own search. Anthropic, OpenAI, Google Gemini and DeepSeek models have one, as do Claude Code, Google Antigravity and OpenAI Codex. OpenRouter, Ollama, LM Studio and custom endpoints don't, so this choice is disabled for their models. DeepSeek's search is billed per search on your DeepSeek account and works only with DeepSeek's own endpoint, not with a custom base URL.</li><li>A search provider (Brave Search, Tavily, Exa, Serper, Perplexity or SearXNG) searches through that service instead, whichever model is answering. Search providers are added in the <em>Search Providers</em> section of the AI settings, which <em>Manage search providers</em> at the bottom of the submenu opens. The browser version can't use Brave Search, Exa or Perplexity, whose services refuse requests made from a web page, so they're shown disabled there.</li></ul><p>To use SearXNG, enable its JSON output by adding <code>json</code> to the search formats in the instance's <code>settings.yml</code>. SearXNG turns JSON off by default, and without it every search fails.</p><pre><code class=\"language-text-x-yaml\">search:\n formats:\n - html\n - json</code></pre><p>SearXNG doesn't use API keys, so leave the API key empty. Fill it in only if your instance sits behind a proxy that requires a token; Trilium sends it as a bearer token in the <code>Authorization</code> header.</p><p>Whether web search is on is kept per chat; the search source is shared by all chats. A choice the current model can't use stays in the menu, disabled; hover the <span class=\"tn-icon bx bx-info-circle\"></span> icon next to it to see why. Claude Code, GitHub Copilot, Google Antigravity and OpenAI Codex run their own tools, so they can't use a search provider.</p><p>In the chat, a search run through a search provider shows that provider's logo at the start of its line instead of the <span class=\"tn-icon bx bx-search\"></span> magnifier; hover the logo to see the provider's name.</p><p>With a search provider, the model can also read the pages it finds, or a link you give it, as text: Trilium fetches the page itself and hands the model up to its first 20,000 characters. Addresses on your own machine or network are refused. In the browser version most sites don't allow being read this way, so reading a page there usually fails.</p><h3>Thinking</h3><p>Some models reason before they answer. While the model is thinking, its reasoning is shown in full under a spinner; once it is done, it folds into a collapsible <em>Thought process</em> line above the reply.</p><p>How much a model thinks is set per chat, in one of two ways depending on the model:</p><ul><li>Most models have an <span class=\"tn-icon bx bx-brain\"></span><em>Extended thinking</em> button, next to the <span class=\"tn-icon bx bx-shield-quarter\"></span><em>Tools</em> button.</li><li>Models that offer several levels of reasoning (DeepSeek V4, OpenRouter models that reason, OpenAI Codex, Antigravity) have a <span class=\"tn-icon bx bx-brain\"></span> reasoning effort dropdown next to the model selector instead. <em>None</em>, where offered, turns thinking off; higher levels give better answers to hard questions, but take longer and cost more.</li></ul><aside class=\"admonition note\"><p>The effort dropdown only appears once Trilium knows the model's levels. For a DeepSeek provider set up with an earlier version of Trilium, edit the provider in the model selection box and press <em>Save</em> once.</p></aside><h3>Note access (tools)</h3><p>Tools allow the agentic AI to understand and operate on notes directly within your Trilium instance.</p><p>This feature is on by default. To turn it off, press the <span class=\"tn-icon bx bx-shield-quarter\"></span><em>Tools</em> button next to the model selector at the bottom of the chat and switch off <em>Note access</em>. The <em>Tools</em> button is highlighted while note access or web search is on.</p><p>Here are a few tools that Trilium provides for the LLM:</p><ul><li>At note level:<ul><li>Search for notes</li><li>Get the metadata or content of a note.</li><li>Edit a note<ul><li>There are multiple mechanism for the LLM to edit a note: completely by re-writing it, find/replace of a text sequence or append.</li><li>When re-writing a note, the LLM can also change its type (for example from a text note to a code note) or the language of a code note, rewriting the content to match.</li><li>Whenever the AI makes a change, a <a href=\"#root/_help_vZWERwf8U3nx\">revision</a> is saved to be able to revert any unwanted changes.</li></ul></li><li>Create a new note<ul><li>Asked for a drawing, the LLM can create an SVG image note, or turn an existing note into one. It can write only SVG images, not other formats such as PNG.</li></ul></li><li>Rename or delete a note.</li></ul></li><li>At attribute level:<ul><li>Get the full list of attributes, or a specific attribute.</li><li>Set the value of an attribute, or add another value next to the existing ones (such as a second <code>#tag</code>). When setting a value replaces an existing one, the AI is told which value it replaced.<ul><li>An attribute that runs code, such as <code>#run</code>, <code>#widget</code> or <code>~renderNote</code>, is saved with a <code>disabled:</code> prefix (for example <code>#disabled:widget</code>), the same way a safe import disables it (see <a class=\"reference-link\" href=\"#root/_help_YzMcWlCVeW09\">Active content</a>). If the note already had that attribute enabled and the AI sets rather than adds the value, the AI removes the enabled one, so none of it runs until you enable the new value. The AI tells you which note it is on; review the code, then enable it with the toggle next to the active content badge beside the note's title or, for a <a class=\"reference-link\" href=\"#root/_help_HcABDtFCkbFN\">Render Note</a>, the <em>Enable render note</em> button in the note.</li></ul></li><li>Delete an attribute.</li></ul></li><li>At tree level:<ul><li>Get the direct children of a note.</li><li>Get the entire subtree of a note.</li><li>Move or clone a note somewhere else.</li></ul></li><li>For <a class=\"reference-link\" href=\"#root/_help_0vhv7lsOLy82\">Attachments</a>:<ul><li>Get metadata for an attachment.</li><li>Get the content of an attachment.</li></ul></li><li>Skills (see the dedicated section).</li></ul><p>Each tool the AI uses appears in the chat as a single line naming the tool and the note or query it worked on; a renamed note shows its previous title struck through, a deleted note its title struck through, a moved note where it was moved from and to, an attribute the AI read, set, added or deleted as a pill (struck through once deleted), an attachment by its title, note and size, and a web page the AI read as a link. A line folds open only when there is something to read inline: the notes a search found, the pages a web search found, the icons an icon search found, the type, attributes or start of the content of a note the AI read, all the attributes of a note, the text of an attachment or of a web page, the User Guide pages the AI looked up or its table of contents (both open in the help panel), the children or the whole subtree of a note, what the AI wrote into a note it created, rewrote or added to, the changes of an edit, or the reason a tool failed. A search names on its line the part of the tree it is confined to, if any, and also shows how many notes it found and how many of the matches the AI asked for; each note it lists opens with a click. To see exactly what the AI sent to a tool and what it got back, hover the line and press the <span class=\"tn-icon bx bx-code-alt\"></span> button next to it; on touch screens the button is always shown.</p><p>When the reply stops moving for a couple of seconds while the AI is still at work, for example while it reads what a tool returned, a <em>Still working…</em> line appears under it until the next part of the reply arrives.</p><h4>Approving tool calls</h4><p>Before the AI runs a tool, the chat asks whether to allow it. The tool's line is marked with a <span class=\"tn-icon bx bxs-hand\"></span> icon and has <em>Allow</em> and <em>Deny</em> buttons below it. When the call would write to a note, the line opens on the text it would write or the changes of an edit. The reply waits until you answer.</p><ul><li>To let the call run, press <em>Allow</em>.</li><li>To stop asking about a tool for the rest of the chat, open the menu next to <em>Allow</em> and choose to always allow that tool for this chat. The call runs, and so do the other calls of that tool still waiting and every later one in this chat. Other tools keep asking, and a new chat asks again.</li><li>To refuse it, press <em>Deny</em>. The AI is told that you declined, and its reply carries on without the call, which is marked <em>denied</em>.</li><li>Stopping the reply denies every call that is still waiting.</li></ul><p>To make a chat ask about a tool again, open the <span class=\"tn-icon bx bx-shield-quarter\"></span><em>Tools</em> menu at the bottom of the chat and, under <em>Allowed in this chat</em>, press the tool. The submenu is shown once the chat has allowed a tool.</p><p>Which calls ask depends on the chat's permission mode, chosen in the <span class=\"tn-icon bx bx-shield-quarter\"></span><em>Tools</em> menu under <em>Permissions</em>:</p><ul><li><em>Always ask</em>: every call asks, including the ones that only read (searching notes, or reading a note or an attachment).</li><li><em>Ask before changes</em>: the calls that only read run on their own, and the ones that change your notes (creating, editing, renaming, moving or deleting a note, and setting, adding or deleting an attribute) ask.</li><li><em>Don't ask</em>: every call runs without asking, changes included.</li></ul><p>A new chat starts in the mode you picked last, in any chat, or in <em>Ask before changes</em> until you pick one. Picking <em>Don't ask</em> therefore carries over to the next chat too.</p><p>A tool allowed for the chat runs without asking in every mode. So does looking something up in what ships with Trilium (its User Guide, the skill sheets that teach the AI Trilium's search syntax and note types, and the icons), since it reads none of your notes. Searching the web and reading a web page never ask either: turning on web search in the <em>Tools</em> menu is what allows them, whether the model searches on its own or through a search provider.</p><aside class=\"admonition note\"><p>The <a class=\"reference-link\" href=\"#root/_help_eFhxp9laTW1S\">Subscription-based providers</a> (Claude Code, GitHub Copilot, Google Antigravity and OpenAI Codex) ask like any other provider.</p></aside><aside class=\"admonition note\"><p>Most changes you allow can be undone: a deleted note can be restored, and an edit reverted from its revision. Setting an attribute is harder to undo, since attributes have no history.</p></aside><aside class=\"admonition note\"><p>Gemini can't use its built-in search while note access is on. While it is, the built-in search choice in the <em>Tools</em> menu is disabled and says why; a search provider works with note access on.</p></aside><h3>Attachments</h3><p>Since Trilium v0.140.0, <a class=\"reference-link\" href=\"#root/_help_0vhv7lsOLy82\">Attachments</a> allow for multi-modal chat:</p><ul><li>Raster image (sent as vision input, except for SVGs) with the following supported formats: PNG, JPEG, GIF, WebP.</li><li>PDFs, sent natively to the provider (supported by Anthropic, OpenAI and Google).</li><li>SVG images (sent as raw HTML).</li><li>Text files.</li></ul><p>Not every model reads every kind of attachment: DeepSeek reads no PDFs, and images only with its vision models; OpenAI Codex, GitHub Copilot and Google Antigravity read images but no PDFs. For such a model:</p><ul><li>The attach button offers only the kinds the model reads, and a pasted or dropped file it can't read is not attached.</li><li>After switching to such a model, an attachment it can't read is marked with a <span class=\"tn-icon bx bx-error\"></span> warning, and the message can't be sent until the attachment is removed or another model is selected.</li><li>An attachment sent in an earlier message reaches the model as its name only, such as <code>[attached file: report.pdf]</code>, so it can tell you it doesn't see the content.</li></ul><p>To upload an attachment:</p><ul><li>Press the dedicated <em>Attach</em> button (paperclip icon) underneath the text box.</li><li>Paste an image directly from clipboard using Ctrl+V.</li></ul><p>Once one or more attachments are uploaded, they will appear directly above the text box:</p><ul><li>Images have a small thumbnail for easy identifications.</li><li>Every attachment can be deleted by pressing their corresponding X button.</li></ul><p>Clicking an image or a PDF, either its chip above the text box or where it appears in a sent message, opens it in a viewer: an image can be zoomed and panned there, a PDF read page by page. The button next to the viewer's close button opens the original file in a new browser tab. <kbd>Ctrl</kbd>-clicking instead opens an image in a new browser tab, and a PDF as an attachment in a new Trilium tab.</p><p>When an attachment is present, the LLM is instructed to consider the attachment with priority, even if it has access to the current note.</p><aside class=\"admonition note\"><p>Currently Trilium doesn't pre-process the attachments (e.g. via <a class=\"reference-link\" href=\"#root/_help_TiQbQDgP8L5t\">Text Extraction (OCR)</a>) before sending them to the LLM provider.</p></aside><h3>Mentions</h3><p>Mentions are a way to insert references to notes other than the current note, using the same mechanism as <a class=\"reference-link\" href=\"#root/_help_hrZ1D00cLbal\">Internal (reference) links</a>. To refer to another note, simply type @ followed by the name of the note to reference.</p><p>This feature is mostly helpful when note tools are enabled, otherwise the LLM will have no way to access the given note.</p><h3>Skills</h3><p>Skills in Trilium are specialized instruction sets that help the AI be more productive by understanding how Trilium.</p><p>These skills are not loaded by default to avoid an increased consumption of tokens, but the AI can load them on-demand if <em>Note tools</em> are enabled.</p><p>The following skills are built-in:</p><ul><li>Search syntax: understands the full syntax of <a class=\"reference-link\" href=\"#root/_help_eIg8jdvaoNNd\">Search</a>.</li><li>Backend scripting: to be able to write proper <a class=\"reference-link\" href=\"#root/_help_SPirpZypehBG\">Backend scripts</a>.</li><li>Frontend scripting: to be able to write proper <a href=\"#root/_help_yIhgI5H7A2Sm\">front-end scripts</a> (basic scripts, widgets, <a class=\"reference-link\" href=\"#root/_help_HcABDtFCkbFN\">Render Note</a>).</li><li>Dashboards: to build a <a class=\"reference-link\" href=\"#root/_help_IF7Q6I9x7zuw\">Dashboard</a> and its widgets, including interactive ones made with a <a class=\"reference-link\" href=\"#root/_help_HcABDtFCkbFN\">Render Note</a>.</li></ul><p>When <em>Note tools</em> are enabled the skills will automatically be made available to the AI, so no user interaction is required.</p><aside class=\"admonition note\"><p>Custom skills are currently not supported but they are planned.</p></aside><h3>MCP</h3><p>Trilium comes with a built-in MCP server which allows you to use an external agent such as Claude Code have access to your database. See the dedicated <a class=\"reference-link\" href=\"#root/_help_KOWBFgsZXJAD\">MCP</a> page for more details.</p><h2>History</h2><h3>Removal in v0.102.0</h3><p>Starting with version v0.102.0, AI/LLM integration has been removed from the Trilium Notes core.</p><p>While a significant amount of effort went into developing this feature, maintaining and supporting it long-term proved to be unsustainable.</p><p>When upgrading to v0.102.0, your Chat notes will be preserved, but instead of the dedicated chat window they will be turned to a normal <a class=\"reference-link\" href=\"#root/_help_6f9hih2hXXZk\">Code</a> note, revealing the underlying JSON of the conversation.</p><h3>Reintroduction in v0.103.0</h3><p>Given the recent advancements of the AI scene, we decided to give the LLM integration another try. v0.103.0 introduces a completely new chat system.</p><p>One of the key changes that lead to the reimplementation is that now we are using a library (<a href=\"https://github.com/vercel/ai\">Vercel AI</a>) to manage the inner mechanism and the differences between LLM providers instead of having to implement it on our own.</p>","_help_bkPZAMT7d2sR": "<p>Providers are added in the <em>Model Providers</em> section of the AI settings, with <em>Add Model Provider</em>. Each one lists the models selected for it, which are the ones the chat offers; a provider with no models selected is not offered in the chat.</p><h2>Cloud providers using API keys</h2><p>Currently, the following cloud providers are supported:</p><ul><li><span class=\"tn-icon tn-brand tn-brand-anthropic\"></span> <a href=\"https://platform.claude.com/settings/workspaces/default/keys\">Anthropic</a></li><li><span class=\"tn-icon tn-brand tn-brand-openai\"></span> OpenAI</li><li><span class=\"tn-icon tn-brand tn-brand-gemini\"></span> Gemini</li><li><span class=\"tn-icon tn-brand tn-brand-deepseek\"></span> DeepSeek</li><li><span class=\"tn-icon tn-brand tn-brand-openrouter\"></span> <a href=\"https://openrouter.ai/settings/keys\">OpenRouter</a></li></ul><p>For all the providers, an API key is needed. Note that this is charged separately from the subscription you might already have (e.g. Claude Pro). If that might be a problem, consider using either a subscription provider (see below) or using it externally via MCP.</p><p>Do note that most other LLM providers (e.g. Groq, Mistral, Together) can still be used in Trilium via the OpenAI-compatible custom endpoint (see below).</p><p>If you are using a proxy or gateway, you can also configure the base URL, otherwise the default will be used.</p><p>For OpenRouter, the models are billed to your OpenRouter credits, and their prices, context windows and the attachments they read come from OpenRouter's own model list:</p><ul><li>The <em>Latest</em> models that can use tools are selected by default, such as <em>Anthropic: Claude Sonnet Latest</em>. OpenRouter points each of them at the newest model of its line, so the selection stays current without editing the provider.</li><li>Models that reason have a reasoning effort dropdown in the chat (<em>Low</em>, <em>Medium</em> or <em>High</em>).</li><li><em>Auto Router</em> (<code>openrouter/auto</code>) picks a model for each message. Below each reply, the chat names the model that wrote it, which is also the case when a <em>Latest</em> model was used.</li><li>The cost shown below a reply is what OpenRouter billed for it, rather than an estimate from the listed prices.</li><li>Image generation models and the deferred <em>batch</em> variants are not listed.</li><li>Chat titles are generated with <em>Anthropic: Claude Haiku Latest</em>.</li><li>Requests are attributed to Trilium on your OpenRouter activity page.</li></ul><p>For Gemini, a chat that doesn't specify a model uses <code>gemini-3.8-flash</code>, and the automatically generated chat titles use <code>gemini-3.5-flash-lite</code>. A model you select explicitly is used as is and isn't affected by these defaults.</p><aside class=\"admonition note\"><p>We don't plan to support all cloud providers, even if the library we are using would theoretically support them. Before opening a PR adding support for a different cloud provider, make sure to discuss it over <a href=\"https://github.com/orgs/TriliumNext/discussions\">GitHub Discussions</a>.</p></aside><aside class=\"admonition important\"><p>See also the dedicated <a class=\"reference-link\" href=\"#root/_help_cRRrdZjgyhNc\">Privacy</a> section to better understand what data is being sent to a cloud provider.</p></aside><h2>Subscription-based providers</h2><p>Trilium integrates multiple <a class=\"reference-link\" href=\"#root/_help_eFhxp9laTW1S\">Subscription-based providers</a>:</p><ul><li><span class=\"tn-icon tn-brand tn-brand-claude\"></span> Claude Code by reusing your CLI.</li><li><span class=\"tn-icon tn-brand tn-brand-github-copilot\"></span> GitHub Copilot by reusing your CLI's ACP.</li><li><span class=\"tn-icon tn-brand tn-brand-antigravity\"></span> Google Antigravity by downloading and setting up an ACP for Trilium.</li><li><span class=\"tn-icon tn-brand tn-brand-codex\"></span> OpenAI Codex by reusing your CLI through an ACP adapter shipped with Trilium.</li></ul><h2>Local/self-hosted providers</h2><p>Local or self-hosted providers are a free alternative which respects your privacy but requires specific hardware.</p><p>Trilium directly supports the following local providers:</p><div class=\"trilium-tabs\"><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon tn-brand tn-brand-ollama\"></span> Ollama</p><div class=\"trilium-tab-panel\"><p>Generally Ollama runs in the background so it should be directly usable in Trilium as long as the models are downloaded (e.g. <code>ollama pull llama3.2</code>).</p></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon tn-brand tn-brand-lmstudio\"></span> LM Studio</p><div class=\"trilium-tab-panel\"><p>The OpenAI-compatible server is <strong>disabled</strong> by default in LM Studio installations. First download your desired models through the graphical interface, then go to <em>Settings</em> → <em>Developer</em> and toggle <em>Developer mode</em>. On the left there will be a new <em>Developer</em> tab, with a toggle to start it up.</p></div></section></div><p>Even for local providers that are not directly supported by Trilium, you can still use a custom endpoint (see below).</p><aside class=\"admonition warning\"><p>When dealing with self-hosted LLM models, depending on the training and the size of the model, the quality of the output may vary. Before <a href=\"#root/_help_wy8So3yZZlH9\">reporting issues</a> regarding the quality of the output (e.g. hallucinating tool calls), consider benchmarking the response against a cloud provider (Claude Sonnet is recommended).</p></aside><h2>Custom endpoints</h2><p>If your desired hosted (e.g. Groq, Mistral, Together) or local LLM provider is not listed in Trilium, you can use the dedicated <em>OpenAI-compatible</em> provider from the <em>Custom endpoint</em> section.</p><p>This allows you to set the base URL to an OpenAI-compatible API, with an optional API key if required by the service.</p><p>Enter the base URL exactly as the service documents it, including its version path, such as <code>https://api.groq.com/openai/v1</code> or <code>https://open.bigmodel.cn/api/paas/v4</code>. Only a bare host such as <code>http://localhost:8080</code> is completed with <code>/v1</code>.</p><p>The endpoint can run on the same machine as Trilium, elsewhere on your local network or on a Tailscale tailnet. Trilium refuses link-local addresses (<code>169.254.0.0/16</code>) and cloud metadata endpoints, which no model server is served on.</p><p>For custom endpoints, the pricing of the models is not known so the cost of a conversation will not be displayed; this is especially relevant for hosted providers.</p>","_help_eFhxp9laTW1S": "<p>Some cloud providers offer a subscription, which has a fixed monthly fee instead of pay-per-use (unlike the API keys).</p><p>In a nutshell, subscription-based providers work by either reusing your existing CLI tools (e.g. Claude Code, GitHub Copilot and OpenAI Codex via ACP) whereas some require installing the ACP server manually (e.g. Google Antigravity). Because they require something to be installed on your device, these providers are not available on Mobile (Android or iOS) or standalone mode.</p><p>See also the dedicated <a class=\"reference-link\" href=\"#root/_help_cRRrdZjgyhNc\">Privacy</a> section to better understand what data is being sent to a cloud provider.</p><h2>Using the Flatpak</h2><p>The Flatpak version of Trilium (see <a href=\"#root/_help_poXkQfguuA0U\">Installing from Flathub</a>) runs in a sandbox that hides the programs installed on your computer, so on its own it cannot find Claude Code, the GitHub Copilot CLI, the Codex CLI or Google's Antigravity ACP server. Trilium can start them outside the sandbox once you allow it to:</p><ol><li><p>Install the CLI on your computer and sign in to it, as described below for each provider.</p></li><li><p>Allow Trilium to start programs outside its sandbox by running this in a terminal:</p><pre><code class=\"language-text-x-sh\">flatpak override --user --talk-name=org.freedesktop.Flatpak org.triliumnotes.Trilium</code></pre></li><li><p>Restart Trilium, then go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>AI / LLM</em> and add the provider.</p></li></ol><p>Trilium then looks the CLI up in your computer's <code>PATH</code> and in your login shell's, and starts it there through <code>flatpak-spawn --host</code>. Until the permission is granted, adding one of these providers fails with a message that repeats these steps.</p><aside class=\"admonition warning\"><p>This permission lets Trilium run any program on your computer outside the sandbox, which is the same access an installation outside Flatpak has. To take it back, run <code>flatpak override --user --no-talk-name=org.freedesktop.Flatpak org.triliumnotes.Trilium</code> and restart Trilium.</p></aside><p>The environment variables that point Trilium at a CLI (such as <code>TRILIUM_CLAUDE_CODE_PATH</code>) name a file inside the sandbox, so with the Flatpak, leave them unset and let Trilium find the CLI on your computer.</p><h2><span class=\"tn-icon tn-brand tn-brand-claude\"></span> Claude Code</h2><p>To use a subscription:</p><ol><li>First, Claude Code needs to be installed on the machine that runs Trilium. So for a <a class=\"reference-link\" href=\"#root/_help_poXkQfguuA0U\">Desktop Installation</a>, Claude needs to be installed locally and for a <a class=\"reference-link\" href=\"#root/_help_WOcw2SLH6tbX\">Server Installation</a> accessed via a browser, Claude needs to be installed on the server.</li><li>Claude Code must already be authenticated. To do so, run <code>claude</code> in a terminal once, type <code>/login</code> and follow the instructions.</li><li>Go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>AI / LLM</em> and add the Claude Code provider.</li></ol><details class=\"trilium-collapsible\"><summary>How Trilium identifies your Claude Code binary</summary><p>In this order:</p><ul><li>By looking for a <code>TRILIUM_CLAUDE_CODE_PATH</code> environment variable pointing to the Claude binary. This allows overriding the path if needed.</li><li>By looking for <code>claude</code> in your PATH, generally works in most circumstances.</li><li>By asking your login shell for its <code>PATH</code> which lets a desktop install find a CLI installed through <code>nvm</code>, <code>fnm</code>, <code>asdf</code> or Homebrew, since a GUI-launched app doesn't inherit your terminal's environment.</li></ul></details><p>After your provider is set up, you'll benefit from the same features as an API key (note tools, web search, extended thinking, image/PDF attachments, streaming).</p><aside class=\"admonition note\"><p>Trilium intentionally uses your Claude Code binary in order not to have to package a ~250 MB client with it, but this comes at a cost: there is a small risk for a version incompatibility, if the version installed locally doesn't match the one expected by Trilium. Generally it's best to keep both Claude Code and Trilium updated to the latest version.</p></aside><h2><span class=\"tn-icon tn-brand tn-brand-github-copilot\"></span> GitHub Copilot</h2><aside class=\"admonition note\"><p>This subscription-based provider is still in beta. It is safe to use (won't use additional funds and respects the terms of use), but you might experience small issues. Consider <a class=\"reference-link\" href=\"#root/_help_wy8So3yZZlH9\">Reporting issues</a>.</p></aside><p>GitHub Copilot gives access to the models of your GitHub Copilot subscription (Pro, Pro+, Business or Enterprise), without an API key. Usage counts against your Copilot plan.</p><ol><li>Install the GitHub Copilot CLI on the machine that runs Trilium, for example with <code>npm install -g @github/copilot</code>. As with Claude Code, for a <a class=\"reference-link\" href=\"#root/_help_WOcw2SLH6tbX\">Server Installation</a> it needs to be installed on the server.</li><li>Sign in by running <code>copilot login</code> in a terminal once. If you already use GitHub Copilot in another editor on the same machine, that login is reused.</li><li>Go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>AI / LLM</em> and add the GitHub Copilot provider.</li></ol><details class=\"trilium-collapsible\"><summary>How Trilium identifies your Copilot CLI binary</summary><p>In this order:</p><ul><li>By looking for a <code>TRILIUM_COPILOT_PATH</code> environment variable pointing to the Copilot binary.</li><li>By looking for <code>copilot</code> in your PATH.</li><li>By asking your login shell for its <code>PATH</code>, the same as for Claude Code.</li></ul></details><h3>Known limitations</h3><ul><li>The agent can only work with your notes through Trilium's note tools; its own file, shell and web tools are blocked for security reasons.</li><li>Images can be attached to the conversation, PDFs cannot. The LLM should still be able to read PDF notes and attachments via <a class=\"reference-link\" href=\"#root/_help_TiQbQDgP8L5t\">Text Extraction (OCR)</a> when the note tools are enabled.</li></ul><h2><span class=\"tn-icon tn-brand tn-brand-antigravity\"></span> Google Antigravity</h2><aside class=\"admonition note\"><p>This subscription-based provider is still in beta. It is safe to use (won't use additional funds and respects the terms of use), but you might experience small issues. Consider <a class=\"reference-link\" href=\"#root/_help_wy8So3yZZlH9\">Reporting issues</a>.</p></aside><p>Google Antigravity gives access to Gemini models using a Google account (free, Google AI Pro or Google AI Ultra), without an API key. At the time of writing, a free Google account is enough to use it.</p><p>Unlike Claude Code or GitHub Copilot, Google's Antigravity ACP server is not part of the CLI so it needs to be installed manually just for Trilium. The downloaded archive is around 112-334 MB and the extracted size is around 230 MB-2 GB based on the platform.</p><div class=\"trilium-tabs\"><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bxl-windows\"></span> Windows</p><div class=\"trilium-tab-panel\"><ol><li>Download Google's Antigravity ACP server for your platform. The link is shown when adding the provider in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>AI / LLM</em>. Unpack it on the device that runs Trilium.</li><li>Make it findable by Trilium, either:<ol><li>by adding the unpacked folder to your PATH, or</li><li>by setting a <code>TRILIUM_ANTIGRAVITY_ACP_PATH</code> environment variable pointing to <code>agy_acp_server.exe</code>.</li></ol></li><li>Go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → AI / LLM and add the <span class=\"tn-icon tn-brand tn-brand-antigravity\"></span> <em>Google Antigravity</em> provider. When the list of models is loaded for the first time, the Google sign-in page opens in a browser on the machine running Trilium; finish signing in there.</li></ol></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bxl-tux\"></span> Linux & <span class=\"tn-icon bx bxl-apple\"></span> macOS</p><div class=\"trilium-tab-panel\"><ol><li>Download Google's Antigravity ACP server for your platform. The link is shown when adding the provider in <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>AI / LLM</em>. Unpack it on the device that runs Trilium.</li><li>Make it findable by Trilium, either:<ol><li>by adding the unpacked folder to your PATH, or</li><li>by setting a <code>TRILIUM_ANTIGRAVITY_ACP_PATH</code> environment variable pointing to <code>agy_acp_server.par</code>.</li></ol></li><li>Go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → AI / LLM and add the <span class=\"tn-icon tn-brand tn-brand-antigravity\"></span> <em>Google Antigravity</em> provider. When the list of models is loaded for the first time, the Google sign-in page opens in a browser on the machine running Trilium; finish signing in there.</li></ol></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\">NixOS</p><div class=\"trilium-tab-panel\"><ol><li><p>On NixOS, <code>antigravity-acp</code> package is already available but only in <code>nixos-unstable</code> at the time of writing. The easiest method to test it out is to use the <code>nix shell</code> with flakes:</p><pre><code class=\"language-text-x-trilium-auto\">NIXPKGS_ALLOW_UNFREE=1 nix shell --impure github:nixos/nixpkgs/nixos-unstable#antigravity-acp\ntrilium</code></pre></li><li><p>Go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → AI / LLM and add the <span class=\"tn-icon tn-brand tn-brand-antigravity\"></span> <em>Google Antigravity</em> provider. When the list of models is loaded for the first time, the Google sign-in page opens in a browser on the machine running Trilium; finish signing in there.</p></li></ol></div></section></div><aside class=\"admonition note\"><p>Trilium needs <code>curl</code> to use Google Antigravity. It comes with Windows 10 and later, macOS and most Linux distributions.</p></aside><h3>Known limitations</h3><ul><li>The agent can only work with your notes through Trilium's note tools; its own file and shell tools are blocked for security reasons.</li><li>The Antigravity ACP server requires authentication via a login link. The login link needs to be run on the same device, so it might not be possible to set up the provider while using the web version of a Docker installation. <a class=\"reference-link\" href=\"#root/_help_poXkQfguuA0U\">Desktop Installation</a> should work fine.</li><li>Images can be attached to the conversation, PDFs cannot. The LLM should still be able to read PDF notes and attachments via <a class=\"reference-link\" href=\"#root/_help_TiQbQDgP8L5t\">Text Extraction (OCR)</a> when the note tools are enabled.</li><li>The results of tool calls (e.g. reading a note, writing attributes) are not properly displayed because they are not exposed by the ACP server.</li></ul><h2><span class=\"tn-icon tn-brand tn-brand-codex\"></span> OpenAI Codex</h2><aside class=\"admonition note\"><p>This subscription-based provider is still in beta. It is safe to use (won't use additional funds and respects the terms of use), but you might experience small issues. Consider <a class=\"reference-link\" href=\"#root/_help_wy8So3yZZlH9\">Reporting issues</a>.</p></aside><p>OpenAI Codex gives access to the Codex models of your ChatGPT plan (Free, Go, Plus, Pro or Business), without an API key. At the time of writing, a free ChatGPT account is enough to use it. Usage counts against your plan's Codex limits, which are small on the Free plan.</p><div class=\"trilium-tabs\"><section class=\"trilium-tab\"><p class=\"trilium-tab-title\"><span class=\"tn-icon bx bxl-windows\"></span><span class=\"tn-icon bx bxl-tux\"></span><span class=\"tn-icon bx bxl-apple\"></span> Most platforms</p><div class=\"trilium-tab-panel\"><ol><li>Install the Codex CLI on the machine that runs Trilium, for example with <code>npm install -g @openai/codex</code>. As with Claude Code, for a <a class=\"reference-link\" href=\"#root/_help_WOcw2SLH6tbX\">Server Installation</a> it needs to be installed on the server. Trilium ships the ACP adapter that connects to it, so nothing else is needed.</li><li>Go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>AI / LLM</em> and add the <span class=\"tn-icon tn-brand tn-brand-codex\"></span> <em>OpenAI Codex</em> provider. When the list of models is loaded for the first time, the ChatGPT sign-in page opens in a browser on the machine running Trilium; finish signing in there.</li></ol></div></section><section class=\"trilium-tab\"><p class=\"trilium-tab-title\">NixOS</p><div class=\"trilium-tab-panel\"><ol><li><p>On NixOS, Codex is available as the <code>codex</code> package in nixpkgs. The stable channel can lag behind Codex's releases, so a newer version can be taken from <code>nixos-unstable</code>:</p><pre><code class=\"language-text-x-sh\">nix shell github:nixos/nixpkgs/nixos-unstable#codex\ntrilium</code></pre></li><li><p>Go to <a class=\"reference-link\" href=\"#root/_help_4TIF1oA4VQRO\">Options</a> → <em>AI / LLM</em> and add the <span class=\"tn-icon tn-brand tn-brand-codex\"></span> <em>OpenAI Codex</em> provider. When the list of models is loaded for the first time, the ChatGPT sign-in page opens in a browser on the machine running Trilium; finish signing in there.</p></li></ol></div></section></div><p>Trilium keeps its own Codex sign-in and settings, separate from any Codex CLI you use in a terminal, so an existing <code>codex login</code> is not reused.</p><details class=\"trilium-collapsible\"><summary>How Trilium identifies your Codex CLI binary</summary><p>In this order:</p><ul><li>By looking for a <code>TRILIUM_CODEX_PATH</code> environment variable pointing to the Codex binary.</li><li>By looking for <code>codex</code> in your PATH.</li><li>By asking your login shell for its <code>PATH</code>, the same as for Claude Code.</li></ul></details><aside class=\"admonition note\"><p>Trilium needs <code>curl</code> to use OpenAI Codex, the same as for Google Antigravity: Trilium checks every tool call Codex makes through it. It comes with Windows 10 and later, macOS and most Linux distributions.</p></aside><h3>Known limitations</h3><ul><li>The agent can only work with your notes through Trilium's note tools, and search the web when the chat allows it; its own file, shell and other tools are blocked for security reasons.</li><li>The ChatGPT sign-in opens in a browser on the device running Trilium, so it might not be possible to set up the provider while using the web version of a Docker installation. <a class=\"reference-link\" href=\"#root/_help_poXkQfguuA0U\">Desktop Installation</a> should work fine.</li><li>Images and SVGs can be attached to the conversation, PDFs cannot. The LLM should still be able to read PDF notes and attachments via <a class=\"reference-link\" href=\"#root/_help_TiQbQDgP8L5t\">Text Extraction (OCR)</a> when the note tools are enabled.</li></ul>","_help_cRRrdZjgyhNc": "<p>Trilium sends nothing to an AI provider until you send a message. Enabling the integration, adding a provider or opening a chat transmits nothing on its own, the one exception is that listing a provider's models sends your API key to that provider, so the list can be fetched.</p><p>Once you send a message or run the <a class=\"reference-link\" href=\"#root/_help_VRoP0g1uHHc2\">In-editor AI assistant</a>, what leaves your machine depends on the provider you chose and on which context options are enabled.</p><h2>Where your notes go</h2><figure class=\"table\"><table><thead><tr><th>Provider type</th><th>Destination</th></tr></thead><tbody><tr><td>Cloud providers</td><td>The provider's servers (Anthropic, OpenAI, Google, DeepSeek). OpenRouter passes each message on to the lab that runs the chosen model, according to the privacy settings of your OpenRouter account.</td></tr><tr><td>Subscription-based</td><td>The provider's servers, via Claude Code running locally</td></tr><tr><td>Local / self-hosted</td><td>Nothing leaves the machine running the model</td></tr><tr><td>Custom endpoint</td><td>Wherever it was pointed, which may be your own hardware or a hosted service</td></tr></tbody></table></figure><p>This is the reason the provider list is grouped this way, and why Trilium pre-selects nothing: the choice of where your note content is sent is made explicitly by you, before anything is sent.</p><aside class=\"admonition note\"><p>The <a class=\"reference-link\" href=\"#root/_help_VRoP0g1uHHc2\">In-editor AI assistant</a> has a model selection of its own, so it may be answered by a different provider than the one in the chat. The row at the bottom of the assistant's menu always names the one being used.</p></aside><h2>What is actually sent</h2><ul><li><strong>Always, with every message</strong><ul><li>The conversation itself: your messages and the assistant's replies, including earlier turns</li><li>Trilium's system prompt describing how to format answers and use tools.</li></ul></li><li><strong>The current note, only when note context is enabled.</strong><ul><li>In the sidebar chat this is the file icon at the bottom; the dedicated chat note type never sends a current note.</li><li>What travels is a metadata block: the note's ID, title, type, creation and modification dates, its parent IDs, the titles of up to 20 children, up to 20 attributes, and a preview of the content.</li><li>Notes above a size threshold send a size hint instead of the text, and the model must call a tool to read further.</li></ul></li><li><strong>Any note the model asks for, when note access is enabled.</strong><ul><li>Tools let the model search your tree and read notes, attributes and attachments beyond the current one.</li><li>It decides what to fetch, and each call waits for you to allow it, unless the chat's permission mode lets reads or every call run on their own, or you allowed that tool for the chat. The reachable scope is your whole tree, except for notes you exclude (see <em>Excluding notes</em> below).</li></ul></li><li><strong>Attachments and mentions</strong>, when you add them: images, PDFs and text files are sent to the provider, and an <code>@</code> mention makes that note fetchable.</li><li><strong>Your search query</strong>, when web search is enabled, the model's search terms reach the provider's own search infrastructure, or the search provider chosen in the <em>Tools</em> menu (Brave Search, Tavily, Exa, Serper, Perplexity or your SearXNG instance).</li><li><strong>The pages the model reads</strong>, when web search goes through a search provider or a DeepSeek model's built-in search: Trilium fetches each page the model asks for from the site itself, so the site sees a request from the machine running Trilium. The page's text is then sent to the model's provider.</li></ul><h2>The in-editor AI assistant</h2><p>A run of the <a class=\"reference-link\" href=\"#root/_help_VRoP0g1uHHc2\">In-editor AI assistant</a> sends a different set than a chat message. For quick actions, it sends it the moment you pick an action, there is no send button to reconsider at. For the free-form <em>Ask AI</em>, there is a dedicated send button and model selector.</p><ul><li><strong>The passage you selected</strong>, or the paragraph the cursor is in when you pick a quick action without selecting anything.</li><li><strong>Up to 1500 characters of the note on each side of that passage</strong>, as plain text. The assistant is told this is context only and must not be rewritten, but it is sent regardless of whether you selected it: a run on a single sentence still transmits the paragraphs around it.</li><li><strong>Where the note sits</strong>: its title and the titles of its parents, as a breadcrumb.</li><li><strong>Trilium's writing-assistant instructions</strong>, which describe the formatting it may produce.</li><li><strong>Earlier turns of the same exchange</strong>, once you follow up on a response.</li></ul><p>No note metadata block is sent, web search is never enabled, and the assistant has no note tools so it can read nothing beyond the text listed above.</p><h2>Protected notes</h2><p>While your <a href=\"#root/_help_bwg0e8ewQMak\">protected session</a> is locked, protected notes send neither title nor content. <strong>While it is unlocked they are treated like any other note,</strong> a note the model reads through a tool is sent to the provider in full. If you keep sensitive material in protected notes, be aware that unlocking them removes that boundary for the duration of the session.</p><p>The same applies to the <a class=\"reference-link\" href=\"#root/_help_VRoP0g1uHHc2\">In-editor AI assistant</a>: it works on whatever is open in the editor, so running it inside an unlocked protected note sends that note's text like any other.</p><h2>Excluding notes</h2><p>Add the <code>#excludeFromLlm</code> <a href=\"#root/_help_HI6GBBIduIgv\">label</a> to a note to hide it from the AI chat and the <a href=\"#root/_help_KOWBFgsZXJAD\">MCP server</a>. The label covers only that note: the notes below it stay visible unless you make the label <a href=\"#root/_help_bwZpz2ajCEwO\">inheritable</a>, and a child can opt back in with <code>#excludeFromLlm=false</code>.</p><p>A note created from a template inherits all of the template's labels (see <a class=\"reference-link\" href=\"#root/_help_KC1HB96bqqHX\">Templates</a>), so adding <code>#excludeFromLlm</code> to a template hides every note that uses it, not just the template.</p><p>For an excluded note:</p><ul><li>The note tools report it as not found: it is left out of search results, child lists and subtrees, and relations that point to it are not shown.</li><li>The model cannot read, edit, move, clone or rename it, create notes under it, or remove the label. It also cannot delete a note that has an excluded note below it.</li><li>Its metadata is not sent as the current note, even when note context is enabled.</li><li>A visible child does not show it as a parent, and the model cannot move the child out of it.</li></ul><p>Unlike a protected note, an excluded note stays hidden while your protected session is unlocked. The exclusion applies to the note tools only. It is not encryption, and it does not cover:</p><ul><li>Files you attach to a message yourself.</li><li>The <a class=\"reference-link\" href=\"#root/_help_VRoP0g1uHHc2\">In-editor AI assistant</a> when you run it inside the note.</li><li>Text from the note that appears in other notes, such as a link with the note's title.</li><li>What a search query can test. Search never returns an excluded note, but a query can still match a visible note through an excluded one: by its title in the note path, through a relation (<code>~link.title</code>), a parent or child (<code>note.parents.content</code>), or a label the visible note inherits from it. A model that guesses can learn whether an excluded note contains a given word.</li></ul><h2>What you control</h2><ul><li><strong>Which provider</strong>: the single decision that determines whether anything leaves your machine at all.</li><li><strong>Note access</strong>: turn it off in the <span class=\"tn-icon bx bx-shield-quarter\"></span><em>Tools</em> menu at the bottom of the chat, and the model can read nothing beyond what you type.</li><li><strong>The current note:</strong> the file icon in the sidebar chat.</li><li><strong>Notes the AI cannot reach:</strong> the <code>#excludeFromLlm</code> label, see <em>Excluding notes</em> above.</li><li><strong>Web search:</strong> also in the <em>Tools</em> menu.</li><li><strong>Which tool calls ask first:</strong> the <em>Permissions</em> submenu of the <em>Tools</em> menu. <em>Always ask</em> has every call wait for you, reads included. A new chat starts in the mode you picked last, so a chat after one set to <em>Don't ask</em> asks about nothing either. Until you pick a mode, chats start in <em>Ask before changes</em>, where the AI reads and searches your notes without asking.</li><li><strong>The editor assistant</strong>: it has no per-run toggles. What you control is whether you run it, what you select before you do and which model answers.</li></ul><p>With note access and note context both off, the provider receives only the words you typed.</p><h2>Keeping everything local</h2><p>Adding an Ollama or LM Studio provider keeps every message on the machine running the model, and Trilium marks their models as free because no metered API is involved. The trade-off is quality and hardware: a small local model may fail at tool calls that a cloud model handles, so a local setup that misbehaves is worth benchmarking against a cloud provider before reporting it as a bug.</p><h2>Telemetry & security</h2><p>Trilium itself collects no telemetry from the AI integration.</p><p>Your API key is stored in your database, sent only to the provider it belongs to, and is write-only through the options API so that a malevolent <a class=\"reference-link\" href=\"#root/_help_CdNpE2pqjmI6\">Scripting</a> cannot access it. If you have backend or SQL console access enabled, a malevolent script <strong>could potentially exfiltrate your API keys</strong>.</p><p>The built-in MCP server is off by default. When enabled, every request must carry an ETAPI token, which grants the same full read and write access to your notes as the REST API; treat one like a password. On desktop it is reachable only from <code>localhost</code> unless you turn on <a class=\"reference-link\" href=\"#root/_help_swSFivWk6KkA\">Network Access</a>.</p>",diff --git a/docs/User Guide/User Guide/AI.md b/docs/User Guide/User Guide/AI.mdindex ecf296100a..3c08e7a242 100644--- a/docs/User Guide/User Guide/AI.md+++ b/docs/User Guide/User Guide/AI.md@@ -116,9 +116,9 @@ search:SearXNG doesn't use API keys, so leave the API key empty. Fill it in only if your instance sits behind a proxy that requires a token; Trilium sends it as a bearer token in the `Authorization` header.-Whether web search is on is kept per chat; the search source is shared by all chats. A choice the current model can't use stays in the menu, disabled; hover the <span class="tn-icon bx bx-info-circle"></span>icon next to it to see why. Claude Code, GitHub Copilot, Google Antigravity and OpenAI Codex run their own tools, so they can't use a search provider.+Whether web search is on is kept per chat; the search source is shared by all chats. A choice the current model can't use stays in the menu, disabled; hover the <span class="tn-icon bx bx-info-circle"></span> icon next to it to see why. Claude Code, GitHub Copilot, Google Antigravity and OpenAI Codex run their own tools, so they can't use a search provider.-In the chat, a search run through a search provider shows that provider's logo at the start of its line instead of the <span class="tn-icon bx bx-search"></span>magnifier; hover the logo to see the provider's name.+In the chat, a search run through a search provider shows that provider's logo at the start of its line instead of the <span class="tn-icon bx bx-search"></span> magnifier; hover the logo to see the provider's name.With a search provider, the model can also read the pages it finds, or a link you give it, as text: Trilium fetches the page itself and hands the model up to its first 20,000 characters. Addresses on your own machine or network are refused. In the browser version most sites don't allow being read this way, so reading a page there usually fails.@@ -129,7 +129,7 @@ Some models reason before they answer. While the model is thinking, its reasoninHow much a model thinks is set per chat, in one of two ways depending on the model:* Most models have an <span class="tn-icon bx bx-brain"></span>_Extended thinking_ button, next to the <span class="tn-icon bx bx-shield-quarter"></span>_Tools_ button.-* Models that offer several levels of reasoning (DeepSeek V4, OpenRouter models that reason, OpenAI Codex, Antigravity) have a <span class="tn-icon bx bx-brain"></span>reasoning effort dropdown next to the model selector instead. _None_, where offered, turns thinking off; higher levels give better answers to hard questions, but take longer and cost more.+* Models that offer several levels of reasoning (DeepSeek V4, OpenRouter models that reason, OpenAI Codex, Antigravity) have a <span class="tn-icon bx bx-brain"></span> reasoning effort dropdown next to the model selector instead. _None_, where offered, turns thinking off; higher levels give better answers to hard questions, but take longer and cost more.> [!NOTE]> The effort dropdown only appears once Trilium knows the model's levels. For a DeepSeek provider set up with an earlier version of Trilium, edit the provider in the model selection box and press _Save_ once.@@ -166,13 +166,13 @@ Here are a few tools that Trilium provides for the LLM:* Get the content of an attachment.* Skills (see the dedicated section).-Each tool the AI uses appears in the chat as a single line naming the tool and the note or query it worked on; a renamed note shows its previous title struck through, a deleted note its title struck through, a moved note where it was moved from and to, an attribute the AI read, set, added or deleted as a pill (struck through once deleted), an attachment by its title, note and size, and a web page the AI read as a link. A line folds open only when there is something to read inline: the notes a search found, the pages a web search found, the icons an icon search found, the type, attributes or start of the content of a note the AI read, all the attributes of a note, the text of an attachment or of a web page, the User Guide pages the AI looked up or its table of contents (both open in the help panel), the children or the whole subtree of a note, what the AI wrote into a note it created, rewrote or added to, the changes of an edit, or the reason a tool failed. A search names on its line the part of the tree it is confined to, if any, and also shows how many notes it found and how many of the matches the AI asked for; each note it lists opens with a click. To see exactly what the AI sent to a tool and what it got back, hover the line and press the <span class="tn-icon bx bx-code-alt"></span>button next to it; on touch screens the button is always shown.+Each tool the AI uses appears in the chat as a single line naming the tool and the note or query it worked on; a renamed note shows its previous title struck through, a deleted note its title struck through, a moved note where it was moved from and to, an attribute the AI read, set, added or deleted as a pill (struck through once deleted), an attachment by its title, note and size, and a web page the AI read as a link. A line folds open only when there is something to read inline: the notes a search found, the pages a web search found, the icons an icon search found, the type, attributes or start of the content of a note the AI read, all the attributes of a note, the text of an attachment or of a web page, the User Guide pages the AI looked up or its table of contents (both open in the help panel), the children or the whole subtree of a note, what the AI wrote into a note it created, rewrote or added to, the changes of an edit, or the reason a tool failed. A search names on its line the part of the tree it is confined to, if any, and also shows how many notes it found and how many of the matches the AI asked for; each note it lists opens with a click. To see exactly what the AI sent to a tool and what it got back, hover the line and press the <span class="tn-icon bx bx-code-alt"></span> button next to it; on touch screens the button is always shown.When the reply stops moving for a couple of seconds while the AI is still at work, for example while it reads what a tool returned, a _Still working…_ line appears under it until the next part of the reply arrives.#### Approving tool calls-Before the AI runs a tool, the chat asks whether to allow it. The tool's line is marked with a <span class="tn-icon bx bxs-hand"></span>icon and has _Allow_ and _Deny_ buttons below it. When the call would write to a note, the line opens on the text it would write or the changes of an edit. The reply waits until you answer.+Before the AI runs a tool, the chat asks whether to allow it. The tool's line is marked with a <span class="tn-icon bx bxs-hand"></span> icon and has _Allow_ and _Deny_ buttons below it. When the call would write to a note, the line opens on the text it would write or the changes of an edit. The reply waits until you answer.* To let the call run, press _Allow_.* To stop asking about a tool for the rest of the chat, open the menu next to _Allow_ and choose to always allow that tool for this chat. The call runs, and so do the other calls of that tool still waiting and every later one in this chat. Other tools keep asking, and a new chat asks again.@@ -212,7 +212,7 @@ Since Trilium v0.140.0, <a class="reference-link" href="Basic%20Concepts%20and%Not every model reads every kind of attachment: DeepSeek reads no PDFs, and images only with its vision models; OpenAI Codex, GitHub Copilot and Google Antigravity read images but no PDFs. For such a model:* The attach button offers only the kinds the model reads, and a pasted or dropped file it can't read is not attached.-* After switching to such a model, an attachment it can't read is marked with a <span class="tn-icon bx bx-error"></span>warning, and the message can't be sent until the attachment is removed or another model is selected.+* After switching to such a model, an attachment it can't read is marked with a <span class="tn-icon bx bx-error"></span> warning, and the message can't be sent until the attachment is removed or another model is selected.* An attachment sent in an earlier message reaches the model as its name only, such as `[attached file: report.pdf]`, so it can tell you it doesn't see the content.To upload an attachment:diff --git a/docs/User Guide/User Guide/Note Types/Text/Tables.md b/docs/User Guide/User Guide/Note Types/Text/Tables.mdindex 5263724472..bce474063c 100644--- a/docs/User Guide/User Guide/Note Types/Text/Tables.md+++ b/docs/User Guide/User Guide/Note Types/Text/Tables.md@@ -7,7 +7,7 @@ To create a table, simply press the table button and select with the mouse the dSince v0.107.0, the same menu starts with an _Insert table…_ item, for a table larger than the grid or to type its size instead:-1. Click the <span class="tn-icon cke cke-table"></span>button and select _Insert table…_. A small form opens at the cursor.+1. Click the <span class="tn-icon cke cke-table"></span> button and select _Insert table…_. A small form opens at the cursor.2. Enter the number of _Columns_ (up to 100) and _Rows_ (up to 1000). The table can have at most 5000 cells in total, for example 1000 rows of 5 columns.3. Optionally, turn on _Use headers_ and enter the number of _Header columns_ and _Header rows_. A table cannot have more header columns or rows than it has columns or rows.4. Press _Insert_ or <kbd>Enter</kbd>.@@ -48,7 +48,7 @@ Since v0.106.0, right-clicking anywhere inside a table opens a context menu with* _Sort_, below the clipboard section, sorts the rows by the column of the current cell, in _Ascending_ or _Descending_ order. See [Sorting rows](#sorting-rows).* _Delete row_ and _Delete column_, below _Sort_, remove every row or column the selection touches, even when only some of their cells are selected.* _Delete table_ removes the whole table and leaves an empty paragraph in its place. In a table nested inside another, only the inner table is removed.-* Since v0.107.0, _Select_, below _Delete table_, selects the cells of every row (_Row_) or column (_Column_) the selection touches, or every cell of the table (_Table_). Unlike the <span class="tn-icon cke cke-drag-handle"></span>button, which selects the table as a whole, _Table_ selects its cells, so cell operations such as _Merge cells_ apply to all of them. In a table nested inside another, _Table_ selects only the cells of the inner table.+* Since v0.107.0, _Select_, below _Delete table_, selects the cells of every row (_Row_) or column (_Column_) the selection touches, or every cell of the table (_Table_). Unlike the <span class="tn-icon cke cke-drag-handle"></span> button, which selects the table as a whole, _Table_ selects its cells, so cell operations such as _Merge cells_ apply to all of them. In a table nested inside another, _Table_ selects only the cells of the inner table.Right-clicking a cell that is not part of the current selection moves the cursor there first, so the menu always applies to the cell under the pointer.@@ -73,7 +73,7 @@ Right-clicking a cell that is not part of the current selection moves the cursor## Resizing cells* Columns can be resized by hovering the mouse over the border of two adjacent cells and dragging it.-* To give several columns the same width, select cells across them and choose _Distribute columns evenly_ from the <span class="tn-icon cke cke-table-column"></span>button of the formatting toolbar or from the [context menu](#context-menu).+* To give several columns the same width, select cells across them and choose _Distribute columns evenly_ from the <span class="tn-icon cke cke-table-column"></span> button of the formatting toolbar or from the [context menu](#context-menu).* By default, the row height is not adjustable using the mouse, but it can be configured from the cell settings (see below).* To adjust exactly the width (in pixels or percentages) of a cell, select the <span class="tn-icon cke cke-table-cell-properties"></span> button.@@ -139,7 +139,7 @@ Outside of tables, <kbd>Alt</kbd>+<kbd>Left</kbd> and <kbd>Alt</kbd>+<kbd>Right<Since v0.107.0, the rows of a table can be sorted by the values of one column:-* To sort all the rows, place the cursor in any cell of the column to sort by, then select _Sort_ → _Ascending_ or _Descending_ from the [context menu](#context-menu). The same items are in the <span class="tn-icon bx bx-sort-alt-2"></span>button of the formatting toolbar.+* To sort all the rows, place the cursor in any cell of the column to sort by, then select _Sort_ → _Ascending_ or _Descending_ from the [context menu](#context-menu). The same items are in the <span class="tn-icon bx bx-sort-alt-2"></span> button of the formatting toolbar.* To sort only some of the rows, select their cells in the column to sort by, then sort the same way. Sorting is not available while the selection spans more than one column.Header rows always stay at the top of the table and are never sorted. A sort can be undone with <kbd>Ctrl</kbd>+<kbd>Z</kbd>.