VOOZH about

URL: https://www.geeksforgeeks.org/reactjs/create-a-radial-bar-chart-using-recharts-in-reactjs/

⇱ Create a Radial Bar Chart using Recharts in ReactJS - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

Create a Radial Bar Chart using Recharts in ReactJS

Last Updated : 23 Jul, 2025

Rechart JS is a library that is used for creating charts for React JS. This library is used for building Line charts, Bar charts, Pie charts, etc, with the help of React and D3 (Data-Driven Documents).  

A Radial Bar chart is a categorical bar chart that is displayed in polar coordinates. It is also known as a circular bar chart. It is used to show comparisons among categorical data by using a circular shape plot.

Prerequisite:

Approach to create Radial Bar Chart:

To craft a Radial Bar chart in React with recharts, employ the RadialBarChart component from the Recharts npm package. Generate individual bars within the chart by employing the RadialBar component.

Steps to create React Application And Installing Module:

Step 1: Create a React application using the following command.

npx create-react-app foldername

Step 2: After creating your project folder i.e. foldername, move to it using the following command.

cd foldername

Step 3: After creating the ReactJS application, Install the required modules using the following command.

npm install --save recharts

Project Structure:

👁 Image

The updated dependencies in package.json file will look like:

"dependencies": {
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-scripts": "5.0.1",
"recharts": "^2.10.1",
"web-vitals": "^2.1.4",
}

Example 1: The code utilizes the 'recharts' library in React to generate a Radial Bar Chart, representing data with categories ('A' to 'I') and corresponding numerical values, while customizing the chart's appearance and layout.

Step to Run Application: Run the application using the following command from the root directory of the project:

npm start

Output: Now open your browser and go to http://localhost:3000

👁 Image
Output

Example 2: The code uses the 'recharts' library in React to create a Radial Bar Chart displaying data with different categories ('A' to 'G') and corresponding values, customizing the appearance and layout of the chart.

Output: Now open your browser and go to http://localhost:3000

👁 Image
Output
Comment
Article Tags: