Trilium natively supports the following formats for both import and export.

## Supported formats

- HTML:
  - This is the main format used by Trilium, where standard tags are used to represent basic formatting and layout (e.g. `<strong>`, `<table>`, `<pre>`).
  - Note that HTML is not a standardized format so some more specific features such as admonitions or Internal (reference) links might not be supported by other applications.
  - The notes can also be exported as static HTML that can be used for web publishing.
- Markdown
  - Most of the formatting is preserved, see Supported syntax.
- OPML (Outliner Interchange Format)
  - Supports both OPML v1.0 for plain text and v2.0 with HTML support.

To import from other applications such as OneNote, Notion and others, see Importing data from other applications.

## Maximum import size

Versions prior to v0.104.0 had an upload limit of 250 MiB that could be bypassed via a `TRILIUM_NO_UPLOAD_LIMIT` environment variable; with v0.104.0 this limit was removed.

Nevertheless, there is still a limit for the maximum size of a single item (whether it's a File, an Attachments or even a Text note). The limit is approximately 374 MiB and it's determined by the Synchronization protocol. Attempts to import such large files will be refused.

During large imports or exports, memory consumption might spike but it will remain somewhere around the 2 gigabyte mark. Tested with a 2.4 GB database with ~21k notes.

For the Desktop Installation, there are two distinct import mechanisms:

- A quick import, from the Note Tree.
- The import dialog (via right click in the note tree → Import into note or from Note buttons).

When dealing with large files (multi-gigabyte), prefer using the import dialog as it has a special mechanism which makes sure that the file is read directly from disk rather than uploaded again.

## Exporting the root note

The root note is the top-most note. Exporting it behaves just like any other note: right click on it in the Note Tree and select Export.

Starting with v0.104.0, when a root note is imported, it will be imported as a child of your existing root note. This behavior makes sure that the import cannot change or overwrite your existing notes.

You can easily move the notes onto the root using the tree's Multiple selection and delete the redundant root note.

Before | After
--- | ---
root one two | root (existing) root (from import) one two

Instead of exporting full ZIPs (including the root note), consider using backupsinstead. Backups always contain the entire structure, as well as additional information a ZIP export does not have: maintains note IDs, contains the options/tokens and handle Protected Notes better.