D3.js

Open Source

by D3.js

Provided by D3.js

Not yet rated
Platform
Web
Pricing
Open Source
Account required
No
Ads
None
Last verified
3 hours ago
Developer
D3.js
Official URL

Overview

D3, short for data-driven documents, is a free, open-source JavaScript library for drawing data visualizations with web standards: SVG, Canvas and the page's own DOM. It was created by Mike Bostock in 2011 and is now maintained at Observable.

D3 is a low-level toolbox, not a charting library. It has no ready-made bar chart or pie chart. Instead you combine building blocks: parsers for CSV data, scales that map values to positions and colours, shape generators for lines and areas, axes, layouts for hierarchies and networks, map projections, and helpers for transitions, zooming, dragging and brushing. The library is split into about 30 modules that can be used together or one at a time, and it can be loaded from a CDN, downloaded as a single file or installed from npm.

That freedom is why newsrooms and specialist teams use it for custom, interactive graphics, and it is also why it takes time to learn. The project's own documentation says a simple chart can take dozens of lines of code and points people who just want a quick chart towards Observable Plot, a higher-level sister library from the same team. D3 can be used alongside frameworks such as React, Vue and Svelte.

Features

  • Draws with web standards: SVG, Canvas and the DOM
  • About 30 modules that can be used together or separately
  • Scales, axes and shape generators for lines, areas, arcs and more
  • Layouts for hierarchies, force-directed networks and stacked data
  • Geographic projections for maps
  • Transitions and easing for animated updates
  • Zoom, drag and brush interactions
  • Data helpers for CSV parsing, number and date formatting and array statistics
  • Loads from a CDN as an ES module or classic script, or installs from npm

Privacy

D3 is a code library that runs in the visitor's browser as part of your own page; it has no accounts. See the official privacy policy for the documentation site.

Pros & Cons

Pros

  • Free and open source under the ISC licence
  • Very fine control over every mark on the page
  • Modular, so a project can pull in only the parts it needs
  • Large official gallery of examples to adapt
  • Works with React, Vue, Svelte and plain JavaScript

Cons

  • Steep learning curve; there are no ready-made chart types
  • Even a basic chart takes a fair amount of code
  • Overkill for quick dashboards, as the project itself says
  • TypeScript type definitions come separately from DefinitelyTyped

Community Reviews (0)

No written reviews yet — be the first to rate this tool.

Similar Tools

  • Developer Libraries · Lodash

    Provides utility functions for common JavaScript programming tasks.

    Not yet rated
    Open Source Web
  • Developer Libraries · jQuery

    Simplifies DOM manipulation, event handling, and AJAX in JavaScript.

    Not yet rated
    Open Source Web
  • Developer Libraries · Bootstrap

    Provides pre-built responsive CSS components and layout tools.

    Not yet rated
    Open Source Web
  • Developer Libraries · Tailwind CSS

    Styles web pages using utility classes instead of custom CSS.

    Not yet rated
    Open Source Web