Skip to main content

Route connectors around shapes automatically

From version 30.1.13 onwards, draw.io can automatically route connectors around the shapes in your diagram. An auto-routed connector takes a path with right-angled bends that doesn't cross other shapes.

Auto-route a connector​

  1. Select one or more connectors.
  2. Click Waypoints in the Style tab of the format panel.
  3. Select Auto-route around shapes.

Auto-routed connectors automatically find new paths whenever you:

  • move or resize one of its connected shapes.
  • move or add a shape on its path, or move a shape away from its path.
  • connect it to a different shape.

From version 31.6.2 onwards, auto-routed connectors will also be routed again when you align, distribute or rotate shapes, change their position or size in the Arrange tab, or apply a layout from Arrange > Layout.

While dragging a shape to reposition it, you will see the new path of each auto-routed connector.

Tip: To auto-route all newly added connectors, select an auto-routed connector, then click Set as Default Style in the Style tab.

Turn auto-routing off​

Note: Auto-routing has no effect on connectors inside containers that arranges contents automatically, such as a list shape or layout shape.

Route connectors around shapes once​

Use the Orthogonal Routing layout to route connectors around shapes a single time. The shapes don't move, and the connectors will not be auto-routed afterwards.

  1. Select the connectors you want to route. All connectors will be routed if nothing is selected.
  2. Select Arrange > Layout > Orthogonal Routing from the menu.
  3. Enter the Spacing between the connectors and the shapes, then click OK.

The connector style will be changed to orthogonal connectors with waypoints that go around the shapes.