Adding directions to leaflet map

How can I add directions to a leaflet map? If possible please could you link me to or provide sample code? This is the example response for the json: .

P.S. Apologies for the ad but this is the fastest temp url shortener I found

Hi @Armaan_Mehta,

There are different ways to do this, but none of them are related to ORS itself.
The directions are stored in the steps property of each route segment.
How you display them (entries in a sidebar, popup on the route) is up to you.
You can check out our client, to look how we do it.

Best regards


I’m working on Lealflet Map and a plugin extend the Leaflet Routing Machine plugin.
Take à look at:

The source of map using this plugin is here


1 Like

my plugin is now on npmjs:

For the map mentioned above, I modified a bit the code of the Leaflet Openroute Service plugin.I’ll probably send a merge request with my improvements to the author… or create a fork with the included plugin.