From OpenStreetMap Wiki
Jump to: navigation, search

Because we all deal with similar problems and use the same data model you don't have to invent the wheel twice. Feel free to build upon the work of others.

Single Purpose Client Libraries for API0.6 (the RESTful API)

Language Name API 0.6? XAPI Notes
Java ? ? ? JOSM and Osmosis codebases have element class representations
Perl [library] No No None
PHP PHPosm Yes No Last change: 2009-12-04
PHP Services_Openstreetmap Yes No Also allows access to User details and includes partial support for querying Nominatim servers (reverseGeocoding and search by place-name). Went through PEAR PePr process
Python osmapi Yes No None
R osmaR Yes ?

Ruby OSMLib Yes No
Ruby Rosemary Yes ?

Data Processing or Parsing Libraries

Functionality that is encapsulated in shared libraries

Name License Code Description dependencies
CartoType commercial; free for evaluation and non-commercial use C++, C# Flexible offline rendering, routing engine open data format (CTM1)
imposm parser Apache2 Python Process PBF and OSM XML files protobuf
osmread Python Simple library for reading XML and PBF data files protobuf, lxml
J2memap non commercial J2ME Provider independent maps with overlays
libosm GPL v3 C read .osm and .pbf protobuf
libOSM (fr) GPL v3 C++ Store/update OSM datas in SQLlite database Spatialite, XML eXpat parser, Geos, Proj4
osmpbf GPL v3 C++ based on iterator concept protobuf,cmake
libosmscout LGPL C++ raw data parsing and preprocessing, database functionality, offline vector map drawing, offline routing (all based on preprocessed data) libxml2 (*.osm and config file parsing), protobuf (parsing, optional), cairo (driver, optional), Qt (, driver, for some demos, optional), libagg (driver, optional), libillumination (for some demos, optional)
libRoadNav LGPL C++ Maps and routing, seem to be outdated wx
MapJumper JS Map Bookmarking, sharing Map configs
OSM common ASL2 Java Overpass, Nominatim, Change set servers; osm.xml parsing and processing; etc. -
Objective CAML OSM Parser WTFTPL OCAML Parses the basic objects of a .osm file -
osm4routing Python, C++ Routing
OSMLib Ruby Datas,SQLlite export, Nominatim search Part of The Rails Port
OsmSharp GPLv2 (Commercial Licence can be bought) C# Datas,Routing, display
Perl Scripts Perl Statistics, API, Data processing
Pyrender GPLv3 Python Tile rendering pyCairo, PIL
PyrouteLib Python Simple A* router on .osm files pycairo
Pyroutelib2 GPL3+ Python Routing with custom vehicles and dislplaying the result python builtin packages only
Routino Routing
Smrender GPLv3 C Offline paper chart rendering and modular OSM data processing. libgd
Gisgraphy LGPL Java Geocoding/reverse geocoding, fulltextsearch, find nearby webservices and importers for osm data
GraphHopper Apache 2.0 Java Routing engine for car, bike and more. Can be used as web service, android library, iOS library or Java library.
BRouter GPLv3 Java bike routing and features elevation awareness, alternatives, fully configurable routing profiles and offline routing for Android
PGMapCSS GNU Affero General Public License 3.0 PGMapCSS is a library for PostgreSQL/PostGIS which works between an osm2pgsql based database and Mapnik (and maybe other renderers)
TileMan [1] GPLv3 Framework for serving OSM based tiles
osm-read LGPLv3 JavaScript Openstreetmap XML and PBF data parser for node.js and the browser
Geow Apache2 Scala Lightweight framework for processing OSM data
OSMemory LGPLv3 Java Library for validators with o5m fast reader. It loads data to memory that allow to use osm data without PostgreSQL JTS
BasicOSMParser GPLv3 Java A XML data parser to manipulate OSM objects in Java, also able to do CSV exports

See also:


Bigger suites offering an complex structure of replaceable modules that work together.

Name License Code Bindings Functions Dependencies Description
CloudMade commercial Java,C++,JS,Python,More Many map related functions. iPhone/Android/Mobile
skobbler commercial Objective C, Java, Javascript Routing, Rendering, Turn By Turn Navigation, Map styling & more for iPhone/Android/Web For full feature set check feature list
Mapbox commercial Objective C, Java, Javascript Rendering, Map styling, Routing, Best Leaflet plugin & more for iPhone/Android/Web For list of supported platforms check developer platform
Osmium C++,JS JavaScript, Python Data Processing
Osmosis Java Data Processing
OSMNavigation GPL Java Routing, Rendering, GPS technologies in a plugin framework
libOSM GPL Java Framework with plugins for fileformats osmosis


Widgets that allow you an easy integration of OSM into your software.

Name License Code Bindings Functions Dependencies Description
BruTile LGPL Silverlight, C# display Slippy Map
COSMCtrl 1.1.3 freeware C++ C++ display,marker,gps,drawing MFC,GPSCom2 GDI Widget
Halcyon PD Flash rendering
JXMapViewer Java display, markers Slippy Map for SWING
JXMapViewer2 LGPL 3 Java display, markers, caching Based on JXMapViewer
JMapViewer GPL Java display, markers Slippy map independent of SWING
JXMapKit Java display, markers SwingX Slippy Map for SWINGX
kogutowicz Apache 2.0 lic. Java rendering
libchamplain 0.4.4 LGPL 2.1+ C++, C#, Perl, Python display,marker Clutter Gnome Widget
libmemphis LGPL C JS, Vala rendering cairo GObject GLib
Maemo Map Display component display
Maep display Maemo Widget for Maemo
map::slippy BSD-ish Tcl/Tk display Tk, tcllib Widget for Tcl/Tk
Mapsforge[2] LGPLv3 Java Offline Rendering Android
Marble LGPL C++ Python, QML display, caching, gps, routing Qt Widget for Qt
MGMapsLib GPL J2ME display,marker Java widget
Nutiteq Android Mapping API SDK commercial Java display,caching,vextors Online Maps API for Android and J2ME
OSM4j Java
OpenStreetMapViewer C# display Slippy Map
Osmdroid LGPL Java display,marker Android Replaces Androids MapClass component
OsmSharp C# display,routing Toolsuite iporting OSM, routing, display slippy map with KML/GPX layers
QMapControl LGPL C++ display,marker,gps,wms QT
QT Mobility API display Slippy Map
QuartzMaps Commercial Objective C rendering, display iOS Slippy Map and Vector Map rendering engine for iOS
route-me BSD Objective C display Slippy map for IPhone
osm-gps-map GPLv2 C/GObject display GTK+ mapping widget (and Python bindings) drawing a GPS track, and points of interest on a moving map
WhirlyGlobe-Maply Apache 2.0 Objective C display iOS Globe and 2D map toolkit for iPhone, iPad, and Android device.

See also:


To add maps to your webpage you need additional libs for the UI.

Name License Code Bindings Functions Dependencies Description
Leaflet BSD JS newly developed lightweight open-source JavaScript library for interactive maps by CloudMade for browsers on desktop PC and especially on mobile devices
OpenLayers BSD mod JS display,marker,heatmap - Webmaps leading toolkit
AFComponents UMap Flash
Cloudmade Web Maps API JS display, markers, vectors require free cloudmade API key, extends Leaflet
FacilMap AGPL JS display, routing, search OpenLayers Extends OpenLayers with Search, Routing and other functionalities
Google Maps Example proprietary JS display,markers require Google API key, costs >25.000 API loads
ka-Map GPL JS display, markers Slippy Map
Kartograph AGPL 3.0 JS and phyton see feature list Kartograph is a simple and lightweight framework for building interactive map applications without any other mapping service. It was created with the needs of designers and data journalists in mind.
Khtmlib JS display,marker Webkit Browsers WebMaps Toolkit with multitouch. Successor of Zoom zoom zoom map
Kothic.js JS rendering Renders streamed vector maps
Mapi JS display, markers, routing OpenLayers, YOURS Simple mapping and routing API
Mapstraction BSD display,caching,vextors JS Map Display Abstraction (e.g. OpenLayers,GMaps...)
OpenScales Flash configurable by XML
OpenStreetBugs layer JS display,markers OpenLayers Client for OSB so POI adding on Slippy Map
Polymaps Lib JS display,diagrams,marker Webmaps with Data overlays
Silverlight OSM Bing Component MS Silverlight Slippy Map
TouchMapLight ApacheV2 display Webkit Browsers Slippy maps
uMapper $ Flash display Slippy Map
µLayers 2BSD or X11/MIT JS display, markers micro webmaps script

See also:

Code Snippets

Small pieces of code to small to make a lib but nevertheless usefull

See also:


Geo related libs

Here we list general third party libs that would help you to work with geodata in general, not only focused on OSM

  • PROJ.4 - Geo Projection Conversion lib with multiple bindings
  • GDAL - Geo Raster image formats lib
  • OGR - Geo Vector data formats lib
  • PostGIS - The leading Geo enabled Database
  • OpenLayers - The leading web map lib
  • Mapbender - Onother more GIS focused web map lib
  • Geotools -Java GIS Toolkit
  • GIS-Python lab - Python GIS Toolkit


See also

You might have a look of our already existing tools: