Start here

Know which tool to reach for

React DevTools tells you what a component received and how it rendered. Redux DevTools tells you what happened to shared application state.

React DevTools

“What is this component doing?”

Use the Components tab to inspect props, state, hooks and context. Use the Profiler when you have a measured rendering problem.

  • Find the component behind a piece of UI.
  • Check the exact props it received.
  • Watch local state and hooks change.
  • Spot avoidable re-renders.
Redux DevTools

“What happened to application state?”

Use the action history to follow events. Inspect payloads, state and diffs to see exactly where the data stopped being correct.

  • Confirm an action was dispatched.
  • Inspect the action payload.
  • See the exact state change.
  • Move backwards through state history.
Team rule: Before adding a console log, check React DevTools, Redux DevTools, Network and Console. Most frontend bugs become much smaller once you know which layer is wrong.

React DevTools

Inspect the component, not just the DOM

The browser Elements tab shows HTML. React DevTools shows the React component tree that produced it.

Interactive component inspector

Select a component below. The inspector updates with the kind of data you would see in React DevTools.

1

Open DevTools with F12 or Ctrl + Shift + I.

2

Open the Components tab.

3

Use the component picker, then click the UI you want to inspect.

4

Read props and state before changing any code.

React DevTools demo
Selected component <ProductPage>

What to look for

Start with values, not implementation. If the component receives the wrong value, move up the data flow. If it receives the right value but renders the wrong UI, inspect the component itself.

Common mistake

A prop being present does not mean it has the expected type. Watch for strings such as "false" where code expects the boolean false.

Profiler warning

Do not optimise every render. Profile a real slow interaction first. Then fix components that render often and cost meaningful time.

Quick experiment

See why changing a prop can narrow a bug

Toggle the simulated disabled prop. In real DevTools, changing a value is temporary and only helps test a theory.

The button is disabled because the component received disabled: true.

Redux DevTools

Follow the event, payload and state change

Redux DevTools is strongest when you treat the action list as a timeline of what the application believed happened.

Redux DevTools demo
Action history

            

How to read an action

If clicking the UI produces no expected action, the problem is probably before Redux. Check the event handler and dispatch call.

If the action exists but the payload is wrong, trace where the payload was built. If the payload is right but state becomes wrong, inspect the reducer or middleware.

Use Diff more often

Large Redux stores are hard to scan. Diff shows the specific fields changed by an action. It is usually faster than comparing full state objects.

Unexpected state changes outside the intended slice are a warning sign for mutation or overly broad reducers.

Watch for sensitive data: Redux state can appear in screenshots, bug reports and recordings. Do not place secrets, tokens or unnecessary personal data in client-side state.

Team workflow

Debug from the symptom towards the source

Use the tools to answer one question at a time. Do not jump straight into changing code.

1
React DevTools

Is the right component rendered? Are its props, hooks and context correct?

2
Redux DevTools

Did the expected action fire? Is its payload correct? Did state change correctly?

3
Network

If data came from an API, inspect request, response, status code and timing.

4
Console and debugger

Use errors, breakpoints and source code once you have narrowed the faulty layer.

Example

“Add to bag doesn't work”

Click through the checks below. This is the sort of sequence the team can follow during a bug investigation.

Start with the React component. Check whether it is rendered, disabled, and receiving the expected product and size.

Cheat sheet

Question → tool

Question Use
Why is this component showing the wrong value?React Components
What props did the component receive?React Components
What is its local state?React Components
Why is an interaction slow?React Profiler
Was the Redux action dispatched?Redux action history
What data was dispatched?Redux Action view
What changed in global state?Redux Diff view
What did state look like before the bug?Redux action history / time travel
Did the API request succeed?Browser Network tab
Did JavaScript throw an error?Browser Console

Team habit

Observe first. Change code second.

A useful bug report should say which component was wrong, which action fired, what the payload contained, and what state changed. That gives the next engineer something concrete to work from.