React Doctor runs deterministic checks on your code. It reports issues in state and effects, performance, architecture, security, accessibility, and maintainability.
Supports React projects built with Next.js, Vite, Astro, TanStack, React Native, and Expo.
Run this command from your project root:
npx react-doctor@latestMain.mp4
Install the skill to help your coding agent find and fix React issues:
npx react-doctor@latest installSupports coding agents including Claude Code, Cursor, Codex, and OpenCode.
Scan each pull request and report the issues it introduces:
npx react-doctor@latest ci installWhen a Git comparison cannot verify Stencil JSX compiler settings, it skips baseline attribution for uncertain class findings. The CLI names the affected paths on stderr in JSON mode. Other findings still count toward the CI gate.
Choose rules and scan settings in doctor.config.ts.
With customRulesOnly: true, explicit rules settings of "warn" or "error"
enable selected ported rules. Legacy rule names also work. Other ported rules and
the React Compiler plugin stay off.
Mixed classic and automatic JSX projects can use
automaticJsxRuntimeFiles to tell the opt-in JSX scope rule which exact
project-relative paths use the automatic transform.
For a component that renders a fixed list supplied by its caller, you can declare a specific prop path in fixedIndexKeyLists. React Doctor checks the exact file, component export, and prop path and still reports index keys on other lists. Use this only when the length and the item at each position stay fixed for each mounted component instance.
{
"fixedIndexKeyLists": [
{ "file": "src/Banner.tsx", "componentExport": "default", "propPath": ["banner", "labels"] }
]
}The rule recognizes direct maps to text-only span elements whose position depends on the index.
Record a Chrome DevTools performance trace while you interact with a running React app:
npx react-doctor@latest scan http://localhost:3000The CLI collects crash reports and anonymous usage data. See Data use for details.
To opt out, run: npx react-doctor@latest --no-telemetry
MIT-licensed