Skip to main content
subagent CX Codex

codebase-search — Claude Code subagent: what it does, how to install

codebase-search finds where a feature lives in your repo and hands back absolute paths plus a short explanation of the flow.

no license ★ 1,064 updated 2026-01-21

Install into Claude Code · Manually: put the files in place All methods and platforms ↓
.claude/agents/codebase-search.md
Open on GitHub

What codebase-search does

Ask it where something lives and it goes looking. The first move is several tool calls at once: grep for text, glob for filenames, LSP for definitions. One request covers matches and symbols together.

It runs on haiku and never writes or deletes files. The main agent handles the patch; this one maps the ground. GitHub examples arrive through the grep-app MCP server, with context7 and exa wired in alongside. Treat those hits with care, since they can come from a different library version, and the agent checks them against local search before reporting.

Every reply closes with a <results> block: absolute paths, an answer to the underlying need, and suggested next steps.

What it helps with

  • locate the auth implementation
  • list every call site of a function before a refactor
  • work out which files handle payment processing
  • get absolute paths you can open straight from the terminal
  • see how open-source repos solved the same problem

Example prompts for the agent

  • Find where the login flow is implemented and explain it
  • List every file that calls validateUser
  • Which files handle payment processing?

How to install codebase-search

Manually: put the files in place

.claude/agents/codebase-search.md

For all projects use ~/.claude/agents/. Claude delegates by the description field or an @-mention

Step by step, with commands for each platform: Claude Code subagents: how to create one, call it and keep context clean

Questions about codebase-search

How do I install codebase-search in Claude Code?

Drop the agent file at .claude/agents/codebase-search.md inside your project.

What does codebase-search do?

It locates code and files on request, then answers with absolute paths, a short explanation and next steps.

What powers the GitHub search?

Public repo results come through the grep-app MCP server; context7 and exa are connected the same way. Without those servers you are left with local Grep, Glob and LSP.

Similar subagents

All subagents for Agent setup: memory, context, orchestration →

From the same set20

The whole set →
rendering-content-visibility The rendering-content-visibility rule applies content-visibility: auto to long lists so off-screen items can wait before rendering. It fits message feeds and other scrollable collections. CX Codex +1 ★ 1,064repo stars rerender-dependencies rerender-dependencies — a Claude rule that keeps useEffect dependency arrays on primitives like user.id rather than whole objects, so an effect stops firing on every field change. CX Codex +1 ★ 1,064repo stars testing The testing rule sets conventions for TypeScript test files and the __tests__ directory. Use it to guide checks for success cases, failures, and edge conditions. CX Codex +1 ★ 1,064repo stars forge The forge rule configures Foundry workflows for Abstract and tells Claude Code to use the ZKsync mode for Solidity projects. CX Codex +1 ★ 1,064repo stars js-batch-dom-css js-batch-dom-css — a Claude rule that keeps the agent from writing styles one property at a time and pushes it toward a class or a single cssText string. CX Codex +1 ★ 1,064repo stars media-interpreter media-interpreter — a subagent for working with PDFs, images, diagrams, and other binary formats. Extracts text, tabular data, and descriptions of visual content when standard file reading isn't an option. CX Codex ★ 1,064repo stars tech-docs-writer tech-docs-writer explores unfamiliar codebases to generate and maintain technical documentation, README files, and API guides with verified code samples. CX Codex ★ 1,064repo stars open-source-librarian The open-source-librarian subagent investigates open-source libraries and codebases, tracing implementations and linking to exact GitHub lines. Use it for source-level and change-history questions. CX Codex ★ 1,064repo stars

Project sponsors

Companies that keep this analytics open