Official agent skill

React Devtools

by sanity-io in sanity-io/sanity

React DevTools CLI for AI agents. An agent skill from sanity-io/sanity.

OfficialMITAuto-check passedMobile

Install React Devtools

skills CLI
$ npx skills add sanity-io/sanity --skill react-devtools -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install sanity-io/sanity react-devtools --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/sanity-io/sanity.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/react-devtools .claude/skills/react-devtools && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
react-devtools
GitHub stars
6.4k
Used in
3 other repos
Token cost
~2.1k tokens
SKILL.md length
497 words
Files
4 (incl. references)
Skills in repo
34
Repo updated
First seen
Licence
MIT

At a glance

React DevTools CLI for AI agents. An agent skill from sanity-io/sanity.

  • Works in 4 steps: Ensure connection — check… → Inspect — get the component tree, search… → Profile — start profiling, trigger the… → …
  • The user asks you to debug a React
  • SKILL.md covers Core Workflow, Essential Commands, Understanding the Output and Common Patterns, plus 3 more sections
  • Calls npx

What it does

React Devtools is an agent skill from sanity-io/sanity, published by the product's own GitHub organization. React DevTools CLI for AI agents. Use when the user asks you to debug a React or React Native app at runtime, inspect component props/state/hooks, diagnose render performance, profile re-renders, find slow components, or understand why something re-renders. Triggers include "why does this re-render", "inspect the component", "what props does X have", "profile the app", "find slow components", "debug the UI", "check component state", "the app feels slow", or any React runtime debugging task.

Its SKILL.md is about 2.1k tokens, which your agent loads only when the skill is triggered. The skill folder holds 4 other files, including reference files (for example `references/commands.md`, `references/profiling-guide.md` and `references/setup.md`).

It sits in Mobile, covering Cross-platform mobile apps and Debugging. It works with React and React Native. The repository describes itself as: Sanity Studio – Rapidly configure content workspaces powered by structured content. The licence is MIT.

When your agent uses it

  • The user asks you to debug a React
  • React Native app at runtime
  • Inspect component props/state/hooks
  • Diagnose render performance

Example prompts

  • “why does this re-render”
  • “inspect the component”
  • “what props does X have”
  • “/react-devtools”

Requirements

  • Node.js
  • Pre-approved tools (allowed-tools): Bash(agent-react-devtools:*)

Workflow steps

4 steps, taken from the first numbered list in SKILL.md.

  1. Ensure connection — check agent-react-devtools status. If the daemon is not running, start it with agent-react-devtools start. Use…
  2. Inspect — get the component tree, search for components, inspect props/state/hooks.
  3. Profile — start profiling, trigger the interaction (or ask the user to), stop profiling, analyze results.
  4. Act — use the data to fix the bug, optimize performance, or explain what's happening.

What it can do on your machine

Read from SKILL.md and the folder at commit 982525c. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Bash(agent-react-devtools:*)

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • npx

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use npx, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

React Devtools loads about 2.1k tokens when it runs, and up to ~5.7k if it reads all its reference files. Until then it costs about 128 tokens; SKILL.md has 497 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~128
When it runs · the whole SKILL.md, loaded when a task matches
~2.1k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~5.7k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from sanity-io/sanity at commit 982525c, republished under its MIT licence (© sanity-io). 497 words, ~2,067 tokens.

Download SKILL.mdSave it as .claude/skills/react-devtools/SKILL.md (or your agent's skills folder). This skill also uses 3 other files; get the full folder from GitHub.
name
react-devtools
description
React DevTools CLI for AI agents. Use when the user asks you to debug a React or React Native app at runtime, inspect component props/state/hooks, diagnose render performance, profile re-renders, find slow components, or understand why something re-renders. Triggers include "why does this re-render", "inspect the component", "what props does X have", "profile the app", "find slow components", "debug the UI", "check component state", "the app feels slow", or any React runtime debugging task.
allowed-tools
Bash(agent-react-devtools:*)

agent-react-devtools

CLI that connects to a running React or React Native app via the React DevTools protocol and exposes the component tree, props, state, hooks, and profiling data in a token-efficient format.

Core Workflow

  1. Ensure connection — check agent-react-devtools status. If the daemon is not running, start it with agent-react-devtools start. Use agent-react-devtools wait --connected to block until a React app connects.
  2. Inspect — get the component tree, search for components, inspect props/state/hooks.
  3. Profile — start profiling, trigger the interaction (or ask the user to), stop profiling, analyze results.
  4. Act — use the data to fix the bug, optimize performance, or explain what's happening.

Essential Commands

Daemon
bash
agent-react-devtools start              # Start daemon (auto-starts on first command)
agent-react-devtools stop               # Stop daemon
agent-react-devtools status             # Check connection, component count, last event
agent-react-devtools wait --connected   # Block until a React app connects
agent-react-devtools wait --component App # Block until a component appears
Component Inspection
bash
agent-react-devtools get tree           # Full component hierarchy (labels: @c1, @c2, ...)
agent-react-devtools get tree --depth 3 # Limit depth
agent-react-devtools get component @c5  # Props, state, hooks for a specific component
agent-react-devtools find Button        # Search by display name (fuzzy)
agent-react-devtools find Button --exact # Exact match
agent-react-devtools count              # Count by type: fn, cls, host, memo, ...
agent-react-devtools errors             # List components with errors or warnings
Performance Profiling
bash
agent-react-devtools profile start              # Start recording
agent-react-devtools profile stop               # Stop and collect data
agent-react-devtools profile slow               # Slowest components by avg render time
agent-react-devtools profile slow --limit 10    # Top 10
agent-react-devtools profile rerenders          # Most re-rendered components
agent-react-devtools profile report @c5         # Detailed report for one component
agent-react-devtools profile timeline --limit 10                        # First 10 commits (use --limit; uncapped can dump 300+ lines)
agent-react-devtools profile timeline --limit 10 --offset 10           # Next 10 (pagination)
agent-react-devtools profile timeline --sort duration --limit 5        # Top 5 most expensive commits
agent-react-devtools profile timeline --sort timeline --limit 5        # Explicit chronological order (same as default)
agent-react-devtools profile commit 3           # Detail for commit #3
agent-react-devtools profile export profile.json # Export as React DevTools Profiler JSON
agent-react-devtools profile diff before.json after.json  # Compare two exports

Understanding the Output

Component Labels

Every component gets a stable label like @c1, @c2. Use these to reference components in follow-up commands:

@c1 [fn] App
├─ @c2 [fn] Header
├─ @c3 [fn] TodoList
│  ├─ @c4 [fn] TodoItem key=1
│  └─ @c5 [fn] TodoItem key=2
└─ @c6 [host] div

Type abbreviations: fn = function, cls = class, host = DOM element, memo = React.memo, fRef = forwardRef, susp = Suspense, ctx = context.

Components with errors or warnings show annotations: ⚠2 = 2 warnings, ✗1 = 1 error. Use agent-react-devtools errors to list only affected components.

Inspected Component
@c3 [fn] TodoList
props:
  items: [{"id":1,"text":"Buy milk"},{"id":2,"text":"Walk dog"}]
  onDelete: ƒ
state:
  filter: "all"
hooks:
  useState: "all"
  useMemo: [...]
  useCallback: ƒ

ƒ = function value. Values over 60 chars are truncated.

Profiling Output
Slowest (by avg render time):
  @c3 [fn] ExpensiveList  avg:12.3ms  max:18.1ms  renders:47  causes:props-changed  changed: props: items, filter
  @c4 [fn] TodoItem  avg:2.1ms  max:5.0ms  renders:94  causes:parent-rendered, props-changed  changed: props: onToggle

Render causes: props-changed, state-changed, hooks-changed, parent-rendered, force-update, first-mount.

When specific changed keys are available, a changed: suffix shows exactly which props, state keys, or hooks triggered the render (e.g. changed: props: onClick, className state: count hooks: #0).

Common Patterns

Wait for the app to connect after a reload
bash
agent-react-devtools wait --connected --timeout 10
agent-react-devtools get tree

Use this after triggering a page reload or HMR update to avoid querying empty state.

Diagnose slow interactions
bash
agent-react-devtools profile start
# User interacts with the app (or use agent-browser to drive the UI)
agent-react-devtools profile stop
agent-react-devtools profile slow --limit 5
agent-react-devtools profile rerenders --limit 5

Then inspect the worst offenders with get component @cN and profile report @cN.

Browse a long timeline in chunks
bash
agent-react-devtools profile timeline --limit 20               # commits 0–19
agent-react-devtools profile timeline --limit 20 --offset 20   # commits 20–39
agent-react-devtools profile timeline --offset 30 --limit 10   # skip warm-up, show 30–39

Use profile commit <N> to drill into a specific commit once you spot a spike.

Find a component and check its state
bash
agent-react-devtools find SearchBar
agent-react-devtools get component @c12
Verify a fix worked
bash
agent-react-devtools profile start
# Repeat the interaction
agent-react-devtools profile stop
agent-react-devtools profile slow --limit 5
# Compare render counts and durations to the previous run
Show full SKILL.md (202 more words)Show less

Using with agent-browser

When using agent-browser to drive the app while profiling or debugging, you must use headed mode (--headed). Headless Chromium does not execute ES module scripts the same way as a real browser, which prevents the devtools connect script from running properly.

bash
agent-browser --session devtools --headed open http://localhost:5173/
agent-react-devtools status  # Should show 1 connected app

Important Rules

  • Labels reset when the app reloads or components unmount/remount. After a reload, use wait --connected then re-check with get tree or find.
  • status first — if status shows 0 connected apps, the React app is not connected. The user may need to run npx agent-react-devtools init in their project first.
  • Headed browser required — if using agent-browser, always use --headed mode. Headless Chromium does not properly load the devtools connect script.
  • Profile while interacting — profiling only captures renders that happen between profile start and profile stop. Make sure the relevant interaction happens during that window.
  • Use --depth on large trees — a deep tree can produce a lot of output. Start with --depth 3 or --depth 4 and go deeper only on the subtree you care about.

References

FileWhen to read
commands.mdFull command reference with all flags and edge cases
profiling-guide.mdStep-by-step profiling workflows and interpreting results
setup.mdHow to connect different frameworks (Vite, Next.js, Expo, CRA)

© sanity-io, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 3 other files (references) in .agents/skills/react-devtools of sanity-io/sanity.

  • SKILL.md
  • references/commands.md
  • references/profiling-guide.md
  • references/setup.md

Open the folder on GitHubat commit 982525c

Used in 3 other repositories

We found 3 copies of this SKILL.md (exact, near-identical or edited) in other folders, from 3 other GitHub owners. This page covers the copy in sanity-io/sanity, which our catalogue first saw on October 7, 2026.

Compare with similar skills

React Devtools next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

React Devtools compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
React Devtools this skillsanity-io/sanity6.4k3 repos~2.1kAutomated safety check: PassMIT
Jazz UI Developmentgarden-co/classic-jazz2.5k—~1.7kAutomated safety check: PassMIT
Add Error Trackinggotempsh/temps822—~4.2kAutomated safety check: NotesApache-2.0
Community Migrationjingjing2222/react-native-nitro-geolocation116—~3.5kAutomated safety check: PassMIT
React Composition Structurefluid-design-io/payload-better-auth-starter120—~899Automated safety check: PassCustom licence
Diagnosing Stacktrace SymbolicationPostHog/posthog-foss721—~2.2kAutomated safety check: PassMIT

Similar skills

  • Jazz UI Development

    garden-co/classic-jazz

    A skill your agent uses when building, debugging, or optimizing Jazz applications.

    2.5k GitHub stars~1.7k tokensUpdated 1 mo ago
    DevelopmentAuto-check passed
  • Add Error Tracking

    gotempsh/temps

    Add Temps error tracking to applications using the Sentry-compatible SDK.

    822 GitHub stars~4.2k tokensUpdated today
    MobileAuto-check: notes
  • Community Migration

    jingjing2222/react-native-nitro-geolocation

    Migrate React Native apps from @react-native-community/geolocation to react-native-nitro-geolocation.

    116 GitHub stars~3.5k tokensUpdated 24 days ago
    MobileAuto-check passed
  • React Composition Structure

    fluid-design-io/payload-better-auth-starter

    React and React Native file-system architecture patterns that scale.

    120 GitHub stars~899 tokensUpdated 3 days ago
    MobileAuto-check passed
  • Official

    Help users debug PostHog Error Tracking stack-trace symbolication for any supported platform — JavaScript/TypeScript web, React Native (Hermes), Android (Proguard / R8), or iOS / macOS (dSYM).

    721 GitHub stars~2.2k tokensUpdated today
    MobileAuto-check passed
  • Performance

    Sidiora-Labs/centra-llm-agents

    Performance optimization guidelines for React/React Native applications.

    115 GitHub stars~778 tokensUpdated 19 days ago
    MobileAuto-check passed

More from sanity-io/sanity

All 34 skills in this repo
  • Playwright CLI

    sanity-io/sanity

    Official

    Automates browser interactions for web testing, form filling, screenshots, and data extraction.

    6.4k GitHub starsUsed in 18 repos~1.9k tokens
    Auto-check passed
  • Find Skills

    sanity-io/sanity

    Official

    Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities.

    6.4k GitHub starsUsed in 67 repos~1.2k tokens
    Auto-check passed
  • Official

    React and Next.js performance optimization guidelines from Vercel Engineering.

    6.4k GitHub starsUsed in 130 repos~1.6k tokens
    Auto-check passed
  • Before And After

    sanity-io/sanity

    Official

    Add existing screenshots or screen recordings to a GitHub pull request as a before/after or preview block.

    6.4k GitHub starsUsed in 1 repo~2.1k tokens
    Auto-check passed
  • TDD

    sanity-io/sanity

    Official

    Test-driven development with red-green-refactor loop. An agent skill from sanity-io/sanity.

    6.4k GitHub starsUsed in 20 repos~1k tokens
    Auto-check passed
  • Official

    Measures @sanity/ui v5 side-by-side migration progress — per-component import file counts (v5 alias vs @sanity/ui), JSX instance counts, and styled() instance counts with alias resolution.

    6.4k GitHub stars~2.1k tokensUpdated today
    Auto-check passed

Questions about React Devtools

What does React Devtools do?

React DevTools CLI for AI agents. An agent skill from sanity-io/sanity. React Devtools is an agent skill from sanity-io/sanity, published by the product's own GitHub organization. React DevTools CLI for AI agents.

When should I use React Devtools?

React Devtools fits situations like: the user asks you to debug a React; React Native app at runtime; inspect component props/state/hooks; diagnose render performance.

How do I install React Devtools in Claude Code?

Run `npx skills add sanity-io/sanity --skill react-devtools -a claude-code`. Or copy the skill folder (.agents/skills/react-devtools in sanity-io/sanity) into .claude/skills/react-devtools in your project. Claude Code loads it when a task matches its description.

How do I install React Devtools in Codex?

Run `npx skills add sanity-io/sanity --skill react-devtools -a codex`. Or copy the skill folder (.agents/skills/react-devtools in sanity-io/sanity) into .agents/skills/react-devtools in your project. Codex loads it when a task matches its description.

Can I use React Devtools in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add sanity-io/sanity --skill react-devtools -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/react-devtools, .gemini/skills/react-devtools, .github/skills/react-devtools and .opencode/skills/react-devtools in your project.

What does React Devtools need to run?

Going by SKILL.md and its folder, React Devtools needs the command-line tools its instructions call (npx). Our summary lists: Node.js. Its frontmatter pre-approves these tools: Bash(agent-react-devtools:*).

Does React Devtools access the network?

SKILL.md contains no URLs. Its commands use npx, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is React Devtools safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does React Devtools use?

React Devtools is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does React Devtools use?

About 2.1k tokens (SKILL.md is roughly 8.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 3.6k tokens, read only when the agent opens those files.

What are the alternatives to React Devtools?

Skills that share tags, products or a category with React Devtools: Jazz UI Development (garden-co/classic-jazz, 2.5k stars), Add Error Tracking (gotempsh/temps, 822 stars), Community Migration (jingjing2222/react-native-nitro-geolocation, 116 stars) and React Composition Structure (fluid-design-io/payload-better-auth-starter, 120 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains React Devtools?

sanity-io (a GitHub organization, an official publisher) maintains it in sanity-io/sanity, which has 6,352 GitHub stars. The repository holds 34 skills in this directory. The repository was last updated on October 7, 2026.

Source: sanity-io/sanity on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.