Skip to main content
Workforce LibreTexts

9.2.4: Sankey Diagrams (Flow Diagrams for Quantitative Flows)

  • Page ID
    53352
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \( \newcommand{\dsum}{\displaystyle\sum\limits} \)

    \( \newcommand{\dint}{\displaystyle\int\limits} \)

    \( \newcommand{\dlim}{\displaystyle\lim\limits} \)

    \( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)

    ( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\id}{\mathrm{id}}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\kernel}{\mathrm{null}\,}\)

    \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\)

    \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\)

    \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    \( \newcommand{\vectorA}[1]{\vec{#1}}      % arrow\)

    \( \newcommand{\vectorAt}[1]{\vec{\text{#1}}}      % arrow\)

    \( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vectorC}[1]{\textbf{#1}} \)

    \( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

    \( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

    \( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

    \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \(\newcommand{\longvect}{\overrightarrow}\)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \(\newcommand{\ket}[1]{\left| #1 \right>}\)
    \(\newcommand{\bra}[1]{\left< #1 \right|}\)
    \(\newcommand{\braket}[2]{\left< #1 \vphantom{#2} \right| \left. #2 \vphantom{#1} \right>}\)
    \(\newcommand{\braopket}[3]{\left< #1 \vphantom{#2}\vphantom{#3} \right| #2 \vphantom{#1}\vphantom{#3} \left| #3 \vphantom{#1}\vphantom{#2} \right>}\)
    \(\newcommand{\qmvec}[1]{\mathbf{\vec{#1}}}\)
    \(\newcommand{\op}[1]{\hat{\mathbf{#1}}}\)
    \(\newcommand{\expect}[1]{\langle #1 \rangle}\)
    \(\newcommand{\dfn}[1]{\emph{\textbf{#1}}}\)

    \(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)

    Sankey Diagrams (Flow Diagrams for Quantitative Flows)

    A Sankey diagram is a type of flow diagram where the width of the connecting flows is proportional to the quantity flowing from one stage to the next. It consists of nodes (usually drawn as rectangles or text labels) and links (often drawn as arrows or bands) connecting the nodes; the links have varying thickness to indicate the volume of whatever is flowing. Sankey diagrams are named after Captain Matthew Sankey, who used this format in the 19th century to visualize energy losses in steam engines. The hallmark of a Sankey is that it visually emphasizes the magnitude of flow between stages, making it immediately clear where the largest flows or drop-offs occur [11].

    When to use a Sankey diagram: Sankey charts are ideal for showing flows and transformations of resources, especially when material, energy, cost, or people move through a series of stages or categories. Classic uses are in energy flow diagrams (showing how energy input splits into various outputs or losses), budget allocation (money flowing into different expenditures), and process funnels. For example, in web analytics or marketing, a Sankey can illustrate an e-commerce conversion funnel: from 100% of website visitors, what portion click on a product, then what portion add to cart, then proceed to checkout, and finally purchase. The diagram will show progressively thinner bands if large drop-offs occur at each stage, vividly highlighting where most users fall off. Another example is a hiring process: out of all applicants (left node), some proceed to interview (next node), then some get offers, then hires – the Sankey bands between these stages show proportions at each transition. The lecture slides refer to turning data into stories; Sankey diagrams often tell a story of movement, making complex processes easier to grasp at a glance, which aligns with the goal of using visuals to communicate insights clearly.
    A Sankey diagram depicting a hiring funnel. Details in caption.

    Figure \(\PageIndex{1}\): A Sankey diagram depicting a hiring funnel (simplified example). Each stage of the process is a node (Applicants, Interviews, Offers, Hires), and the flows between them are drawn with widths proportional to the number of candidates moving from one stage to the next. This visual immediately highlights drop-offs (e.g. the large drop from Applications to Interviews), making it an effective storytelling tool for process data. In this example, out of 52 applicants, only 7 reached the interview stage and 1 was hired, as indicated by the narrowing bands. (CC BY 4.0; Felix Amoruwa) Access to a detailed description of Figure \(\PageIndex{1}\)

    Sankey Diagram. Details in caption.

    Figure \(\PageIndex{2}\): Sankey Diagram — E-Commerce Conversion Funnel. A Sankey flow diagram illustrating user progression through an e-commerce purchase funnel, from website visit through product view, add-to-cart, checkout, and purchase, with band widths proportional to user volume at each stage, highlighting major drop-off points. (CC BY 4.0; Felix Amoruwa) Access to a detailed description of Figure \(\PageIndex{2}\)

    The strength of Sankey diagrams is in comparing flow quantities. They answer questions like: Where does the quantity go? Which path carries the most weight? In an organization’s budget, a Sankey might show that the largest portion of funding flows into Operations, a smaller but significant portion into R&D, etc., which is more informative than a simple list of numbers. They also show how flows split or merge. For instance, in an energy Sankey: 100 units of energy enter, perhaps 30 units flow to electricity generation, 20 to transportation, etc., and within electricity, those 30 might further split into residential, commercial, industrial usage, and so on.

    However, Sankey diagrams can become unwieldy if there are too many nodes or if the flow structure is very complex (lots of crossing bands). They generally work best for relatively coarse stages (not dozens of distinct stages). Another consideration: if exact numerical comparison is needed, the reader has to rely on the width of bands, which is less straightforward than reading a bar length. Therefore, Sankeys are more for pattern and proportion (good for an overview of where the largest losses or contributions are) rather than precise value lookup.

    In terms of tools, creating Sankey diagrams is possible in Tableau (there are community hacks since it’s not a native chart), in Power BI (with custom visuals), and certainly with code libraries like D3 (which has a Sankey plugin) or Plotly. Google Charts and other libraries also support Sankeys. Data preparation for Sankey often requires summarizing flows between each pair of stages.

    Use Sankey diagrams when you need to trace the flow of quantities through a system or process and you want to focus on volumes and drop-offs. They are highly effective in presentations where you need to tell a story of attrition or distribution, as the visual weighting naturally draws attention to major vs. minor flows, embodying the adage “a picture is worth a thousand words.” Indeed, good Sankey diagrams have been described as enabling data to “tell its story” clearly by mapping numbers to an intuitive flow image.


    This page titled 9.2.4: Sankey Diagrams (Flow Diagrams for Quantitative Flows) was last modified on Thu, 17 Sep 2026 21:51:25 GMT and is shared under a CC BY 4.0 license and was authored, remixed, and/or curated by Felix Amoruwa.

    • Was this article helpful?