Obsidian Tasks Documentation

repository·main·Indexed 26 days ago

https://github.com/obsidian-tasks-group/obsidian-tasks

A task management plugin for the Obsidian knowledge base (version 8.3.0) that enables tracking, querying, and managing tasks across a vault using Markdown-based syntax. Features include powerful query blocks for filtering, grouping, and sorting tasks, support for due dates and recurring patterns, and advanced CSS styling options for task components and statuses.

Tokens
114.2K
Snippets
369
Records
762
Agent score
84%

What's inside Obsidian Tasks

  1. Overview of Obsidian Tasks

    main

    Obsidian Tasks is a plugin for the Obsidian knowledge base that allows you to track tasks across your entire vault. It provides the ability to query tasks and mark them as done from any view or query, which automatically updates the original source file.

    Key features include:

    • Support for due dates and done dates.
    • Recurring tasks (repetition).
    • Filtering and querying capabilities.
    • Support for a subset of checklist items.
    • Ability to toggle task status directly within query results.
  2. Use scripting capabilities in Tasks queries

    main

    Once JavaScript is enabled, you can use JavaScript expressions within Tasks query blocks to extend the standard query language. The available scripting capabilities include:

    • Custom Filters: Write short JavaScript expressions to create task search filters.
    • Custom Sorting: Write short JavaScript expressions to sort tasks in query results.
    • Custom Grouping: Write short JavaScript expressions to define task group names in query results.
  3. Understand Core Statuses in Obsidian Tasks

    main

    Core statuses represent conventional markdown task syntax. They are natively supported in Tasks blocks and Live Preview without requiring custom CSS.

    By default, the core statuses are:

    • Todo: Represented by [ ] (a space after the bracket).
    • Done: Represented by [x] (an x after the bracket).

    These statuses can be used for filtering, sorting, and grouping in Tasks queries using status.name or status.type.

  4. Understand the rendered Task HTML structure

    main

    Tasks 3.0.0+ renders tasks with a specific nested HTML structure in query results and Reading View. This structure allows for granular CSS styling of individual components like priority, dates, and recurrence rules.

    Key Hierarchy:

    • Container: div.block-language-tasks (the Obsidian code block)
    • Results List: ul.plugin-tasks-query-result (in queries) or ul.contains-task-list (in Reading View)
    • Task Item: li.task-list-item (contains data attributes for priority, due date, status, etc.)
      • Checkbox: li.task-list-item-checkbox
      • Content Wrapper: span.tasks-list-text
        • Components: Various span elements for description, priority, recurrence, and dates (created, start, scheduled, due, cancelled, done).
        • Internal Spans: Each component contains an internal span to allow styling the text content directly (e.g., for highlights or boxes).
  5. Understand Task Statuses in Obsidian Tasks

    main

    Obsidian Tasks recognizes several types of task statuses based on the character used in the markdown checkbox. These include standard Markdown statuses, core Tasks statuses, and custom statuses.

    Standard Markdown statuses

    • [ ]: Todo
    • [x]: Done

    Core Tasks statuses

    • [ ]: Todo
    • [x]: Done
    • [/]: In Progress
    • [-]: Cancelled

    Custom Task statuses

    You can use any character within the brackets to define custom statuses, such as:

    • [X]: Checked
    • [!]: Important
    • [P]: Pro
    • [C]: Con
  6. Explore Obsidian Tasks Getting Started guide

    main

    The Getting Started documentation provides a roadmap for setting up and using the Obsidian Tasks plugin. Key areas covered include:

    • Basics: Installation, initial setup, global filters, and plugin settings.
    • Task Data: How to add dates, priorities, recurring rules, completion actions, custom statuses, and tags to your tasks.
    • Advanced Features: Using task dependencies, querying Obsidian Properties, and searching based on note links.
    • Editing: Techniques for easy task manipulation.
  7. Understand Task Statuses and Custom Statuses

    main

    In Tasks, every task has a Status. A status is defined by the character (symbol) inside the brackets [] at the start of a task line and its associated configuration.

    • Core Statuses: Standard markdown tasks using [ ] (not done) and [x] (done). These work out-of-the-box without extra styling.
    • Custom Statuses: Non-standard characters (e.g., [-], [?], [/]). These require custom CSS or a theme to render correctly in Obsidian, but Tasks allows you to define their behavior (like what happens when they are toggled).
    • Unknown Statuses: If Tasks encounters a symbol it doesn't recognize, it assigns it an Unknown status with a TODO type and sets the next status symbol to x.
  8. Understand Custom Statuses in Obsidian Tasks

    main

    Custom Statuses allow you to use non-standard markdown task characters between the brackets [ ]. This enables you to represent task states beyond simple completion (e.g., 'In Progress', 'Cancelled', or 'Question').

    Examples of custom status syntax:

    • - [X] Checked (Standard)
    • - [-] A dropped/cancelled task
    • - [?] A question
    • - [/] A half done/in-progress task

    Important: Custom statuses require custom CSS styling or a specific theme to display correctly in Tasks blocks or Obsidian's Live Preview. Without styling, they will appear as plain text characters within the brackets.

  9. Understand the Query Assembly Order

    main

    Tasks assembles a query by combining instructions from multiple sources in a specific order. Later instructions (like Layout) can override earlier ones. The assembly order is:

    1. Global Query: Set in the plugin settings. This is discarded if ignore global query is present in any subsequent step.
    2. Query File Defaults: Instructions defined in the note's frontmatter properties.
    3. Query Source: The specific instructions written inside the tasks code block.

    Note: Layout instructions applied at any stage can override previous settings.

  10. Configure Obsidian Tasks settings

    main

    Obsidian Tasks settings are organized by functional area. You can find detailed documentation for each setting category in the following sections:

    • Task Formats: Selecting the task format.
    • Global Filter: Settings for the Global Filter.
    • Global Query: Settings for Global Queries.
    • Status Settings: Overview of status configurations.
    • Dates: Date-tracking settings.
    • Use Filename as Default Date: Settings for using filenames as dates.
    • Recurring Tasks: Recurrence settings.
    • Auto-Suggest: Auto-suggest settings.
    • Create or edit Task modal: Turning off keyboard shortcuts.
    • Search results: Task count location settings.
  11. Understand Status Types in Obsidian Tasks

    main

    Obsidian Tasks uses 'Status Types' to categorize custom statuses. This categorization determines how the plugin handles searching, toggling Done dates, and creating new instances of recurring tasks. There are 6 possible status types:

    • TODO: Tasks not yet started.
    • IN_PROGRESS: Tasks currently being worked on.
    • ON_HOLD: Tasks that are currently unworkable (e.g., awaiting external feedback). Note: Tasks treats ON_HOLD as 'not done' for the purposes of done and not done filters.
    • DONE: Tasks that are completed. This type controls the addition/removal of Done dates and the triggering of recurring task instances.
    • CANCELLED: Tasks that were originally intended but are no longer needed. This prevents them from being misidentified as DONE.
    • NON_TASK: Used for non-task concepts (like Pro/Con lists). Toggling these will never acquire a Done date or create new recurring instances.