Skip to main content
NeVibeCode · collection · 19

Claude Code hooks examples

Ordered by install count from the source, then by repository stars on GitHub. A language model writes each description from the source file; only descriptions that passed the automatic check are listed.

  1. 1

    smart-commit

    A Claude hook that commits the changed file right after Edit or Write. Useful when you would rather not build git history by hand.

    hook · davila7 · MIT

    3,745installs
  2. 2

    update-search-year

    This hook appends the current year to WebSearch queries that lack one. Useful when you want fresh results instead of last year's pages.

    hook · davila7 · MIT

    3,412installs
  3. 3

    lint-on-save

    The hook fires a linter right after the agent changes a file. ESLint, Pylint or RuboCop runs on its own, no manual call needed.

    hook · davila7 · MIT

    3,235installs
  4. 4

    dependency-checker

    A PostToolUse hook that runs a package audit after you touch a dependency file, so outdated or vulnerable packages surface right away.

    hook · davila7 · MIT

    2,314installs
  5. 5

    security-scanner

    This hook runs a security pass whenever Claude edits or writes a file. It looks for vulnerabilities and hardcoded secrets.

    hook · davila7 · MIT

    2,256installs
  6. 6

    nextjs-code-quality-enforcer

    A PostToolUse hook that checks every Next.js file you write: App Router structure, Server and Client Component directives, imports, types. It runs right after an edit.

    hook · davila7 · MIT

    2,249installs
  7. 7

    format-python-files

    This hook runs black on every .py file Claude edits. Formatting stops being a separate step you remember to do.

    hook · davila7 · MIT

    1,405installs
  8. 8

    backup-before-edit

    A Claude hook that copies a file with a timestamp before every edit. Useful when the agent rewrites code and you want a way back.

    hook · davila7 · MIT

    1,328installs
  9. 9

    test-runner

    This hook fires a test command right after Claude edits a file. Handy when you keep forgetting to re-run checks by hand.

    hook · davila7 · MIT

    1,027installs
  10. 10

    performance-budget-guard

    A Claude hook that measures your Next.js JS bundle after a build and blocks the deploy when it goes over the performance budget.

    hook · davila7 · MIT

    393installs
  11. 11

    vercel-environment-sync

    A hook that inspects environment variables after an .env edit and points you to the right Vercel sync commands. Useful when local and deployed values drift apart.

    hook · davila7 · MIT

    363installs
  12. 12

    env-file-protection

    This hook stops Write calls aimed at .env* files, so an agent cannot overwrite your secrets by accident. One command adds it to Claude settings.

    hook · davila7 · MIT

    279installs
  13. 13

    slack-notifications

    Posts a Slack message when Claude finishes working or a subagent completes its task. Useful when you step away from the terminal and want to know the run is done.

    hook · davila7 · MIT

    279installs
  14. 14

    discord-notifications

    Posts a Discord message when Claude stops working or a subagent finishes. Useful when you step away from the terminal and want a ping on completion.

    hook · davila7 · MIT

    217installs
  15. 15

    tdd-gate

    The hook blocks edits to production files until a matching test exists. Useful if you want the agent to keep the TDD order.

    hook · davila7 · MIT

    192installs
  16. 16

    debug-window

    Opens a live-tailing debug log window when Claude starts with --debug or -d, then closes it when the session ends.

    hook · davila7 · MIT

    189installs
  17. 17

    change-logger

    This hook writes each file mutation to a CSV: timestamp, tool, path, action and details. Handy when you are prepping a demo and need to show what the agent touched.

    hook · davila7 · MIT

    163installs
  18. 18

    secrets-scanner official

    Scans the files a Copilot coding agent touched during a session for leaked keys and credentials before they get committed. Useful when the agent edits code fast.

    hook · github · MIT

    ★ 40,418repo stars
  19. 19

    dependency-license-checker official

    A GitHub Copilot hook that scans newly added dependencies at session end and flags copyleft licenses before they get committed.

    hook · github · MIT

    ★ 40,418repo stars

Other collections

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor