obsidian-cli
Original:🇺🇸 English
Translated
3 scripts
Install, enable, and operate Obsidian CLI for terminal-driven note automation against a running Obsidian app. Use when you need to run Obsidian commands from a shell or TUI, target a specific vault or file, automate daily notes, search, tags, tasks, or file operations, use developer commands such as plugin reload and screenshots, or launch `obsidian://` URIs with callback parameters. Triggers on: obsidian cli, obsidian command line, obsidian uri, obsidian daily note command, obsidian plugin reload cli, obsidian dev screenshot, obsidian vault command.
6installs
Sourceakillness/oh-my-skills
Added on
NPX Install
npx skill4agent add akillness/oh-my-skills obsidian-cliTags
Translated version includes tags in frontmatterSKILL.md Content
View Translation Comparison →obsidian-cli - Control Obsidian from the Terminal
Keyword:·obsidian cli·obsidian uri·obsidian daily note commandobsidian plugin reload cliUse this skill for the official desktop CLI. If the user needs sync without the desktop app, that is Obsidian Headless, not this skill.
Obsidian CLI is the official command line interface for controlling a running Obsidian app from the terminal. It supports single commands, an interactive TUI, vault and file targeting, note operations, search, tags, tasks, and developer commands. Official docs also link it closely with the URI protocol for cross-app automation.
obsidian://When to use this skill
- Enable and verify the official Obsidian CLI registration
- Run one-shot commands such as ,
obsidian help,obsidian daily, orobsidian readobsidian search - Open the interactive TUI with autocomplete and history
- Target a specific vault with or
vault=<name>vault=<id> - Target a specific note with or
file=<name>path=<path> - Copy command output with
--copy - Use developer commands for plugin and theme work such as ,
devtools,plugin:reload, anddev:screenshoteval - Launch or generate URIs for open, new, daily, unique, search, and callback-based workflows
obsidian://
Instructions
Step 1: Enable and verify the CLI
Use the official app flow first:
- Upgrade to the installer and early access versions required by the docs
- In Obsidian, go to
Settings -> General - Enable
Command line interface - Follow the prompt to register the CLI
Run the local helper:
bash
bash scripts/install.shWhat to remember:
- The docs currently say CLI usage requires the Obsidian installer
1.12 - The same page also says to upgrade to the latest installer and the latest early access
1.11.71.12.x - The app must be running, or the first CLI command launches it
- Linux packaging may need extra symlink or PATH work
Treat those version strings exactly as current official docs, not as inferred packaging logic.
Step 2: Choose single-command mode or the TUI
Run a single command:
bash
obsidian helpOpen the terminal interface:
bash
obsidian
helpUse the TUI when the user wants autocomplete, command history, and reverse search. Use single-command mode for scripts, automation, and shell aliases.
Step 3: Target the right vault and file
Vault targeting rules:
- If the current working directory is a vault, that vault is used by default
- Otherwise, the active vault is used
- or
vault=<name>must be the first parameter before the commandvault=<id>
Examples:
bash
obsidian vault=Notes daily
obsidian vault="My Vault" search query="meeting notes"File targeting rules:
- uses wikilink-style resolution by file name
file=<name> - requires the exact path from the vault root
path=<path> - If neither is provided, many commands default to the active file
Examples:
bash
obsidian read file=Recipe
obsidian read path="Templates/Recipe.md"Move the targeting details into references/vault-and-file-targeting.md.
Step 4: Use the command families that match the job
Start with the everyday commands:
dailydaily:appendsearchreadcreatetagstasksdiff
General commands:
helpversionreloadrestart
Developer-oriented commands:
devtoolsplugin:reloaddev:screenshoteval
These developer commands are especially useful for plugin and theme workflows because the docs explicitly position them for automatic testing and debugging.
See references/commands-and-developer-tools.md for a compact command map.
Step 5: Use flags and output features deliberately
Parameter rules:
- Parameters use
name=value - Wrap values with spaces in quotes
- Boolean switches are bare flags such as or
openoverwrite - Use for newlines and
\nfor tabs in content strings\t
Examples:
bash
obsidian create
obsidian create name=Note content="Hello world"
obsidian create name=Note content="Hello" open overwrite
obsidian create name=Note content="# Title\n\nBody text"Output helper:
bash
obsidian read --copy
obsidian search query="TODO" --copyMany listing commands also expose parameters such as , , , , or .
format=jsontsvcsvmdpathsStep 6: Use obsidian://
URI workflows for external automation
obsidian://The official URI actions include:
opennewdailyuniquesearchchoose-vault
Examples:
text
obsidian://open?vault=my%20vault&file=my%20note
obsidian://new?vault=my%20vault&name=my%20note
obsidian://daily?vault=my%20vault
obsidian://search?vault=my%20vault&query=ObsidianImportant URI rules:
- Encode values properly, especially spaces and
/ - overrides
path=andvaultfile - controls opening location
paneType=tab|split|window - is desktop-only
paneType=window - and
x-successsupport callback flows on supported endpointsx-error
Use references/uri-and-callbacks.md for the URI-specific behavior and Hook integration notes.
Step 7: Respect the limitations
- CLI automation is for the desktop app, not headless sync
- requires the Daily notes plugin to be enabled
daily - requires the Unique note creator plugin to be enabled
unique - Linux registration may require manual symlinks, PATH updates, or packaging-specific fixes
- Developer commands can change app or plugin state, so use them intentionally
Examples
Example 1: Verify CLI registration
bash
bash scripts/install.shExample 2: Open the TUI
bash
bash scripts/run-command.shExample 3: Open today's daily note
bash
bash scripts/run-command.sh dailyExample 4: Append a task to today's daily note
bash
bash scripts/run-command.sh daily:append content="- [ ] Buy groceries"Example 5: Search a specific vault
bash
bash scripts/run-command.sh vault="My Vault" search query="meeting notes"Example 6: Read a file by name or exact path
bash
bash scripts/run-command.sh read file=Recipe
bash scripts/run-command.sh read path="Templates/Recipe.md" --copyExample 7: Reload a plugin you are developing
bash
bash scripts/run-command.sh plugin:reload id=my-pluginExample 8: Take a screenshot from the app
bash
bash scripts/run-command.sh dev:screenshot path=screenshot.pngExample 9: Open a note via URI
bash
bash scripts/open-uri.sh 'obsidian://open?vault=my%20vault&file=my%20note'Best practices
- Start with or the TUI before assuming a command family name.
obsidian help - Put first when you need deterministic multi-vault automation.
vault= - Prefer when duplicate file names make wikilink-style
path=resolution ambiguous.file= - Use when the result needs to feed another tool or model without extra shell parsing.
--copy - Treat developer commands like ,
plugin:reload, andevalas operational tools, not casual shortcuts.dev:screenshot - Keep CLI automation separate from Headless Sync workflows; they solve different problems.
- URI values must be encoded correctly or the action may be misinterpreted.
- On Linux, check registration, symlinks, and before assuming the CLI is broken.
PATH
References
- references/installation-and-troubleshooting.md
- references/vault-and-file-targeting.md
- references/commands-and-developer-tools.md
- references/uri-and-callbacks.md
- scripts/install.sh
- scripts/run-command.sh
- scripts/open-uri.sh
- Obsidian CLI
- Obsidian URI