D3.js
JavaScript library for creating data-driven documents with powerful data visualization capabilities.
Charts and data visualisation npm ISC
Used in agent projects
63
0.5% of 12,697 public repos built with AI coding agents
Rank in charts and data visualisation
#8 of 16
by use in those projects
Downloads
22.2M
npm, last 7 days, d3
GitHub stars
114K
last push May 28, 2026
How D3.js is used
D3.js is a dependency in 63 of the 12,697 public GitHub projects set up for AI coding agents that we scanned (0.5%), #8 of 16 in charts and data visualisation. The most used alternative there is Recharts. Projects that use it most often also use Tailwind CSS (76.2%), Lucide React (57.1%), React (82.5%).
Often used with D3.js
| Tailwind CSS | 76.2% of D3.js projects · 2.2× more than average |
|---|---|
| Lucide React | 57.1% of D3.js projects · 2.9× more than average |
| React | 82.5% of D3.js projects · 1.9× more than average |
| Framer Motion | 44.4% of D3.js projects · 3.3× more than average |
| Zustand | 36.5% of D3.js projects · 6.2× more than average |
| Testing Library | 34.9% of D3.js projects · 4.8× more than average |
| Recharts | 33.3% of D3.js projects · 4.1× more than average |
| TypeScript | 85.7% of D3.js projects · 1.5× more than average |
By coding agent
| Cursor | 1.0% of projects set up for it |
|---|---|
| Claude Code | 0.7% of projects set up for it |
| GitHub Copilot | 0.6% of projects set up for it |
| OpenAI Codex | 2.4% of projects set up for it |
| Gemini CLI | 1.1% of projects set up for it |
Share of public repos configured for each agent that list D3.js as a dependency.
Install
| Package | npm install d3 |
|---|---|
| Main stacks | Next.js (30), TypeScript / JavaScript (25), Python (5), PHP (2) |
| Example projects | NG-ZORRO/ng-zorro-antd, blockscout/frontend, leboncoin/spark-web, confluentinc/vscode, chrisreddington/trend-radar |
Alternatives to D3.js
| Tool | Used in agent projects | Downloads / wk | GitHub stars | License |
|---|---|---|---|---|
| Recharts npm Composable React component library for building responsive charts. |
1,037 (8.2%) | 56.3M | 27.6K | MIT |
| Matplotlib pypi Python library for creating static, animated and interactive plots and visualizations. |
194 (1.5%) | 39.3M | 23.3K | — |
| Chart.js npm Simple HTML5 canvas-based charting library for creating interactive data visualizations. |
165 (1.3%) | 12.7M | 67.7K | MIT |
| React Chart.js 2 npm React components wrapper for Chart.js enabling data visualization with charts. |
111 (0.9%) | 4.4M | 6,937 | MIT |
| Plotly pypi Interactive data visualization library for Python with rich chart and dashboard support. |
74 (0.6%) | 12.5M | 18.8K | — |
| Seaborn pypi Statistical data visualization library built on matplotlib with rich plot types. |
66 (0.5%) | 6.8M | 14.1K | — |
| Mermaid npm Markdown-like syntax for creating flowcharts, diagrams, and visualizations programmatically. |
65 (0.5%) | 17.7M | 90.6K | MIT |
| XY Flow npm Customizable React library for building interactive node-based editors and flow charts. |
62 (0.5%) | 13.4M | 38.6K | MIT |