Chart.js vs D3.js
A data-driven comparison of two data visualization tools: popularity, development activity, licensing and installation. Updated .
Key differences
- D3.js has 1.7× as many GitHub stars as Chart.js (113.8K vs 67.7K).
- Chart.js had more development activity over the last 12 months: 21 commits vs 2.
- D3.js is downloaded 1.6× as often on npm (25.7M vs 15.7M per week).
- Chart.js is licensed under MIT; D3.js under ISC.
- D3.js is the older project: its repository was created in 2010, Chart.js's in 2013.
By the numbers
- Chart.js
- D3.js
Show data as a table
| Metric | Chart.js | D3.js |
|---|---|---|
| GitHub stars | 67,733 | 113,802 |
| npm downloads / week | 15,670,895 | 25,739,179 |
| Commits, last 12 months | 21 | 2 |
| Contributors | 426 | 136 |
| Forks | 11,947 | 22,637 |
Development activity
Commits per month to each default branch, last 12 complete months.
- Chart.js
- D3.js
Show data as a table
| Month | Chart.js | D3.js |
|---|---|---|
| Oct 2025 | 6 | 0 |
| Nov 2025 | 3 | 0 |
| Dec 2025 | 0 | 1 |
| Jan 2026 | 0 | 0 |
| Feb 2026 | 0 | 0 |
| Mar 2026 | 0 | 0 |
| Apr 2026 | 1 | 0 |
| May 2026 | 1 | 1 |
| Jun 2026 | 0 | 0 |
| Jul 2026 | 0 | 0 |
| Aug 2026 | 0 | 0 |
| Sep 2026 | 10 | 0 |
Side by side
| Attribute | Chart.js | D3.js |
|---|---|---|
| Description | Charts with the canvas tag. | JavaScript library for producing dynamic, data-driven visualizations with SVG, Canvas and HTML. |
| Category | JavaScript charting libraries | D3.js |
| License | MIT | ISC |
| Language | JavaScript | JavaScript |
| Status | Active | Maintained |
| Latest release | v4.5.1 () | v7.9.0 () |
| Last commit | ||
| Repository created | ||
| Open issues | 499 | 5 |
| Install | npm install chart.js | npm install d3 |
Which should you choose?
Popularity and activity are only part of the story. Consider which ecosystem you work in, the chart types and interactions you need, how much data you render, and whether the license fits your project. Both tool pages list alternatives if neither is quite right.