
D3.js, short for Data-Driven Documents, is a JavaScript library for building custom data visualizations in the browser. It binds data to the DOM and provides modules for scales, axes, shapes, layouts, transitions, colours, and interaction rather than shipping ready-made chart types.
The site links to versioned documentation, a large gallery of community examples, API references for every module, and Observable notebooks where users can experiment with datasets and share live, editable charts.
It suits front-end developers and data journalists who need precise control over bespoke charts, dashboards, maps, and animated explainers, and teams whose visual requirements go beyond what standard charting libraries offer.
Compared with declarative chart libraries it has a steeper learning curve but far greater expressive freedom; compared with business-intelligence tools it requires writing code and handling data preparation, yet produces lightweight, embeddable output.
Match documentation and examples to your installed major version since the API has changed across releases, sanitise any data rendered into the DOM, and consider accessibility fallbacks such as data tables for complex visuals.