Blog / Sankey

    How to make a Sankey diagram from Excel data

    Excel has no Sankey chart type. Three ways to get one from Excel data, what each costs in time, and how to prepare the sheet.

    , 5 min read

    Excel has no built-in Sankey chart. You can install an add-in, imitate one with stacked areas, or use a Sankey tool with the data from your sheet. For a single diagram, the third way is the fastest.

    Prepare the sheet first

    All three ways start from the same table: one row per flow with source, target and value. If your data is a matrix with sources in rows and targets in columns, turn it into a list with Power Query: select the table, choose Data, From Table/Range, select the first column, then Transform, Unpivot Other Columns.

    sourcetargetvalue
    WebsiteLead600
    EventLead250
    LeadCustomer180
    LeadLost670

    Way 1: an Excel add-in

    Add-ins from the Office store draw a Sankey diagram inside the workbook and update it when cells change. Choose this when the diagram is part of a report you refresh every month. Check the price, and whether your company allows add-ins to read workbook data.

    Way 2: stacked areas by hand

    Each band becomes a stacked area with a smooth transition calculated in helper columns. It works without any add-in, but you need helper rows for every flow and invisible areas for the gaps. Beyond two levels it takes hours, and one changed value can shift everything.

    Way 3: a Sankey tool

    Save the three columns as a workbook or CSV and attach the file. This is the diagram for the table above.

    One in five leads becomes a customer
    Website 600Lead 850Event 250Customer 180Lost 670

    The PNG goes straight into Excel, Word or PowerPoint. The SVG stays sharp at any size.

    Which way fits

    Add-inBy handSankey tool
    Updates with the workbookYesYesNo, attach the file again
    Time for the first diagramMinutes plus installationHoursMinutes
    More than two levelsDepends on the add-inImpracticalYes
    Needs permission to installOftenNoNo

    When the diagram looks wrong

    • Separate pieces: a name is spelled in two ways, or has a space at the end. Use TRIM in Excel.
    • An error about a loop: a flow returns to an earlier step. Rename the second visit, for example "Lead (second contact)".
    • A gap on a node: inflow and outflow differ. Add the missing flow.

    For ready-made structures, use the income statement or the budget template.