This tutorial is a quick intro to D3.js, a Javascript library for creating interactive data visualizations in the browser. D3 is built on top of common web standards like HTML, CSS, and SVG.

This is not designed to be a deep dive — this tutorial will teach you how to learn D3 and give you a high-level understanding of this powerful tool.

This tutorial is a fork of Square’s Intro to D3 tutorial, updated to reflect APIs introduced in newer versions of D3.

Older Versions

This tutorial is meant for D3 v5-v7. Major versions of D3 frequently come with breaking changes, so the code from this tutorial may not run if you are using older versions of D3.

If you want to view a version of the tutorial compatible with older versions of D3, check out the archived source code here:

Let’s get started!