knip
✂️ Find unused files, dependencies and exports in your JavaScript and TypeScript projects. Knip it before you ship it!
The Knip MCP server enables AI assistants to detect unused files, dependencies, and exports in JavaScript and TypeScript codebases. By integrating Knip's analysis capabilities through the Model Context Protocol, developers can ask AI agents to identify dead code, bloated dependencies, and orphaned exports directly within their workflow. This server helps maintain leaner projects by surfacing cleanup opportunities that improve performance and reduce maintenance burden.
Key Features
Use Cases
- 01Ask an AI assistant to scan a TypeScript project for unused dependencies before deployment
- 02Identify dead code and orphaned files during codebase refactoring sessions
- 03Automate dependency cleanup analysis in CI/CD pipelines through AI-powered workflows
- 04Get AI-driven recommendations for reducing bundle size by removing unused exports
- 05Conduct code audits with AI assistance to find maintenance opportunities
- 06Streamline project cleanup by letting AI agents surface removable code and dependencies
Related MCP Servers
View moremarkitdown
Python tool for converting files and office documents to Markdown.
firecrawl
The context API to search, scrape, and interact with the web at scale. 🔥
prompts.chat
f.k.a. Awesome ChatGPT Prompts. Share, discover, and collect prompts from the community. Free and open source — self-host for your organization with complete privacy.
langflow
Langflow is a powerful tool for building and deploying AI-powered agents and workflows.
knip — FAQ
What is the Knip MCP server?+
The Knip MCP server is a Model Context Protocol integration that allows AI assistants to analyze JavaScript and TypeScript projects for unused files, dependencies, and exports. It exposes Knip's code analysis capabilities to compatible AI clients through standardized MCP tools.
How do I install the Knip MCP server?+
Install the @knip/mcp package via npm and add it to your AI client's MCP configuration. For Claude Desktop, add the server configuration to claude_desktop_config.json with the npx command pointing to @knip/mcp.
Which AI clients work with the Knip MCP server?+
The Knip MCP server works with any MCP-compatible client, including Claude Desktop and other applications that support the Model Context Protocol standard.
Do I need API keys to use the Knip MCP server?+
No API keys are required. The Knip MCP server runs locally and analyzes your project files directly without external API dependencies.
Is the Knip MCP server free to use?+
Yes, the Knip MCP server is free and open-source software licensed under the ISC License. All official Knip packages, including @knip/mcp, are available at no cost.
What programming languages does Knip support?+
Knip supports JavaScript and TypeScript projects, analyzing both source files and dependency declarations to identify unused code and packages.
How do I install knip?+
Open the source repository on GitHub and follow its README. knip is a mcp server — MCP Agents Market links you directly to the official repo.
Is knip free?+
knip is an open-source project hosted on GitHub. Check the repository for its license and any usage requirements.