Try online!

GraphHopper is a fast and Open Source road routing engine.

Overview

GraphHopper offers memory efficient algorithms in Java for routing on graphs. E.g. Dijkstra and A* but also optimized road routing algorithms like Contraction Hierarchies. It stands under the Apache License and is build on a large test suite.

License

We chose the Apache License to make it easy for you to embed GraphHopper in your products. We suggest to contribute back your changes (as GraphHopper will evolve fast) but of course this is not necessary.

OpenStreetMap Support

OpenStreetMap is directly supported from GraphHopper. Without the amazing data from OpenStreetMap GraphHopper wouldn't be possible at all. Other map data will need a custom import procedure.

Development

Development happens at GitHub. You can clone the project at GitHub.

Written in Java

GraphHopper is written in Java and runs on Linux, OS X, Windows, Raspberry Pi and Android. Other environments which supports at least Java 5 will work too.

Android

On Android we provide an integration with Mapsforge which makes offline navigation one step closer. Due to the usage of memory mapped files and Contraction Hierarchies we avoid allocating too much memory which makes it possible to run Germany-wide queries with only 32MB in a few seconds. We provide an Eclipse project as well as the Maven-Android integration to be used in other IDEs.

Web

With the web module we provide code to query GraphHopper over HTTP and decrease bandwidth usage as much as possible. For that we use the polyline encoding from Google, the Ramer–Douglas–Peucker algorithm and a simple GZIP servlet filter. On the client side we provide Java and JavaScript code (via Leaflet) to consume that service and visualize the routes.

Desktop

GraphHopper also works on the Desktop in a Java application without internet access. E.g. you could use the rough user interface called MiniGraphUI provided in the tools module. To have a proper and fast map visualization we'll have to wait for mapsforge 0.4 which will support the desktop via Swing/AWT. Or you have to use an older version of it. Ask on the mailing list for more up to date information.

Customizable API

We've build the GraphHopper class which makes simple things easy. Still you can use the low level API of GraphHopper and you'll see that it was created to allow fast and memory efficient use of the underlying datastructures and algorithms.

Features

  • Written in Java and runs under Linux, Windows, Android, ...
  • Business friendly due to Apache License 2.0, commercial support and ... see below!
  • Based on many unit and integration tests
  • Memory efficient data structures, algorithms and also the API is tuned towards ease of use and efficiency.
  • Very fast. And via the speed-up technic called "Contraction Hierarchies" it can be even faster - CH is enabled by default.
  • Simple installation - just Java necessary! Simple setup for developers due to Maven.
  • Has algorithms ala A*, Dijkstra and the bidirected versions, plus one-to-many cases
  • Works out of the box with OpenStreetMap (osm and pbf) but can be adapted to use your own data
  • OpenStreetMap integration: Takes care of the road type, the surface, barriers, access restrictions, ferries, ...
  • Uses only a few dependencies (trove4j and slf4j)
  • Scales from small indoor- to world-wide-sized graphs
  • Can be used on mobile devices with less than 32MB. For Android we additionally provide a demo with mapsforge.
  • Supports car, bicycle, pedestrian vehicles by default. But you can easily create your own or customize existing vehicles.
  • The web module provides GraphHopper routing as a service which can be accessed via Java or JavaScript.
  • The web module returns highly compressed paths via gzip and polyline encoding.

Community

Download

0.2 release, 23-Nov-2013

Android Application (apk 0.2)
Solved Issues for 0.2

Maven

Support GraphHopper - Get your shirt!
Unstable 0.3
Android Application (apk 0.3)
Open Issues of 0.3
0.1.1 release, 06-Aug-2013
Android Application (apk 0.1.1)
Solved Issues for 0.1 and 0.1.1

Contact

Click to route


Email: email

Please ask questions on Stackoverflow or sign up to our mailing list!

GraphHopper Enterprise

We offer different solutions besides GraphHopper itself to make routing simple and flexible. Routing problems occur in a wide range of applications: From outdoor planning to optimization in logistic software; from touristic apps to ridesharing websites - we offer the right and optimized package for you!
Consulting
We provide training, support, development and hot fixes. Or a custom GraphHopper installations with maintenance and support.
Contact Us
The Consulting package is for companies ...
  • that don't want to waste time digging into GrapHopper or routing algorithms
  • that need fast one-time support or a support/maintenance contract
  • with developers who want to learn GraphHopper fast
  • that don't want to host own custom GraphHopper installations
  • that need support with their custom hosted GraphHopper solution
GraphHopper Web API
A hosted solution of GraphHopper which is fast, easy to use and reliable - see the documentation or try GraphHopper Maps for a showcase.
Get Invitation
The Web API is for companies ...
  • that need a fast routing solution with world wide coverage
  • that need a routing solution based on OpenStreetMap which does not limit your use case. I.e. navigation applications are allowed.
  • that need a cost effective routing solution for bicycle, walking and car [1].
  • that need Geocoding
[1] Car routing is currently without turn restrictions.

Pricing - GraphHopper Web API

It will take you only a few minutes to get started with our Web API - pick a package and get started! There are no risks as you can try it free for 7 days.
Package
Price per month 1
Requests per day
Routing API
Geocoding API
Support 2
White-label 3
Standard
109 €
14,000 per day
V
V
V
No
Premium
249 €
40,000 per day
V
V
V
V
Custom
Custom
Custom
V
V
V
V
In 2014 you pay 20% less if paid annually, in 2015 and later we offer a 10% discount. We'll add more features as they come and you can use them for free. Servers will located in Germany or France. For more details read our complete terms.
  1. Prices do not include taxes.
  2. All packages include free online support, software and daily OpenStreetMap data updates. For the custom package a dedicated support contract can be bought.
  3. For packages with the white-label offer you do not need to display a prominent link to GraphHopper.com nearby the search results.

The GraphHopper Team says thanks to

  • OpenStreetMap - the best map data world wide!
  • NetBeans - for the best Java IDE!
  • YourKit is kindly supporting open source projects with its full-featured Java Profiler. YourKit, LLC is the creator of innovative and intelligent tools for profiling Java and .NET applications.
  • Xubuntu, Trove4J, Log4J, Guice, Maven and other Open Soure software.
  • Images and icons for our website via Wikipedia, and famfamfam icons!