recharts vs d3 vs chart.js vs echarts vs apexcharts vs vega vs @observablehq/plot vs plotly.js vs victory
Choosing a chart abstraction and rendering integration
rechartsd3chart.jsechartsapexchartsvega@observablehq/plotplotly.jsvictorySimilar Packages:

Choosing a chart abstraction and rendering integration

Choose from exploratory marks, configurable chart families, React components, a visualization grammar or lower-level building blocks.

Npm Package Weekly Downloads Trend

3 Years

Github Stars Ranking

Stat Detail

Package
Downloads
Stars
Size
Issues
Publish
License
recharts70,620,21027,7228.89 MB4732 days agoMIT
d335,652,287113,961882 kB2616 days agoISC
chart.js17,673,27067,8076.23 MB640a month agoMIT
echarts11,175,17067,75560.3 MB1,4766 months agoApache-2.0
apexcharts2,936,60015,19030.6 MB28119 hours agoSEE LICENSE IN LICENSE.md
vega2,401,14212,0513.73 MB4953 months agoBSD-3-Clause
@observablehq/plot1,518,7875,4301.74 MB35514 days agoISC
plotly.js983,27718,38598.6 MB80921 days agoMIT
victory843,78311,25129.9 kB957 days agoMIT

Choose the representation before the chart appearance

Observable Plot is designed for tabular-data exploration through marks, scales and transforms. It offers a concise way to express a visualization without requiring a complete application-specific chart engine. D3 provides lower-level modules for data, scales, shapes and other visualization work. Owning that composition can enable specialized output, but also means owning more implementation and interaction work.

Vega describes a visualization in a declarative JSON specification and produces interactive views through its runtime. This is useful when specifications need to be generated, saved or exchanged as data. It is not the same API as imperatively composing D3 modules or rendering React chart children.

Configured chart libraries

Chart.js follows a canvas-oriented chart, dataset, scale and plugin model. ECharts supplies chart families and interaction through its option/component model. ApexCharts offers configured interactive charts and its own lifecycle and feature imports. Compare the actual series, data format, axes, interactions and update contract required by the dashboard rather than counting chart names.

ApexCharts has usage-dependent Community, paid and redistribution terms, and some features depend on the selected plan. Its shipped license is not a blanket MIT grant; review the applicable usage and distribution terms before choosing it. Do not transfer an old license assumption to the current package.

Plotly.js uses figure data/traces and layout for statistical, scientific, financial and other visualizations. Complete, partial and custom bundles have different integration requirements. The project’s ready-to-use distribution packages and this source package are distinct npm identities; follow the intended bundle instructions instead of assuming any installation example imports this exact package.

React composition

Recharts and Victory expose React chart components. They can fit an existing React component tree, while their data, event, layout and interaction models still differ. Recharts declares related React, React DOM and react-is peers; Victory declares React 18 or later. The web Victory package does not automatically provide its separate native integration.

Make a representative choice

Start with a real dataset, required chart type, update behavior and application rendering model. A parent container still needs meaningful dimensions for responsive charts. Check labels, interaction, export needs and the specific rendering path instead of declaring any library universally faster or simpler. Choose the abstraction the team wants to maintain: marks, options, React children, JSON specifications or lower-level visualization code.

How to Choose: recharts vs d3 vs chart.js vs echarts vs apexcharts vs vega vs @observablehq/plot vs plotly.js vs victory

  • recharts:

    Choose it for declarative React chart composition, aligning React, React DOM and react-is peers.

  • d3:

    Choose its lower-level visualization modules when the application should own data transformation, scales, layout and rendering composition.

  • chart.js:

    Choose it for common chart types drawn through a canvas-oriented chart configuration and plugin model.

  • echarts:

    Choose it for configurable chart families and interactions within the ECharts option/component model.

  • apexcharts:

    Choose it for configured interactive charts when its integration, feature plan and usage-dependent license fit the application.

  • vega:

    Choose it for declarative JSON visualization specifications and their runtime, with Canvas or SVG output.

  • @observablehq/plot:

    Choose it for concise tabular-data exploration with marks, scales and transforms in a grammar-of-graphics style.

  • plotly.js:

    Choose it for a figure/trace model covering scientific, statistical and other specialized interactive charts, with the appropriate distributed bundle.

  • victory:

    Choose it for React chart primitives and interaction/container composition on a supported React host.

README for recharts

Recharts

storybook Build and test codecov Flakiness VR tests npm version npm downloads MIT License

Introduction

Recharts is a Redefined chart library built with React and D3.

The main purpose of this library is to help you to write charts in React applications without any pain. Main principles of Recharts are:

  1. Simply deploy with React components.
  2. Native SVG support, lightweight with minimal dependencies.
  3. Declarative components.

Documentation at recharts.github.io and our storybook

Also see the wiki.

All development is done on the main branch. The current latest release and storybook documentation reflects what is on the release branch.

Examples

<LineChart width={400} height={400} data={data}>
  <XAxis dataKey="name" />
  <Tooltip />
  <CartesianGrid stroke="#f5f5f5" />
  <Line type="monotone" dataKey="uv" stroke="#ff7300" />
  <Line type="monotone" dataKey="pv" stroke="#387908" />
</LineChart>

All the components of Recharts are clearly separated. The LineChart is composed of x axis, tooltip, grid, and line items, and each of them is an independent React Component. The clear separation and composition of components is one of the principle Recharts follows.

Installation

npm

NPM is the easiest and fastest way to get started using Recharts. It is also the recommended installation method when building single-page applications (SPAs). It pairs nicely with a CommonJS module bundler such as Webpack.

# latest stable
$ npm install recharts react-is

react-is needs to match the version of your installed react package.

Deno

Deno is a drop-in replacement for npm, so Recharts installs the same way:

$ deno add recharts react-is

umd

The UMD build is also available on unpkg.com:

<script src="https://unpkg.com/react@18/umd/react.production.min.js"></script>
<script src="https://unpkg.com/react-dom@18/umd/react-dom.production.min.js"></script>
<script src="https://unpkg.com/react-is@18/umd/react-is.production.min.js"></script>
<script src="https://unpkg.com/recharts/umd/Recharts.js"></script>

Then you can find the library on window.Recharts.

Contributing

Recharts is open source. If you want to contribute to the project, please read the CONTRIBUTING.md to understand how to contribute to the project and DEVELOPING.md to set up your development environment.

Thanks

Chromatic

Thanks to Chromatic for providing the visual testing platform that helps us review UI changes and catch visual regressions.

JetBrains logo.

Thanks to JetBrains for providing OSS development license for their IDEs.

Browser testing via

TestMu AI

License

MIT

Copyright (c) 2015-2026 Recharts Group.