Fossil

v1.0.0Developer Toolsstable

The code quality toolkit for the agentic AI era. Find dead code, clones, and scaffolding across 15 languages. MCP server + CLI.

ai-codingai-toolsastclaude-codecli
Share:
56
Stars
0
Downloads
0
Weekly
0/5

What is Fossil?

Fossil is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to code quality toolkit for the agentic ai era. find dead code, clones, and scaffolding across 15 languages. mcp server + cli.

The code quality toolkit for the agentic AI era. Find dead code, clones, and scaffolding across 15 languages. MCP server + CLI.

This server falls under the Developer Tools category on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • The code quality toolkit for the agentic AI era. Find dead c

Use Cases

Find dead code and clones across 15 languages.
Perform code quality analysis with AI.
Identify code scaffolding and unused patterns.
yfedoseev

Maintainer

LicenseApache-2.0
Languagerust
Versionv1.0.0
UpdatedMay 11, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

Manual Installation

npx fossil

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use Fossil

Fossil is a code quality MCP server and CLI toolkit built in Rust that detects dead code, code clones (Types 1, 2, and 3), and scaffolding artifacts across 16 programming languages using AST-based static analysis. It integrates directly with AI coding agents through its MCP server interface, providing tools like scan_all, analyze_dead_code, detect_clones, fossil_inspect, fossil_trace, and fossil_detect_scaffolding so that assistants can assess blast radius, trace call graphs, and identify cleanup opportunities in large codebases. Fossil is zero-configuration by default — it works out of the box with an optional fossil.toml for fine-tuning thresholds and exclusions.

Prerequisites

  • Rust toolchain installed (for cargo installation) OR curl/PowerShell for the binary installer
  • A codebase in one of the 16 supported languages (Python, JavaScript, TypeScript, Rust, Go, Java, C#, C/C++, Ruby, PHP, Swift, Kotlin, Scala, Bash, R)
  • Claude Desktop, Claude Code, or another MCP-compatible AI assistant
  • Cargo or cargo-binstall for Rust-based installation (optional)
1

Install Fossil

Install the fossil-mcp binary using the installer script, cargo, or by building from source. The installer script is the fastest method for macOS and Linux.

# macOS/Linux (recommended)
curl -fsSL fossil-mcp.com/install.sh | sh

# Windows PowerShell
irm fossil-mcp.com/install.ps1 | iex

# Via Cargo
cargo install fossil-mcp

# Via cargo-binstall (faster)
cargo binstall fossil-mcp
2

Verify installation

Confirm fossil-mcp is installed and accessible in your PATH by checking the version.

fossil-mcp --version
3

Create an optional configuration file (fossil.toml)

For projects where you want to customize detection thresholds or exclude generated code, create a fossil.toml in your project root. This file is optional — Fossil works with zero configuration.

[dead_code]
min_confidence = "high"
exclude_patterns = ["generated/**", "vendor/**"]

[clones]
min_lines = 6
similarity_threshold = 0.8
4

Register Fossil as an MCP server in Claude Desktop

Add the fossil-mcp server entry to your claude_desktop_config.json, specifying the project directory to analyze as an argument.

{
  "mcpServers": {
    "fossil": {
      "command": "fossil-mcp",
      "args": ["serve", "/path/to/your/project"]
    }
  }
}
5

Run a standalone scan from the CLI

Use the CLI for one-off analysis or CI/CD integration. The scan command runs all analyses (dead code, clones, scaffolding) and reports results.

# Full scan of current directory
fossil-mcp scan .

# Dead code only, high confidence
fossil-mcp dead-code . --min-confidence high

# Clone detection with custom thresholds
fossil-mcp clones . --min-lines 10 --similarity 0.9

# CI gate: fail if more than 10 dead code items
fossil-mcp check --max-dead-code 10 --diff origin/main --format sarif

Fossil Examples

Client configuration

Claude Desktop configuration entry for Fossil MCP server, enabling Claude to analyze your project for dead code, clones, and scaffolding.

{
  "mcpServers": {
    "fossil": {
      "command": "fossil-mcp",
      "args": ["serve", "/path/to/your/project"],
      "env": {
        "FOSSIL_MIN_CONFIDENCE": "medium",
        "FOSSIL_OUTPUT_FORMAT": "json"
      }
    }
  }
}

Prompts to try

Use these prompts to explore code quality issues in your codebase through Claude with the Fossil MCP server.

- "Scan my project for dead code and show me the highest-confidence findings"
- "Find all Type 3 code clones in the src/ directory with similarity above 85%"
- "Trace the call graph for the processPayment function and show its blast radius"
- "Detect any scaffolding artifacts or TODO-phase comments left in the codebase"
- "Run a full scan and summarize the top 10 cleanup opportunities by impact"

Troubleshooting Fossil

fossil-mcp command not found after installation

The installer adds fossil-mcp to ~/.local/bin or ~/.cargo/bin. Ensure this directory is in your PATH: add 'export PATH="$HOME/.cargo/bin:$PATH"' to your ~/.zshrc or ~/.bashrc and restart your shell. For Claude Desktop, use the absolute path (e.g. /Users/yourname/.cargo/bin/fossil-mcp) in the config.

Dead code detection reports too many false positives

Increase the minimum confidence threshold by setting FOSSIL_MIN_CONFIDENCE=high or adding min_confidence = "high" to your fossil.toml [dead_code] section. Also add exclude_patterns for generated directories like vendor/, generated/, or dist/.

Clone detection is slow on large codebases

Increase FOSSIL_MIN_LINES to filter out short duplicates (e.g. FOSSIL_MIN_LINES=15). Use the --diff flag to limit analysis to changed files: 'fossil-mcp clones . --diff origin/main'. This is especially useful in CI pipelines.

Frequently Asked Questions about Fossil

What is Fossil?

Fossil is a Model Context Protocol (MCP) server that code quality toolkit for the agentic ai era. find dead code, clones, and scaffolding across 15 languages. mcp server + cli. It connects AI assistants to external tools and data sources through a standardized interface.

How do I install Fossil?

Follow the installation instructions on the Fossil GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.

Which AI clients work with Fossil?

Fossil works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is Fossil free to use?

Yes, Fossil is open source and available under the Apache-2.0 license. You can use it freely in both personal and commercial projects.

Browse More Developer Tools MCP Servers

Explore all developer tools servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "fossil": { "command": "npx", "args": ["-y", "fossil"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use Fossil?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides