Npm
npm package publishing, versioning, auditing and install tools for MCP clients
Npm is an open-source MCP server for developer tools. It runs locally on your machine and is started by your AI client.
- Pricing
- Open source
- Platforms
- Self-hosted, CLI
- Runs
- Locally
- What it can do
- Can delete data (1 tool)
- Version
- 1.4.0
- Listing updated
Similar MCP servers
Install
You install MCP servers on a computer. Send yourself the link.
Add with the CLI
Run in a terminal
claude mcp add npm --env NPM_TOKEN='<NPM_TOKEN>' -- npx -y @mikusnuz/npm-mcpAdd --scope user to use it in every project, or --scope project to share it in .mcp.json.
Or share it with your project
Add to .mcp.json
{
"mcpServers": {
"npm": {
"command": "npx",
"args": [
"-y",
"@mikusnuz/npm-mcp"
],
"env": {
"NPM_TOKEN": "<NPM_TOKEN>"
}
}
}
}Add to claude_desktop_config.json
{
"mcpServers": {
"npm": {
"command": "npx",
"args": [
"-y",
"@mikusnuz/npm-mcp"
],
"env": {
"NPM_TOKEN": "<NPM_TOKEN>"
}
}
}
}Settings → Developer → Edit Config, then quit and reopen Claude Desktop.
Add to ~/.cursor/mcp.json
{
"mcpServers": {
"npm": {
"command": "npx",
"args": [
"-y",
"@mikusnuz/npm-mcp"
],
"env": {
"NPM_TOKEN": "<NPM_TOKEN>"
}
}
}
}Use .cursor/mcp.json in a project to share it with the project.
Add to ~/.copilot/mcp-config.json
{
"mcpServers": {
"npm": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@mikusnuz/npm-mcp"
],
"env": {
"NPM_TOKEN": "<NPM_TOKEN>"
}
}
}
}Or put the same entry in .mcp.json at your workspace root to share it.
Add with the CLI
Run in a terminal
codex mcp add npm --env NPM_TOKEN='<NPM_TOKEN>' -- npx -y @mikusnuz/npm-mcpOr add to config.toml
Add to ~/.codex/config.toml
[mcp_servers.npm]
command = "npx"
args = ["-y", "@mikusnuz/npm-mcp"]
env = { NPM_TOKEN = "<NPM_TOKEN>" }Add to your client's MCP settings (most use this shape)
{
"mcpServers": {
"npm": {
"command": "npx",
"args": [
"-y",
"@mikusnuz/npm-mcp"
],
"env": {
"NPM_TOKEN": "<NPM_TOKEN>"
}
}
}
}Gemini CLI and Antigravity
Gemini CLI
Add to ~/.gemini/settings.json
{ "mcpServers": { "npm": { "command": "npx", "args": [ "-y", "@mikusnuz/npm-mcp" ], "env": { "NPM_TOKEN": "<NPM_TOKEN>" } } } }Or run: gemini mcp add -s user -e NPM_TOKEN='<NPM_TOKEN>' npm npx -- -y @mikusnuz/npm-mcp
Antigravity
Add to ~/.gemini/config/mcp_config.json
{ "mcpServers": { "npm": { "command": "npx", "args": [ "-y", "@mikusnuz/npm-mcp" ], "env": { "NPM_TOKEN": "<NPM_TOKEN>" } } } }Use .agents/mcp_config.json to add it to one workspace only.
Devin Desktop (formerly Windsurf)
Add to ~/.config/devin/mcp_config.json
{ "mcpServers": { "npm": { "command": "npx", "args": [ "-y", "@mikusnuz/npm-mcp" ], "env": { "NPM_TOKEN": "<NPM_TOKEN>" } } } }On Windows the file is %APPDATA%\devin\mcp_config.json. Use .devin/mcp_config.json to share it with a project.
Cline
Add to cline_mcp_settings.json
{ "mcpServers": { "npm": { "command": "npx", "args": [ "-y", "@mikusnuz/npm-mcp" ], "env": { "NPM_TOKEN": "<NPM_TOKEN>" } } } }Open it from the MCP Servers icon → Configure → Configure MCP Servers.
Zed
Add to Zed settings.json
{ "context_servers": { "npm": { "command": "npx", "args": [ "-y", "@mikusnuz/npm-mcp" ], "env": { "NPM_TOKEN": "<NPM_TOKEN>" } } } }Open it with zed: open settings file. Merge context_servers into the settings you already have.
JetBrains AI Assistant and Junie
AI Assistant
Add to Settings → Tools → AI Assistant → Model Context Protocol (MCP) → Add
{ "mcpServers": { "npm": { "command": "npx", "args": [ "-y", "@mikusnuz/npm-mcp" ], "env": { "NPM_TOKEN": "<NPM_TOKEN>" } } } }The AI Assistant docs only show command and args. If the env block is ignored, use Junie for this server.
Junie
Add to ~/.junie/mcp/mcp.json
{ "mcpServers": { "npm": { "command": "npx", "args": [ "-y", "@mikusnuz/npm-mcp" ], "env": { "NPM_TOKEN": "<NPM_TOKEN>" } } } }Use .junie/mcp/mcp.json to share it with a project.
Kiro
Add to ~/.kiro/settings/mcp.json
{ "mcpServers": { "npm": { "command": "npx", "args": [ "-y", "@mikusnuz/npm-mcp" ], "env": { "NPM_TOKEN": "<NPM_TOKEN>" } } } }Use .kiro/settings/mcp.json to add it to one workspace only.
Using several servers? Build one config file with the MCP config generator.
Configuration
NPM_TOKENnpm granular access token; stage-only tokens use the stage tool
About Npm
This server wraps the npm command line so an assistant can run package chores without leaving the conversation. The README groups roughly 40 tools into publishing and versioning, package info, dependency management, security and diagnostics, configuration and auth, and project setup.
It includes a staged publishing flow: a stage tool can publish a version to a staging area, then list, view, download, approve or reject it, with approval needing maintainer 2FA. That needs npm CLI 11.15.0 or later and Node.js 22.14.0 or later. For npm 12 it also has tools to review and approve or deny dependency install scripts by name, with no bulk approval.
Authentication uses an npm granular access token in NPM_TOKEN, or existing npm login credentials from ~/.npmrc. The README says classic and Automation tokens are no longer supported. The server itself needs Node.js 20 or newer and is built from source after cloning the repository.
Tools this server provides (42)
Taken from the project documentation; the running server may differ.
From the tool list in its README, going by the names, 1 of 42 tools deletes data and 4 change data; 33 names don't say.
From the server's own tool labels and tool names; not verified by us.
- publishName suggests: changes
- Publish a package to npm registry
- stage
- Stage, list, inspect, download, approve, or reject a pending package version
- version
- Bump package version
- unpublish
- Remove a package version
- deprecate
- Deprecate a version
- pack
- Preview what would be published
- viewName suggests: reads
- View package info from registry
- searchName suggests: reads
- Search npm registry
- bugs
- Get bug tracker URL for a package
- repo
- Get repository URL for a package
- docs
- Get documentation URL for a package
- diff
- Show diff between package versions
- install
- Install packages
- pending-scripts
- List unreviewed dependency install scripts
- approve-scriptsName suggests: changes
- Approve named, reviewed dependencies
- deny-scripts
- Deny install scripts for named dependencies
- uninstallName suggests: deletes
- Remove packages
- updateName suggests: changes
- Update packages
- outdated
- Check for outdated packages
- ls
- List installed packages
- explainName suggests: reads
- Explain why a package is installed
- dedupe
- Reduce duplication in dependency tree
- prune
- Remove extraneous packages
- fund
- Show funding info for dependencies
- queryName suggests: reads
- Query packages using CSS-like selectors
- audit
- Run security audit
- sbom
- Generate Software Bill of Materials
- doctor
- Check npm environment health
- ping
- Check registry connectivity
- whoami
- Check current authenticated user
- token
- Manage access tokens
- access
- Set or view access level on packages
- owner
- Manage package owners
- dist-tag
- Manage distribution tags
- profile
- View or modify npm profile settings
- config
- View npm configuration
- init
- Initialize a new package.json
- pkg
- Manage package.json fields
- ci
- Clean install from lockfile
- run-scriptName suggests: changes
- Run scripts defined in package.json
- link
- Symlink a local package
- cache
- Manage the npm cache
What it does
- Publish and version
- Publish packages, bump versions, deprecate or unpublish releases and preview a pack.
- Staged publishing
- Stage a version, then approve or reject it with a 2FA code.
- Dependency management
- Install, update, prune, dedupe and list packages, and explain why one is present.
- Security checks
- Run audits, generate CycloneDX or SPDX SBOMs and check npm environment health.
- Install script approval
- Review, approve or deny dependency install scripts on npm 12 and later.
- Registry lookups
- Search the registry and view package details, bug and repository URLs, and version diffs.
Good for
- Bump a version and publish a library from an AI chat
- Audit a project's dependencies and list outdated packages
- Generate an SBOM for a production build
- Search npm for libraries and compare two versions of one
Pricing
Open source
Free; uses your own npm account
Npm FAQ
What credentials does Npm need?
A granular npm access token in NPM_TOKEN, or existing credentials from npm login in ~/.npmrc.
Does Npm support staged publishing?
Yes, through the stage tool, which needs npm CLI 11.15.0+ and Node.js 22.14.0+.
Which Node.js version does the server need?
Node.js 20 or newer, though some npm features need newer combinations.
Are classic tokens supported?
No. The README says classic and Automation tokens are no longer supported.
Is Npm free?
Yes. Npm is open source, so you can use and self-host it for free.
How do I add Npm to Claude Code?
Run this command in your terminal: claude mcp add npm --env NPM_TOKEN='<NPM_TOKEN>' -- npx -y @mikusnuz/npm-mcp
What are the best alternatives to Npm?
The closest alternatives to Npm are REA, Codebase Memory, Serena MCP: the IDE for your agent, XERJ and Context7.
Where this comes from
- Description: written from the project's README.
- Install steps: from the official MCP Registry entry.



