Free & Open Source

Ground

Code analysis that checks before it claims

AI assistants will tell you files are "95% similar" without actually comparing them. Ground fixes this. It requires your AI to verify before claiming—no more hallucinated duplicates or false positives.

Install in 2 minutes

Copy the config for your AI tool

Claude Desktop

Add to claude_desktop_config.json

Windsurf

Settings → MCP → View raw config

Codex CLI

codex mcp add ground

npm

Works with any MCP client

How it works

1

Check first

Your AI runs a verification command to actually compare files or count uses

2

Then claim

Only after checking can it report something as a duplicate, dead code, or orphan

3

Blocked otherwise

If it tries to claim without checking first, Ground stops it

# First, compare the files
ground compare utils.ts helpers.ts

# Then, make a claim (only works if you've compared)
ground claim duplicate utils.ts helpers.ts "same validation logic"

# Try to claim without checking? Blocked.
✗ Claim blocked
  You need to compare these files first:
  ground compare utils.ts helpers.ts

What you can do

20+ tools for finding real problems in your code

Verify

  • ground_compare — See how similar two files actually are
  • ground_count_uses — Find if a function is actually used anywhere
  • ground_check_connections — See if a module is connected to your app
  • ground_check_environment — Catch Node.js APIs leaking into Workers

Find problems

  • ground_find_duplicate_functions — Find copy-pasted code
  • ground_find_orphans — Find files nothing imports
  • ground_find_dead_exports — Find exports nobody uses
  • ground_find_drift — Find where code drifted from your design system

Understand patterns

  • ground_adoption_ratio — See how consistently you use your tokens
  • ground_suggest_pattern — Get suggestions based on your existing code
  • ground_mine_patterns — Discover patterns you're already using

Report findings

  • ground_claim_duplicate — Report a duplicate (requires verification first)
  • ground_claim_dead_code — Report dead code (requires verification first)
  • ground_claim_orphan — Report an orphan (requires verification first)
Case Study

Kickstand: 155 scripts became 13

We used Ground to find and consolidate duplicate code in a production codebase. Because every finding was verified, we had zero false positives—every deletion was safe.

92% code reduction
0 false positives
155→13 scripts
Read the full case study →