This can be achieved with a Browser Extension or a global npm package. (rarely a local one) Let me show you the two most popular tools.

React Sight (chrome extension)

React Sight is a live view of the component hierarchy tree of your React application with support for React Router and Redux.

Source: https://github.com/React-Sight/React-Sight

React Monocle (npm package)

React Monocle parses through your React source files to generate a visual tree graph representing your React component hierarchy. The tree is then displayed along with a live copy of your application.

Source: https://github.com/team-gryff/react-monocle

Answer from Orlandster on Stack Overflow
🌐
GitHub
github.com β€Ί singhutsav5502 β€Ί React-tree-visualiser
GitHub - singhutsav5502/React-tree-visualiser: a React based JS/JSX component tree visualiser
React TreeVis is a tool designed to help developers visualize the hierarchy of React components within a single file, enabling a better understanding of complex JSX structures.
Author Β  singhutsav5502
🌐
Visual Studio Marketplace
marketplace.visualstudio.com β€Ί items
ReacTree - Visual Studio Marketplace
February 23, 2023 - Extension for Visual Studio Code - React hierarchy tree visualizer and navigation tool
Discussions

A React component tree and state visualizer
What does this do that the Profiler can't? More on reddit.com
🌐 r/reactjs
12
25
June 18, 2020
Any libraries for representing trees in react?
You could try React Flow More on reddit.com
🌐 r/reactjs
23
15
December 3, 2023
🌐
npm
npmjs.com β€Ί package β€Ί react-d3-tree
react-d3-tree - npm
February 28, 2025 - React component to create interactive D3 tree hierarchies. Latest version: 3.6.6, last published: a year ago. Start using react-d3-tree in your project by running `npm i react-d3-tree`. There are 50 other projects in the npm registry using ...
      Β» npm install react-d3-tree
    
Published Β  Feb 28, 2025
Version Β  3.6.6
Author Β  Ben Kremer
🌐
npm
npmjs.com β€Ί package β€Ί react-tree-visualizer
react-tree-visualizer - npm
A react component library for visualizing tree data structures. Latest version: 0.0.21, last published: a year ago. Start using react-tree-visualizer in your project by running `npm i react-tree-visualizer`. There are no other projects in the ...
      Β» npm install react-tree-visualizer
    
Published Β  Jul 08, 2024
Version Β  0.0.21
Author Β  Omar ElGaml
🌐
MUI
mui.com β€Ί x β€Ί react-tree-view
Tree View React component - MUI X
The Tree View components let users navigate hierarchical lists of data with nested levels that can be expanded and collapsed. ... This impressive paella is a perfect party dish and a fun meal to cook together with your guests.
🌐
CodeSandbox
codesandbox.io β€Ί s β€Ί react-tree-visualizer-hs3l2
react-tree-visualizer - CodeSandbox
January 27, 2021 - react-tree-visualizer using react, react-d3-tree, react-dom, react-scripts
Published Β  Jan 27, 2021
Find elsewhere
🌐
Untitled Publication
singhutsav.hashnode.dev β€Ί react-component-tree-visualizer
React Tree Visualizer: Creating a visualizer for .js/jsx ...
March 21, 2024 - The preliminary goal was to create a tool that allows users to load and parse their .js/jsx component file to visualize it in a tree-like structure that displays a hierarchy of detailed component nodes.
🌐
GitHub
github.com β€Ί oslabs-beta β€Ί Realize
GitHub - oslabs-beta/Realize: A React component tree visualizer
A React component tree visualizer. Contribute to oslabs-beta/Realize development by creating an account on GitHub.
Starred by 335 users
Forked by 21 users
Languages Β  JavaScript 82.1% | TypeScript 9.9% | CSS 4.7% | HTML 3.3% | JavaScript 82.1% | TypeScript 9.9% | CSS 4.7% | HTML 3.3%
🌐
CodeSandbox
codesandbox.io β€Ί examples β€Ί package β€Ί react-tree-graph
react-tree-graph examples - CodeSandbox
Use this online react-tree-graph playground to view and fork react-tree-graph example apps and templates on CodeSandbox.
🌐
Cassidy Williams
cassidoo.co β€Ί post β€Ί tree-visualizer
I made a tree visualizer
September 14, 2025 - I was going through some old folders on my laptop and found some old code from my old React Training teaching days for visualizing how component trees in React work, and turned it into its own standalone web app!
🌐
GitHub
github.com β€Ί React-Sight β€Ί React-Sight
GitHub - React-Sight/React-Sight: Visualization tool for React, with support for Fiber, Router (v4), and Redux Β· GitHub
React Sight is a live view of the component hierarchy tree of your React application with support for React Router and Redux.
Starred by 2.9K users
Forked by 118 users
Languages Β  JavaScript 86.9% | CSS 6.7% | HTML 6.4%
🌐
Reddit
reddit.com β€Ί r/reactjs β€Ί a react component tree and state visualizer
r/reactjs on Reddit: A React component tree and state visualizer
June 18, 2020 -

Hey folks,

A few friends and I made an extension that we wish we had when we were starting out learning React. It visualizes your component tree and state flow.

You can check it out here - https://github.com/oslabs-beta/realize

🌐
Reddit
reddit.com β€Ί r/reactjs β€Ί any libraries for representing trees in react?
r/reactjs on Reddit: Any libraries for representing trees in react?
December 3, 2023 -

what's the best way to draw trees like this one in react from any data

              β”Œβ”€β”€β”€β”
              β””β”€β”Όβ”€β”˜ β”Œβ”€β”
                β”‚   β””β”Όβ”˜
     β”Œβ”€β”€β”€β”€β”€β”€β”€β”  β”‚    β”‚
     β”‚       β”‚  β”œβ”€β”€β”€β”€β”˜
     β””β”€β”€β”€β”¬β”€β”€β”€β”˜  β”‚     β”Œβ”€β”€β”
         β”‚      β”‚     β””β”Όβ”€β”˜
         └┬──────      β”‚
β”Œβ”€β”€β”€β”     β”‚     β”‚      β”‚
β”‚   β”œβ”€β”€β”€β”€β”€β”˜     β”œβ”€β”€β”€β”€β”€β”€β”˜
β””β”€β”€β”€β”˜           β”‚
                β”‚
                β”‚

 

I want each node to be a circle with image and clickable, pretty similar to how the skill tree looked in god of war 4. Should I use d3 or are there simpler ways ?

🌐
LinkedIn
linkedin.com β€Ί pulse β€Ί vs-code-react-tree-visualizer-ioannis-pothos
VS Code - React Tree Visualizer
March 2, 2023 - What if there was a way to visualize these relations and display props with a click? Here comes the VSCode extension reacTree.
🌐
DEV Community
dev.to β€Ί mallchel β€Ί visualize-react-components-tree-p1c
Visualize react components tree - DEV Community
March 5, 2024 - Hi, today I would like to announce my new library that solved my old idea to get a high view of my... Tagged with react, uml, components, visualize.
🌐
GitHub
github.com β€Ί brimdata β€Ί react-arborist
GitHub - brimdata/react-arborist: The complete tree view component for React Β· GitHub
The complete tree view component for React. Contribute to brimdata/react-arborist development by creating an account on GitHub.
Starred by 3.6K users
Forked by 182 users
Languages Β  TypeScript 97.3% | JavaScript 1.3% | CSS 1.1%
🌐
ReactScript
reactscript.com β€Ί home β€Ί categories β€Ί chart & graph β€Ί dynamic tree graph for react – tree visualizer
Dynamic Tree Graph For React - Tree Visualizer | Reactscript
June 20, 2020 - Tree Visualizer is a React based tool designed to plot trees by adding nodes and edges with re-rooting at any node and customizable colors.
🌐
ReactScript
reactscript.com β€Ί home β€Ί 7 best react tree view components for react app (2026 update)
7 Best React Tree View Components For React App (2026 Update) - ReactScript
December 8, 2025 - React Complex Tree offers the best interaction features. It supports drag-and-drop and accessibility standards natively. This component fits complex dashboards well. Test the live demos before you install a package. The correct library prevents future performance headaches. Our Tree View category contains additional resources for React and React Native.