Skip to content

Wayfinding

Pro & EnterpriseWayfinding setup requires a Pro or Enterprise subscription.
Compare plans

Wayfinding lets visitors find the fastest route between any two points on your map, including across multiple floors.

How It Works

  1. Visitor selects an origin (area or marker)
  2. Visitor selects a destination
  3. Layota calculates the shortest path and displays it on the map
  4. If the route crosses floors, the path is split into segments with transition indicators

Setting Up Wayfinding

1. Draw Corridors

Corridors are walkable paths on each level. Open the Wayfinding panel in the editor and draw corridor lines connecting areas and markers.

Wayfinding panel in the editor

2. Add Floor Transitions

Place transition points (elevators, stairs, escalators) that connect corridors across levels. Each transition connects a point on one level to a point on another.

3. Connect Areas and Markers

Link areas and markers to nearby corridor points so the routing engine knows how to reach them.

Route via SDK

Build and display routes programmatically:

typescript
map.buildRoute(
  { id: 'entrance', type: 'area', levelId: 'floor-1' },
  { id: 'cafe',     type: 'area', levelId: 'floor-2' }
)

// Clear the displayed route
map.clearRoute()

The routeBuilt event fires when a route is calculated:

typescript
map.on('routeBuilt', ({ route, levelId }) => {
  console.log('Total distance:', route.totalDistance)
  console.log('Segments:', route.segments.length)
})

map.on('routeNotFound', () => {
  console.log('No route available')
})

Route Result

typescript
interface RouteResult {
  segments: RouteSegment[]
  totalDistance: number
}

interface RouteSegment {
  levelId: string
  points: RoutePoint[]
}

interface RoutePoint {
  x: number
  y: number
}

Each segment represents a portion of the route on a single floor. Multi-floor routes have multiple segments.

Layota Documentation