Claude Code Plugin Security: Vet a Plugin Before You Install It

David IyaDavid Iya November 25, 2026 9 min read
An open antique wooden toolbox full of hand tools on a dark wooden bench, with a brass padlock and a jeweler's loupe on a folded sheet of paper beside a coil of copper wire
Original image, Claude Code Club

What Claude Code plugin security comes down to

Claude Code plugin security comes down to one fact: a plugin you install can execute arbitrary code on your machine with your user privileges. Some of that code runs without Claude ever making a tool call, so your permission rules and the sandbox never see it. The fix is not to avoid plugins. It is to review each one before you install it, control when it updates, and know how to remove it completely.

Most people treat a plugin install like adding a browser bookmark. It is closer to adding a dependency to production. I review a plugin from a marketplace I do not know the same way I would review a new package with a postinstall script, and the check takes about as long as reading the files involved.

What a plugin can run on your machine

A plugin carries two kinds of content: things that run as code, and things that enter Claude's context as instructions. The table splits them by whether your permission rules and sandbox apply.

Plugin components and whether permissions or the sandbox cover them

ComponentWhat it doesCovered by permission rules or sandbox?
HooksShell commands that run at points in Claude Code's lifecycle, such as before or after a tool callNo. Command hooks run with your full user permissions, outside the sandbox
MonitorsBackground shell commands Claude Code starts on its own at session start, when you reload plugins, or the first time a named skill runsNo. They run with your full user permissions, outside the sandbox
ModsJavaScript that runs inside Claude Code with your permissionsNo. Review a mod on its own before you install it
MCP and LSP serversProcesses Claude Code starts on your machine for a stdio MCP server or a language serverThe processes run outside the sandbox. Claude's calls to the plugin's MCP tools are tool calls, so permission rules apply to those
bin/ directoryAdded to the PATH of the Bash tool's shell, so Claude's Bash commands can run anything in itYes. Running one of these executables is a Bash tool call, so permission rules apply
Skills, commands and agentsInstructions that enter Claude's contextThey run nothing themselves, but they shape what Claude does with the tools it already has

The first two rows are the ones that matter. A hook that runs before every tool call, or a monitor that starts when your session opens, never asks for permission. If it reads a file or sends something over the network, nothing in your Claude Code settings stops it.

Which plugin marketplaces are Anthropic's

A marketplace's name puts it in one of three tiers. Claude Code only accepts the official and community names for marketplaces sourced from github.com/anthropics/ repositories.

Marketplace tiers

TierWhich marketplacesWhat that tells you
OfficialReserved names such as claude-plugins-officialAnthropic runs the catalog. It lists plugins Anthropic maintains plus plugins from partners and other authors
Communityclaude-community, claude-plugins-community and healthcareThird-party plugins their authors submitted to Anthropic. Nearly every entry is pinned to a commit SHA, and Claude Code refuses to install a different commit
Third-partyEvery other marketplace, including one a coworker or your own company publishesAnthropic does not review it

Two guardrails are built in. If a marketplace uses an official or community name but its source sits outside github.com/anthropics/, Claude Code stops loading it with the error Marketplace is registered from an untrusted source. And if a marketplace entry pins an archive source to a sha256 digest that the download does not match, the install fails with Plugin archive integrity check failed.

Neither guardrail tells you what a plugin does. The official marketplace is mostly plugins from partners and other authors, and the trust warning you see before installing reads the same whatever marketplace the plugin comes from. A trusted catalog name is a reason to review faster, not a reason to skip the review.

The CCC Plugin Trust Check: four steps before you install

This is the check I run on any plugin I have not used before. Steps 1 and 4 run in a terminal. Step 2 runs in a Claude Code session. If you live in the desktop app, that is fine: a plugin you install at user scope in the desktop app, the terminal or the VS Code extension is available in the other two, because they read the same settings files.

  • Check the marketplace's source. Run claude plugin marketplace list to print where each marketplace was added from, such as a GitHub repository or a local directory. If you do not recognize the source, stop here.
  • Read the details pane. Run /plugin and select the plugin. The Will install section lists its commands, agents, skills, hooks, and MCP and LSP servers. For a plugin fetched from elsewhere you may see Component summary not available for remote plugin, which means you have to read the source yourself.
  • Read the files that run code. Use Open homepage or View on GitHub in the pane, or open the marketplace repository from step 1. The pane shows that a hook exists but not what it runs, so read hooks/hooks.json for each hook's command, .mcp.json for each server's command or URL, and every file in bin/.
  • Print the inventory. Clone the repository and run claude --plugin-dir <plugin directory> plugin details <plugin name>. It reads the plugin's files without starting a session and prints a Component inventory of skills, commands, agents, hooks with their events, and MCP and LSP servers. Compare it with what the pane showed.

In step 3, here is what makes me stop and ask questions: a hook command that makes a network request, a hook that reads files outside the project such as anything under ~/.ssh, an MCP server started from a package with no version pinned, and a bin/ file I cannot read because it is a compiled binary with no source next to it. None of those is proof of anything bad. Each one is a question I want answered before the plugin runs with my user privileges.

Control updates so the plugin you reviewed stays the plugin you run

Your review covers one version. When auto-update is on for the marketplace you installed from, Claude Code updates the plugin in the background, and the files you read can change on disk.

Auto-update defaults by marketplace

MarketplaceAuto-update default
claude-plugins-official and the other official names, except knowledge-work-plugins and first-party-pluginsOn
Marketplaces added from claude.aiOn
The community marketplace, third-party marketplaces and local development marketplacesOff
  • Turn auto-update on or off per marketplace in /plugin, on the Marketplaces tab. Select the marketplace and toggle it.
  • Pin a third-party marketplace to a tag when you add it, for example /plugin marketplace add your-org/plugins#v1.2.0. Add #ref to pin a branch or tag.
  • Update one plugin on purpose with claude plugin update <plugin>@<marketplace>, and run step 3 and step 4 of the check on the new version first.
  • When you see Plugin updated: <name> · Run /reload-plugins to apply, the new version loads on your next launch even if you do not reload.

My default: leave auto-update on for the official marketplace, leave it off for everything else, and update third-party plugins by hand after a quick diff. If a plugin author is someone you would not hand your laptop to, do not let their next commit install itself.

Remove a plugin you no longer trust

Uninstalling is not quite the same as removing every trace. Run claude plugin uninstall <plugin> with the --scope you installed it at, then check three things.

  • Persistent data. When that was the last scope the plugin was installed at, uninstall also deletes the plugin's persistent data directory by default. The --keep-data flag keeps it.
  • Cached files. The plugin's files stay under ~/.claude/plugins/cache/ for 14 days before a background sweep removes them. To delete them now, remove ~/.claude/plugins/cache/<marketplace>/<plugin>/ yourself.
  • The marketplace. If you do not trust the owner either, remove the marketplace too. That uninstalls every plugin you installed from it.

Make plugin review a team rule

One careful developer does not protect a team. If your company uses Claude Code, put the check behind managed settings so nobody has to remember it.

  • Allowlist or blocklist marketplace sources, so plugins can only come from catalogs you have reviewed.
  • Force-enable the plugins everyone needs, so people are not shopping for alternatives.
  • Turn off the --plugin-dir and --plugin-url flags and the CLAUDE_CODE_PLUGIN_DIRS variable, which close the side door around your allowlist.
  • Limit hooks to those from managed settings and force-enabled plugins.
  • Stop plugins from members' claude.ai accounts loading in Claude Code with syncClaudeAiPlugins.
  • Set pluginTrustMessage to append your own line to the trust warning, such as who to ask before installing anything new.

The setup for each of these is in Claude Code managed plugins. If you run your own catalog, the private plugin marketplace post covers hosting and updates. Keep in mind that plugin evals measure whether a plugin helps, not whether it is safe, and pointing an eval at a plugin is the same trust decision as loading it.

Free Claude Code drops, straight to your inbox

Short, practical drops on skills, MCP, agents, prompts, and more. No spam, unsubscribe anytime.

Frequently asked questions

Are Claude Code plugins safe?

A plugin can execute arbitrary code on your machine with your user privileges, so it is as safe as the code inside it. Review its hooks, MCP servers and bin/ files before you install it, whichever marketplace it comes from.

Does the Claude Code sandbox protect me from a plugin?

Not fully. Hooks, monitors, MCP servers and language servers run outside the sandbox with your user permissions. Permission rules do apply to Claude's tool calls, such as calls to a plugin's MCP tools or Bash commands that run files from the plugin's bin/ directory.

Does Anthropic review plugins in the official marketplace?

The official marketplace is an Anthropic-run catalog, but most of what it lists comes from partners and other authors. Anthropic does not review third-party marketplaces at all. The trust warning before install is the same for every marketplace, so review the plugin either way.

How do I see what a Claude Code plugin will install?

Run /plugin and select the plugin to read its Will install section. For the full picture, run claude --plugin-dir <plugin directory> plugin details <plugin name> on a clone of its repository, which prints a Component inventory including each hook's event.

Do Claude Code plugins update automatically?

Only when auto-update is on for the marketplace. It is on by default for the official marketplace names, except knowledge-work-plugins and first-party-plugins, and for marketplaces added from claude.ai. It is off by default for community and third-party marketplaces.

How do I completely remove a Claude Code plugin?

Run claude plugin uninstall <plugin> with the scope you installed it at. Its cached files stay under ~/.claude/plugins/cache/ for 14 days, so delete that folder yourself if you want them gone now, and remove the marketplace if you do not trust its owner.

Last reviewed by David Iya on November 25, 2026

David Iya

Written by

David Iya

Forbes 30 Under 30 · Y Combinator

Keep reading

Claude CodePlugins

Claude Code Plugin Output Styles: Ship a Style With Your Plugin

Claude Code plugin output styles let a plugin ship its own response style: a Markdown file in output-styles/ that shows up in /output-style as plugin:name. Here is the file format, the force-for-plugin flag that applies a style automatically, the keep-coding-instructions trap, and the manifest rules that silently drop styles.

David Iya 8 min
Read article
Claude CodePlugins

Claude Code Plugin Monitors: Background Watchers That Notify Claude

Claude Code plugin monitors are shell commands a plugin starts in the background for the whole session, and whatever they print reaches Claude as notifications. Here is the monitors.json schema, the when trigger, why path variables are substituted but not exported, how to keep state in CLAUDE_PLUGIN_DATA, and the limits that catch people.

David Iya 9 min
Read article

Ready to build it yourself?

Join Claude Code Club, the #1 community for learning claude code, for $9/month.

← Back to the blog