check-links

check-links is a skill for Claude Code from ballred/obsidian-claude-pkm. It costs 32 tokens per session (748 once invoked), scanned A, original, MIT.

A read-only checker for an Obsidian vault, a folder of linked notes, that finds wiki-links written like [[Note]] and checks whether the target note exists.

In plain words
What is it for?
Use it to scan Markdown notes for broken wiki-links and report missing target files.
Why use it?
It helps locate links that lead nowhere without changing your notes or requiring extra software.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Part of the vault-template plugin — 13 skills, 4 agents, 3 hooks shipped together

Good fit Use it to scan Markdown notes for broken wiki-links and report missing target files.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ballred/obsidian-claude-pkm/check-links
About the project

Obsidian + Claude Code Accountability System is a personal knowledge-management setup that connects long-term goals with projects, reviews, daily notes, and tasks inside Obsidian. People use it to plan work, track progress, and review whether daily activity supports their goals with help from Claude Code. Its catalogue add-ons implement the system's planning, tracking, and review workflows.

ballred/obsidian-claude-pkm · 1,861 stars · on GitHub

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add ballred/obsidian-claude-pkm --skill check-links
Clone the repo
git clone --depth 1 https://github.com/ballred/obsidian-claude-pkm

Made for: Claude Code.

Or install vault-template, the plugin that ships this one along with the rest of its 13 skills, 4 agents, 3 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for check-links

README.md
[![agentmods](https://agentmods.dev/badge/skills/ballred/obsidian-claude-pkm/check-links/github.svg)](https://agentmods.dev/skills/ballred/obsidian-claude-pkm/check-links)
Your own site
<a href="https://agentmods.dev/skills/ballred/obsidian-claude-pkm/check-links"><img src="https://agentmods.dev/badge/skills/ballred/obsidian-claude-pkm/check-links/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for check-links

Your own site · 80×15
<a href="https://agentmods.dev/skills/ballred/obsidian-claude-pkm/check-links"><img src="https://agentmods.dev/badge/skills/ballred/obsidian-claude-pkm/check-links.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 32 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 748 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00032 $0.00748
Opus 5 $0.00016 $0.00374
Sonnet 5 $0.00006 $0.00150
Haiku 4.5 $0.00003 $0.00075

Measured 11d ago against content hash 391078e7872d, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

check-links scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

vault-template/.claude/skills/check-links/SKILL.md · 109 lines

How it starts

The opening of the file, as written. The whole thing — 109 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Finds broken [[wiki-links]] across your vault by extracting link targets and verifying that each target file exists. Read-only — never modifies files.

Usage

/check-links

Or ask:

  • "Check for broken links in my vault"
  • "Find dead wiki-links"
  • "Are there any broken links?"

How to Execute

Step 1: Extract all wiki-links

Use Grep to find all [[...]] patterns in markdown files:

Grep:
  pattern: "\\[\\[([^\\]|]+)"
  glob: "*.md"
  output_mode: content
  -n: true

This captures the link target (before any | alias). Exclude .claude/ and .obsidian/ directories from results.

Step 2: Build unique target list

From the grep results, extract the unique link targets. For each match like [[My Note]] or [[My Note|display text]], the target is My Note.

Strip:

  • Heading anchors: [[Note#heading]] → target is Note
  • Block references: [[Note^block-id]] → target is Note
  • Aliases: [[Note|alias]] → target is Note

Step 3: Verify each target exists

For each unique target, use Glob to check if a matching file exists:

Glob:
  pattern: "**/<target>.md"

A link is broken if no file matches. A link is valid if at least one file matches.

Step 4: Report results

Group broken links by source file:

## Broken Links Report

### Daily Notes/2024-01-15.md
- [[Projet Alpha]] — no matching file found
- [[Old Goal]] — no matching file found

### Projects/Project Beta.md
- [[Meeting Notes Jan]] — no matching file found

---

**Summary:** 3 broken links across 2 files (out of 45 total links checked)

Step 5: Suggest fixes

For each broken link, try to find a close match:

  1. Use Glob with a partial pattern: **/*<partial-target>*.md
  2. If a similar filename exists, suggest it:
    - [[Projet Alpha]] — Did you mean [[Project Alpha]]?
    
  3. If no close match, just report "no matching file found"

Edge Cases

  • Embedded images (![[image.png]]) — skip these, they reference attachments
  • External links ([text](https://...)) — skip these, they are not wiki-links
  • Template placeholders ([[{{date}}]]) — skip anything with {{ in the target
  • Empty links ([[]]) — report as malformed, not broken

Read the full file on GitHub · 109 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 109 lines · 32 tokens per session scan A 391078e7872d

Subscribe to this mod's changes

check-links is a skill published in the GitHub repository ballred/obsidian-claude-pkm (1,861 stars, last pushed 6mo ago), licensed MIT. It adds 32 tokens to every session and 748 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

wiki-lint

Run a deterministic, read-only health check on an Obsidian wiki. Use for lint, vault health check, audit wiki health, find orphans, find dead links, frontmatter audit, provenance audit, or wiki audit. Reports graph, link, frontmatter, provenance-ledger, empty-section, and stale-index findings; it does not reason…

AgriciDaniel/claude-obsidian · 79 tokens

code-understand

Build a ranked, citation-backed focus map of a codebase — the files and symbols an architecture actually hangs on — using CodeGraph when available and a dependency-free builtin (regex AST extraction + rg cross-file references) otherwise. Use this any time you (the coding agent) need to orient in an unfamiliar or large…

Ar9av/obsidian-wiki · 175 tokens

api-errors

McpError constructor, JsonRpcErrorCode reference, and error handling patterns for @cyanheads/mcp-ts-core. Use when looking up error codes, understanding where errors should be thrown vs. caught, or using ErrorHandler.tryCatch in services.

cyanheads/obsidian-mcp-server · 54 tokens

report-issue-framework

File a bug or feature request against @cyanheads/mcp-ts-core when you hit a framework issue. Use when a builder, utility, context method, or config behaves contrary to the documented API — not for server-specific application bugs.

cyanheads/obsidian-mcp-server · 52 tokens

report-issue-local

File a bug or feature request against this MCP server's own repo. Use for server-specific issues — tool logic, service integrations, config problems, or domain bugs that aren't caused by the framework.

cyanheads/obsidian-mcp-server · 44 tokens

link-health

Use at the start of Link work when readiness is unclear, after installs or upgrades, and before repairs; verify health, inspect interrupted writes, back up, and repair generated indexes without MCP.

gowtham0992/link · 41 tokens