Nodes and links sized by value
Define stages with SankeyNodeDirective and flows with SankeyLinkDirective, from sourceId to targetId. Link width shows the value, which suits energy distributions and process flows.
AI · MCP Server and Agent Skills included
Show how values flow between stages with nodes and links sized by value, horizontal or vertical layouts, labels, link colors, legends that highlight flows, tooltips, and print and export. AI assistants set it up for you from the current docs.
Trusted by the world’s leading companies
Now easier with AI
Coding assistants write the Sankey setup from the current docs instead of guessing.
01For developers
The Syncfusion MCP server and Agent Skills give assistants in VS Code, Cursor, and JetBrains the current Sankey docs and recommended patterns.
AI coding assistantMCP Server · Syncfusion React
Show energy flowing from solar and wind to electricity.
search_docs“React Sankey nodes and links” · 2 doc sections
Excerpt: imports and sample data omitted.
<SankeyComponent title="Energy flow">
<SankeyNodesCollectionDirective>
<SankeyNodeDirective id="Solar"
/><SankeyNodeDirective id="Wind" />
<SankeyNodeDirective id="Electricity" />
</SankeyNodesCollectionDirective>
<SankeyLinksCollectionDirective>
<SankeyLinkDirective sourceId="Solar"
targetId="Electricity" value={30} />
<SankeyLinkDirective sourceId="Wind"
targetId="Electricity" value={25} />
</SankeyLinksCollectionDirective>
</SankeyComponent>
Documented API: SankeyNodeDirective, SankeyLinkDirective, sourceId, targetId
ResultRendered in your app
AI coding assistantMCP Server · Syncfusion React
Draw the flow from top to bottom.
search_docs“React Sankey vertical orientation” · 2 doc sections
Excerpt: imports and sample data omitted.
<SankeyComponent orientation="Vertical">
<SankeyNodesCollectionDirective>…</SankeyNodesCollectionDirective>
</SankeyComponent>
Documented API: orientation
ResultRendered in your app
AI coding assistantMCP Server · Syncfusion React
Color each link like its source node and soften the curves.
search_docs“React Sankey link colors and curves” · 2 doc sections
Excerpt: imports and sample data omitted.
<SankeyComponent
linkStyle={{ colorType: 'Source', curvature: 0.5, opacity: 0.6 }}
nodeStyle={{ width: 20, opacity: 0.85 }} />
Documented API: linkStyle, colorType, nodeStyle
ResultRendered in your app
AI coding assistantMCP Server · Syncfusion React
Show node totals and link amounts in TBtu in the tooltip.
search_docs“React Sankey tooltip templates” · 2 doc sections
Excerpt: imports and sample data omitted.
<SankeyComponent tooltip={{ enable: true,
nodeTemplate: '${name}: ${value} TBtu',
linkTemplate:
'${start.name} → ${target.name}: ${target.in} TBtu'
}}>
<Inject services={[SankeyTooltip]} />
</SankeyComponent>
Documented API: tooltip, nodeTemplate, linkTemplate
ResultRendered in your app
AI coding assistantMCP Server · Syncfusion React
Add a legend at the bottom that highlights the flows of a node.
search_docs“React Sankey legend with flow highlighting” · 2 doc sections
Excerpt: imports and sample data omitted.
<SankeyComponent
legendSettings={{ visible: true, position: 'Bottom',
enableHighlight: true }}>
<Inject services={[SankeyLegend]} />
</SankeyComponent>
Documented API: legendSettings, enableHighlight, SankeyLegend
ResultRendered in your app
AI coding assistantMCP Server · Syncfusion React
Add buttons that export the diagram to PDF and print it.
search_docs“React Sankey print and export” · 2 doc sections
Excerpt: imports and sample data omitted.
const sankey = useRef<SankeyComponent>(null);
<SankeyComponent ref={sankey}>
<Inject services={[SankeyExport]} />
</SankeyComponent>
<button
onClick={() => sankey.current?.export('PDF', 'energy-flow')}>
Export PDF</button>
Documented API: export, print, SankeyExport
ResultRendered in your app
AI coding assistantMCP Server · Syncfusion React
Make the node labels bold and show each node with its total, such as Solar 30.
search_docs“React Sankey node labels” · 2 doc sections
Excerpt: imports and sample data omitted.
<SankeyComponent
labelSettings={{ visible: true, fontWeight: '700' }}>
<SankeyNodesCollectionDirective>
<SankeyNodeDirective id="Solar"
label={{ text: 'Solar 30' }} />
</SankeyNodesCollectionDirective>
</SankeyComponent>
Documented API: labelSettings, label, text
ResultRendered in your app
AI coding assistantMCP Server · Syncfusion React
When users hover a flow, keep it bright and fade every other flow.
search_docs“React Sankey hover highlighting” · 2 doc sections
Excerpt: imports and sample data omitted.
<SankeyComponent
linkStyle={{ opacity: 0.35, highlightOpacity: 0.9,
inactiveOpacity: 0.1 }}>
<SankeyLinksCollectionDirective>…</SankeyLinksCollectionDirective>
</SankeyComponent>
Documented API: linkStyle, highlightOpacity, inactiveOpacity
ResultRendered in your app
Accessibility
The React Sankey component follows WAI-ARIA practices, with keyboard access and screen reader support.
Features in depth
Open a demo to try each one, or the docs to see the API.
Define stages with SankeyNodeDirective and flows with SankeyLinkDirective, from sourceId to targetId. Link width shows the value, which suits energy distributions and process flows.
nodeStyle sets node width, fill, stroke, and opacity. linkStyle colors links by source, target, or a blend of both, with its own curvature and opacity. The animation setting animates the diagram as it renders.
Labels annotate each node, and labelSettings styles their font, color, and padding. A title and subtitle describe the diagram and its source.
Handle nodeClick and linkClick, react when the pointer enters or leaves a node or link, and change nodes, links, and labels as they render.
Keyboard navigation and WAI-ARIA support follow WCAG 2.2 and Section 508 guidelines. The layout adapts to desktops and phones, with Tailwind CSS, Bootstrap, Material, Fluent, and Fabric themes.
Get started
With an AI coding assistant
Add a Syncfusion React Sankey chart to my energy report showing flows from solar, wind, gas, and coal to electricity and heat, and on to homes, industry, and transport.
By hand, in three steps
1 · Install
npm install @syncfusion/ej2-react-charts --save
2 · Theme
<SankeyComponent theme="Tailwind3" />
3 · src/App.tsx
import { SankeyComponent, SankeyNodesCollectionDirective, SankeyNodeDirective, SankeyLinksCollectionDirective, SankeyLinkDirective } from '@syncfusion/ej2-react-charts';
export default function App() {
return (
<SankeyComponent theme="Tailwind3">
<SankeyNodesCollectionDirective>
<SankeyNodeDirective id="Solar" />
<SankeyNodeDirective id="Electricity" />
</SankeyNodesCollectionDirective>
<SankeyLinksCollectionDirective>
<SankeyLinkDirective sourceId="Solar" targetId="Electricity" value={30} />
</SankeyLinksCollectionDirective>
</SankeyComponent>
);
}
Works withReact 15.5.4 or laterTypeScript and JavaScriptNext.jsRemixGatsbyVitePreactSystem requirements
Customer reviews
“Awesome, enough said”
Easy usability, solving real-life problems, easy to implement. Most of the cases have the operators and settings possibilities you need right away.
“A giant framework with great pricing options”
I have loved the components and options that Syncfusion has; besides, its documentation, demos, and support are excellent.
Customer story · Igniatek
“I would definitely recommend Syncfusion for anyone who is trying to develop something meaningful.”
Somnath Maji, Founder, Igniatek Consultancy
Including the 2026 Devies Award, Capterra Shortlist 2026, Software Advice FrontRunners 2026, and G2 Best Software 2025.
Complete feature list
Showing all 25 features. Each one opens its demo or documentation.
No feature matches that search. Try another word, or open the Sankey demos.
Related data visualization components:React ChartsReact Stock ChartReact HeatMapReact Circular Gauge
Questions and answers
The Syncfusion React Sankey Diagram shows how a quantity moves between stages of a process. Nodes are the stages, and the width of each link shows the amount. Explore the demos
Use it to show transfers across stages, such as energy from sources to uses or users through a funnel, where the size of each flow matters. React Charts
Install @syncfusion/ej2-react-charts and render SankeyComponent with a SankeyNodeDirective for each stage and a SankeyLinkDirective for each flow. Read the getting started guide
Give each node an id, and give each link a sourceId, a targetId, and a value. Read about links
Yes. Set orientation to Vertical; the default is horizontal. Vertical mode demo
Set linkStyle.colorType to Source, Target, or Blend, the default, which blends the colors of both nodes. Read about customization
Yes. Inject SankeyTooltip and set nodeFormat and linkFormat, or nodeTemplate and linkTemplate. Read about tooltips
Yes. Inject SankeyLegend and set legendSettings.enableHighlight to true. Hovering a legend item then highlights its links. Read about the legend
Yes. Handle nodeClick and linkClick, or the enter and leave events, to show details or filter other views. Read about events
Yes. Inject SankeyExport to export PDF, PNG, JPEG, or SVG on the client, and call print to print it. Print and export demo
Yes. Keyboard navigation and WAI-ARIA support follow WCAG 2.2 and Section 508 guidelines. Read about accessibility
Yes. The Syncfusion MCP server and Agent Skills give assistants in VS Code, Cursor, and JetBrains the current Sankey docs and recommended patterns. You need a Syncfusion API key and an active license, which can be a commercial, Community, or trial license. Set up the MCP server
It is a commercial component with a 30-day free trial. A free Community License is available for companies and individuals with less than $1 million USD in annual gross revenue, five or fewer developers, and 10 or fewer total employees. Check Community License eligibility
Resources
Sankey for other frameworks:AngularJavaScriptVue
More React components:ChartsDiagramTreeMapAll 140+ React components
Syncfusion React Sankey
The full Sankey Diagram, the MCP server, and Agent Skills, free for 30 days.