2026-11-16
React Flow 13.0.0
React Flow 13 is here! It focuses on performance and
developer experience: the internal store is split into multiple smaller stores with fine-grained
subscriptions, the library is compiled with the React Compiler, and there are new hooks like
useNode, useEdge and useEqualSelector. On top of that, React Flow now follows the system color
mode by default, ships an optional xy-theme.css and puts all styles in @layer xyflow.
If you want the bigger picture, read the React Flow 13 announcement on our blog.
This release contains breaking changes. Check out the migration guide for everything you need to update when upgrading from React Flow 12.
Major Changes
- #6114 - Align the connection APIs across all frameworks on
NodeConnection.- Remove
getHandleConnections. UsegetNodeConnections({ nodeId, type, handleId })instead:idis renamed tohandleIdandtypeis optional. HandleConnectiontype removed: useNodeConnectioninstead.
- Remove
- #6117 -
onConnectEndandonReconnectEndnow receivetoin flow coordinates instead of screen coordinates. - #5915 - Remove requirement of parent nodes to appear before child nodes in the nodes array.
- #5927 - Use 5% as new default padding for
fitViewandfitBounds. - #5866 - Remove deprecated
useHandleConnectionshook. - #5800 - Replace
useStorewithuseNodesStore,useEdgesStore,useViewportStore,useOptionsStore,useConnectionStoreanduseSelectionStore. They no longer accept an equality function, useuseShallowinstead. - #5996 - Performance: Move options, nodes, edges, selections and connection into separate stores.
- #6115 - Replace
paneClickDistancewithpaneDragThreshold(default1). LikenodeDragThreshold, the pane only starts panning or selecting once the pointer has moved further than the threshold; otherwise it counts as a click. Works with every mouse button. - #5843 - Use system color mode by default, add
forceColorModeto opt-out. - #5556 - Remove
nodeClickDistance. Whether a click on a node fires is now determined solely by whether a drag actually moved the node: clicks are suppressed only after a drag changed node positions. UsenodeDragThreshold(andsnapGrid) to control this. - #5987 - Rename the measured handle geometry type from
HandletoHandleBoundsso it no longer collides with the<Handle />component. - #5927 - Numbers passed to
fitViewOptions.paddingare interpreted as pixel values instead of legacy units. Use percentage values instead (0.1 ≈ 4.5%, 0.5 ≈ 16.7%, 1 ≈ 25%, 2 ≈ 33%). - #5866 - Require React 18 as minimal supported version.
- #5944 - Pass
NodeChangeset/EdgeChangesetclass toonNodesChange/onEdgesChange. - #5866 - Remove UMD build.
Minor Changes
- #5939 - Add
changeParenttouseReactFlowto easily change the parent of a node without calculating a new position. - #5978 - Elevate selected edges by default (
elevateEdgesOnSelectnow defaults totrue), so overlapping edges can be reconnected by selecting them first. - #5844 - Exported styles now live in
@layer xyflow. - #5996 - Performance: Add fine grained reactivity when subscribing to specific nodes and edges.
- #5866 - Add style import from
@xyflow/react/style.css. - #5993 - Add
xy-theme.cssstylesheet (@xyflow/react/xy-theme.css) that ships the xyflow default theme on top ofbase.css. - #5996 - Performance: Compile library with React Compiler.
- #5939 - Add
useNodeanduseEdgehooks for subscribing to changes to specific nodes & edges. - #6099 - Add
useEqualSelectorhook.
Patch Changes
- #5866 - Include source maps and src folder in package. “Go to definition” now links to the source code instead of the generated types.
- #6084 - Fix resizing nodes with a fixed extent & a non-default origin.
- #5989 - Prevent jumping nodes when
nodeOriginis used. - #6064 - Resolve the promises of animated viewport functions like
fitViewandsetCenterwithfalsewhen a user interaction or another viewport change interrupts the animation, instead of leaving them pending. - #6131 - Narrow
databytypewhenNodePropsreceives a union of node types. - #6103 - Fix missing edges when controlled node updates overlap with node measurement.
