10 Trilium Notes Tips to Supercharge Your Workflow

Advanced Trilium Notes Features You’re Not Using YetTrilium Notes is a powerful hierarchical note-taking app that blends structured knowledge management with flexibility for freeform writing. Many users rely on its core features—hierarchical trees, note types, and basic scripting—yet Trilium hides deeper capabilities that can drastically improve productivity, organization, and automation. This article explores advanced features you may not be using and gives practical examples for getting more out of Trilium.


1. Dynamic Templates and Template Variables

Templates in Trilium are more than static boilerplate—when combined with template variables and scripting, they can generate complex, context-aware notes.

  • Use template variables like {{title}}, {{date}}, {{id}} to auto-fill metadata.
  • Create templates with embedded JavaScript for dynamic content:
    • Example: generate a unique task ID, compute dates (e.g., next meeting date), or populate a task checklist based on note context.
  • Insert child notes automatically using template commands to scaffold project structures (e.g., create subnotes for Agenda, Meeting Notes, Tasks).

Practical use: Create a Project template that, when instantiated, generates child notes for Goals, Timeline, Tasks, and Resources with predefined note types and tags.


2. Advanced Note Types and Dedicated Fields

Note types and dedicated fields allow you to structure data inside notes beyond plain text.

  • Define custom note types with fields (text, number, boolean, date). These fields are searchable and can be used for filtering and views.
  • Use inner note fields to store structured metadata like priority, status, estimated time, or links to external resources.
  • Combine note types with templates to ensure consistent data entry across many notes.

Practical use: Implement a “Paper” note type for research management with fields for authors, publication date, DOI, and summary, enabling quick filtering and bibliography exports.


3. Attribute Inheritance and Propagation

One subtle but powerful feature is attribute inheritance across the note hierarchy.

  • Parent notes can define attributes that child notes inherit, which you can override on a per-note basis.
  • Use inheritance for default tags, access control settings, or repeating metadata (e.g., project code or client name).
  • This reduces duplication and enforces consistency across related notes.

Practical use: Put a “client: AcmeCo” attribute on a project parent note so all meeting notes and tasks under it automatically carry that attribute for easy filtering.


4. Scripting with Trilium’s JavaScript API

Trilium includes a JavaScript API usable in automation scripts, custom actions, and scheduled tasks.

  • Automate note creation, modification, and complex searches.
  • Create custom actions that appear in the note action menu to run functions tailored to your workflow—like batch-updating statuses or generating weekly summaries.
  • Scheduled scripts let you run maintenance tasks: clear outdated notes, generate reports, or sync with external services.

Example script ideas:

  • Auto-archive completed tasks older than 90 days.
  • Generate a weekly “review” note that aggregates todos, flagged items, and recently updated pages.

5. Custom Views and Advanced Searches

Beyond simple searches, Trilium supports complex queries and custom views that can act like dashboards.

  • Use advanced search syntax to combine note fields, attributes, tags, types, and full-text matches.
  • Create saved searches and pin them to your sidebar for quick access.
  • Build custom views that display search results in a tailored way—useful for kanban-like task boards or reading lists.

Practical use: A saved search for “type:Task AND status:open AND due:<7d” gives a near-term task list, which you can place in a dashboard note.


6. Automation with Webhooks and External Integrations

Trilium can communicate with other apps via webhooks and by using its scripting API to call external APIs.

  • Create scripts that send data to a webhook (e.g., notify a chat channel when a high-priority task is created).
  • Use scheduled sync scripts to push or pull data from services like Google Calendar, Git, or a personal web server.
  • With the right scripts you can implement two-way sync for specific use-cases (export notes to markdown, import updates back).

Practical use: Sync Trilium tasks with Google Tasks for cross-device reminders, or push finalised meeting notes to a team wiki.


7. Templates + Code Blocks: Reusable Code/Query Snippets

If you store code snippets, queries, or frequently used blocks of text in Trilium, leverage templated code blocks to insert them quickly.

  • Keep a library of code templates and snippet notes with fields for customizable parameters.
  • Use dedicated fields to store language metadata so the editor applies proper syntax highlighting.
  • Combine with actions to paste snippets into the current note or create new notes from them.

Practical use: A “snippet” repository for SQL queries where you can insert a parameterized query into a report note and run minor edits.


8. Multi-edit and Batch Operations

When dealing with large sets of notes, manual edits are tedious. Advanced users employ batch operations.

  • Use scripting to change attributes across many notes, move notes between parents, or convert note types.
  • Search results can be used as input to scripts for targeted batch changes.
  • Scheduled cleanup scripts keep the database consistent (normalize tags, remove broken links).

Practical use: Batch-convert all notes with a legacy type “todo-old” into the modern “Task” type, migrating fields as needed.


9. Encryption and Access Controls

For sensitive content, Trilium supports encryption and per-note access settings.

  • Encrypt individual notes with a passphrase. Only encrypted notes will require the passphrase to view.
  • Use access rights to limit visibility in multi-user or shared setups.
  • Combine encryption with inheritance so all children of a secure parent inherit a security posture.

Practical use: Store passwords, personal identifiers, or confidential client data in encrypted notes and keep metadata in plain text for indexing.


10. Backups, Exports, and Versioning

Protecting your knowledge base is critical. Trilium offers multiple ways to back up and export.

  • Regular database backups via exported JSON (includes note tree, fields, and history).
  • Export notes to Markdown or HTML for portability.
  • Use revision history to restore previous versions of a note when needed.

Practical use: Schedule weekly exports to a cloud storage or git repo to keep incremental backups and enable diffs over time.


Putting It Together: Example Workflow

  1. Create a Project template that generates child notes (Goals, Roadmap, Tasks).
  2. Use custom note types for Task and Paper with structured fields.
  3. Add inheritance on the Project parent for client and default tags.
  4. Create scheduled scripts: weekly review generation and auto-archiving.
  5. Build a dashboard note with saved searches for “Due this week”, “High priority”, and “Recently updated.”

This pipeline turns Trilium from a note repository into a lightweight, automated PKM (personal knowledge management) system.


If you want, I can: provide ready-to-import templates, write sample automation scripts for specific tasks (e.g., weekly review, auto-archive), or build example saved searches and note type definitions you can paste into Trilium. Which would you like?

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *