4.7 (3 reviews total)
By Jonathan Bennett
    Advance your knowledge in tech with a Packt subscription

  • Instant online access to over 7,500+ books and videos
  • Constantly updated with 100+ new titles each month
  • Breadth and depth in over 1,000+ technologies
  1. Making a Free, Editable Map of the World

About this book

Imagine being able to create accurate maps that look how you want them to, and use them on the Web or in print, for free. OpenStreetMap allows exactly that, with no restrictions on how or where you use your maps. OpenStreetMap is perfect for businesses that want to include maps on their website or in publications without paying high fees. With this book in hand you have the power to make, alter, and use this geographical data in a collaborative way from anywhere on the Earth.

OpenStreetMap was started because most maps you think of as free actually have legal or technical restrictions on their use, holding back people from using them in creative, productive, or unexpected ways. This book will allow you to take control of your own maps and use them smoothly. This book introduces the reader to the OpenStreetMap project and shows you how to participate in the project, and make use of the data it provides. No prior knowledge of the project is assumed, and technical details are kept to a minimum.

In this book, you'll learn how easy it is to add your neighborhood to OpenStreetMap using inexpensive GPS equipment, or even no GPS at all. You'll find out how to communicate with other mappers working in the same area, and where to find more information about how to map the world around you.

Once you have your area mapped, you'll learn how to turn this information into maps, whether for use in print or online, large or small, and with the details you want shown. The book describes several rendering methods, each suited to different types of map, and takes you through a tutorial on each one.

Publication date:
September 2010


Chapter 1. Making a Free, Editable Map of the World

Maps have always been a source of power. Armies have used them to give themselves a military advantage, traders have used them to find the shortest route between places of supply and markets, and fictional pirates have used them to find buried treasure. Those possessing a map have an advantage over those that don't.

It's no wonder then that maps and the information used to create them have been fiercely protected by companies and governments that own them. Many government and commercial mapping agencies charge high fees to use their data, impose strict restrictions on what you can do with the information, and may even make you pay to use maps you've drawn yourself. The OpenStreetMap project aims to change this by giving everyone their own map, for free, and to use for whatever they like.

In this book, you will learn:

  • What the OpenStreetMap project is

  • Why it's different from other sources of free maps

  • Why you should contribute to the project

  • How to add and edit geographic data

  • How to turn that data into maps you can use for anything you like

This chapter explains how and why the project was started, how freely redistributable geographic data is different from maps that are merely free of charge to use, and some of the things the project has already achieved.


What is OpenStreetMap?

OpenStreetMap ( is a project to build a free geographic database of the world. Its aim is to eventually have a record of every single geographic feature on the planet. While this started with mapping streets, it has already gone far beyond that to include footpaths, buildings, waterways, pipelines, woodland, beaches, postboxes, and even individual trees. Along with physical geography, the project also includes administrative boundaries, details of land use, bus routes, and other abstract ideas that aren't apparent from the landscape itself.

The database is built by contributors, usually called mappers within OpenStreetMap, who gather information by driving, cycling, or walking along streets and paths, and around areas recording their every move using Global Positioning System (GPS) receivers. This information is then used to create a set of points and lines that can be turned into maps or used for navigation. The next image shows the raw GPS recordings of courier vans working in Central London, where you can see how the many streets in the city are laid out.

Most mappers are volunteers working on the project in their spare time, although both commercial organizations and government bodies have started to contribute to the project.

The process of using groups of people to work on a task in this way, called crowdsourcing, is a recent phenomenon based around using the Internet to distribute tasks and gather the results. It's used by voluntary projects and commercial organizations alike, and has been particularly effective since broadband Internet connections became widely available in the western world.

Other data is gathered from out-of-copyright maps, public domain databases (ones with no copyright protection), or in some cases donations of proprietary databases by the companies that own them. In most cases, this needs further work to update and tidy the data, but it allows mappers to cover areas they can't get to, or for features that are difficult to survey on foot.

The database uses a wiki-like system where any mapper can add or edit any feature in any area, and a full editing history is kept for every object. This means any mistakes or deliberate vandalism can be rolled back, keeping the data accurate. OpenStreetMap doesn't use an existing geographic information system (GIS) to store its data, but instead uses its own software and data model to make the crowdsourcing process as easy as possible, and to allow the maximum level of flexibility in what gets mapped and how.

While the primary aim of the project is to collect geographic data, members of the project have also produced a wide range of software (much of it open source) that creates, edits, manipulates, or uses the data in some way. We'll use a selection of this software in the examples in this book.

OpenStreetMap's data is free to use by anyone, for any purpose. It is released under a license that allows you to copy, change, and redistribute the data. There are many maps available on the web, all of which are free to use, and some can be embedded in your own web pages or used in mash-ups, but they also have restrictions on what you can do with those services and the data they provide.

In contrast to OpenStreetMap, none of these free services allow you to modify or redistribute their data. If the data is wrong, you can submit a bug report and hope that they fix it, but update cycles are typically slow, and can take months, if not years, to make the corrections. If the service is withdrawn, you're left with nothing. If you want to use the data offline or in an alternative format, you can't. Some even go so far as to claim ownership of any information you display on top of their maps. To borrow a phrase from open source software, these services are "free as in beer, not free as in speech".

OpenStreetMap is often compared to Wikipedia, and there are many similarities between the projects. They both create freely licensed content. They both use the Internet to allow contributors from all over the world to participate, and they both rely on collaborative editing to improve the information they contain incrementally. They both rely on a large and diverse community to ensure the project runs smoothly, and to prevent errors, whether accidental or intentional, from lowering the quality of their information.

Unlike Wikipedia, OpenStreetMap is building a database of information rather than a series of articles. The biggest difference between the projects is that to contribute to OpenStreetMap, you will, at some point, have to leave your computer behind and go out and gather some data.

Despite the name, OpenStreetMap isn't just about maps, and certainly not just about one or two maps; routing, geocoding (finding coordinates for a given object), and spatial analysis are other applications for the data. Even the maps on the OpenStreetMap website are just examples, and you can make your own maps in whatever style you choose.


Why use OpenStreetMap?

Unlike most sources of geographic data, there are virtually no restrictions on what you can do with OpenStreetMap data. You can use it for any purpose, including commercial activities, without having to pay license fees. You can edit the information in any way you like and publish the results. You can give the data to someone else without needing permission, and they can, in turn, pass it on. Your only obligation is to "share alike"; that is, to allow anyone you give OpenStreetMap data to redistribute it themselves. The particular license used is currently the Creative Commons Attribution Share-Alike 2.0 license, usually abbreviated as CC-BY-SA, although a process to change the license to the Open Database Licence 1.0 (ODBL) is currently being considered.

OpenStreetMap contains details of much more than just roads. All mappers are free to add any geographic object they find, so people have added phone boxes, bus stops, parks, public toilets, places of worship, and much more. Footpaths and cycleways are better represented in OpenStreetMap than many other databases, and there are already a number of cycling map and routing projects based on OpenStreetMap data.

OpenStreetMap is updated more often than any other geographic database. In fact, it's continually updated, and the latest data is always available to download. While proprietary databases may be updated frequently, those changes often aren't released to customers very quickly, leaving users with an out-of-date database for some time, possibly months. In contrast, the full OpenStreetMap database, known as the Planet file, is released every week, with updates ("diffs") released on a daily, hourly, and minute-by-minute schedule.

You can correct errors in OpenStreetMap data yourself, and share those corrections with everyone. In the UK, the problem of heavy goods vehicles using satellite navigation and being routed along narrow country lanes appears in the news regularly, and one man even found himself driving to the edge of a cliff by following his SatNav. Anyone encountering mistakes in the information like this can change the map themselves directly, and the changes show up in the database immediately.

Most of the other mapping providers only have maps in a limited number of styles, and obtaining custom maps can be an expensive and lengthy process. In contrast, with OpenStreetMap, the only limits to the number of mapping styles you can have is your own technical and cartographic ability. Several map rendering packages and Geographic Information Systems support OpenStreetMap data, and all the software you need to create maps is available free of charge..


Why contribute to OpenStreetMap?

You don't have to map anything yourself to make use of OpenStreetMap data, so why should you do any mapping yourself?

It's fun! Mappers tell stories of finding footpaths less than a mile from their house or workplace that they didn't know existed. Surveying has taken mappers to places they'd otherwise never have visited, and made them appreciate their local area in a different way.

The area you need may not have been mapped in OpenStreetMap yet. While urban areas in Western Europe have extensive coverage, more rural areas in those countries or places elsewhere in the world may still not have been mapped. The project mostly relies on volunteers, and less densely populated areas get mapped at a slower rate. Surveying the area yourself, at whatever level of detail you require, is easy to do. If you have a commercial project that requires mapping, you could pay a professional surveyor to do the work, which may be more cost-effective in the longer term than paying license fees for a proprietary database.

You may be interested in features that no one else has mapped yet. An area may have its roads extensively mapped, but not have any post boxes, car parking, or retail outlets mapped. If you add those features, you may find other mappers start adding them in other areas, and that the features you add to the database are kept up-to-date by the community. You could get back more from the project than you put in this way.

By contributing to the project, you're also contributing to the common good. The license used by OpenStreetMap means that any data in the database forms a commons, in perpetuity, and without restrictions. It puts accurate, customizable mapping within the reach of small, non-commercial groups, such as clubs and societies, charities and other voluntary organizations.



The OpenStreetMap project began in August 2004 when British programmer Steve Coast wanted to experiment with an USB GPS receiver he'd bought and his Linux-powered notebook. He used a piece of software called GPSDrive, which took maps from Microsoft MapPoint, breaking the license conditions. Not wanting to violate copyright on those maps, he looked around for an alternative. Coast found that there were no sources of mapping data available that he could incorporate into open source software without breaking the licensing conditions or paying huge amounts.

Coast realized that he could draw his own map, and so could others, and the project was born. After presenting his ideas at open source events in London, he found that others had similar ideas, but most hadn't got their projects off the ground. Once they were persuaded to join in, OpenStreetMap was up and running.

The idea of amateur cartographers making maps with consumer-grade equipment was greeted with some skepticism at first. Some said that standard GPS receivers were too inaccurate to make maps with, as a 10-meter error would mean roads would be in the wrong place. Others claimed that a complex infrastructure was needed for such a large-scale project. Other objectors said a predefined ontology was needed, or that the database would simply be too big.

The data model was initially very crude, consisting of simple lines drawn over Landsat information from NASA. Over a period of time, the data evolved into a more useful model, but the basic principle of imposing as few restrictions as possible on mappers was followed. The server software was initially written in Java, then rewritten in Ruby, and finally in Ruby on Rails, which is still the current server platform.

In March 2006, the first desktop editing application for OpenStreetMap, JOSM, was released. This was written in Java and allowed offline mapping for the first time. Soon after, the first full-color map was created using a renderer written specifically for OpenStreetMap, called Osmarender, showing Weybridge in Surrey, and added to Wikipedia.

In the month of May of that year, the first mapping event was held on the Isle of Wight (pictured in the previous image). This was the first time many of the mappers had met in person, and marked a turning point for the project. One single area was mapped in detail by many people, showing that the crowdsourcing approach to geography worked. Mapping parties like this event have become regular features of the OpenStreetMap community, and are held all over the world wherever mappers spot an area that needs better coverage.

The OpenStreetMap Foundation was formed in August 2006 to own the infrastructure needed to run the project and accept donations. Prior to this, the servers, domain names, and other infrastructure had been owned by Steve Coast, and establishing the foundation gave the project an existence beyond one person's involvement.

May 2007 saw the server software move to the Ruby on Rails platform, and the release of the online Flash-based editor, Potlatch. Later that month, the first annual OpenStreetMap conference, The State of the Map, was held in Manchester. By August, there were five million ways in the database, and 10,000 registered users on the OpenStreetMap website.

In September 2007, Automotive Navigation Data (AND), a Dutch mapping company, donated its dataset for the Netherlands to the project. This was the first time a commercial organization had provided data to the project, and the first time the whole of any country was covered for some types of data.

During the same month, the process of importing the US government public domain geodata set, known as TIGER (Topologically Integrated Geographic Encoding and Referencing) was started, completing in January 2008. Work began immediately to clean this data up and to make it conform with OpenStreetMap data standards.

By February 2008, there were 25,000 registered users of the OpenStreetMap website, and an appeal was launched to raise £10,000 for new servers. In the end, over £15,000 was raised in less than a week.

State of the Map 2008 was held in Limerick, Ireland in July. By the end of that year, over 300 million points had been plotted in the database. On March 17, 2009, the 100,000th user registered on the site, less than five years after the project started; the number of users had quadrupled in just over a year.

At the time of writing, over half a million points were being added to the OpenStreetMap database each day, and the rate of growth was still increasing.


Does it work?

The process of crowdsourcing geographic data is accurate. A 2008 study by Muki Haklay at University College London examined the OpenStreetMap data for the UK in general, and London in particular, and compared it to similar data from Ordnance Survey. Haklay found that where data existed in OpenStreetMap, 80% of it coincided with Ordnance Survey data for the same features. The average distance from an OpenStreetMap feature to an Ordnance Survey equivalent was six metres, less than the general accuracy of GPS positioning, and this didn't take into account the possibility of the Ordnance Survey data being inaccurate.

There were also large areas where there was no data in OpenStreetMap. The conclusion is that if there is a problem with OpenStreetMap data, it is one of completeness rather than positional accuracy. Everything that's there is in the right place, but not everything is mapped yet.

Another vote of confidence in the quality of OpenStreetMap's data comes from one UK local authority, Surrey Heath Borough Council, whose staff have mapped the area covered by the council, and is using OpenStreetMap maps on its website and internally. You will also find maps based on OpenStreetMap data on, the website of the President of the United States.


Structure of the project

There is very little formal structure to the OpenStreetMap project, and what structure there is reflects the voluntary nature of contributions to the project. There are no super-users who can change the data in ways that "normal" users can't, and there are no fixed ontologies for the data. The data and the project are both intended to give mappers as much flexibility as possible, so they can map features as accurately as they can. While there are system administrators who look after the project's infrastructure, they don't get any more say about what gets put in the database than any other contributor.

The OpenStreetMap Foundation—the non-profit body set up to support the project—doesn't regulate where mappers work, what features they map, or how they describe them. The foundation does have a few working groups that look after various aspects of the project, but they are concerned with long-term development rather than day-to-day operation. The foundation will only intervene when the whole project is being put at risk by the actions of individual mappers.

This relative anarchy is both a strength and weakness of the project. On the positive side, it allows mappers to get on with recording information without needing permission, approval, or moderation. It allows the data to evolve over time to correct mistakes and to take account of changes without the overhead of a top-down design. It allows novel uses of the data without having to check license conditions. However, it also means that problems are addressed according to how interesting they are to individual mappers, rather than how important they may be to the project as a whole, as the volunteers aren't under any obligation to follow a plan.

The project's main website is, which is aimed at collecting and maintaining the data. Various other websites and resources are used to coordinate the project, including mailing lists, a wiki, a code repository, and an issue tracker. Other tools are also provided by individual mappers or companies, and these have their own websites.

The most important thing to remember is that the project has no paid employees. Even mappers whose job involves working with OpenStreetMap are paid by their companies, who have their own interests, and aren't there to solve other people's problems necessarily. While the OpenStreetMap community will be happy to help you solve any problems you have, you will be expected to make an effort yourself.


The OpenStreetMap Foundation

The OpenStreetMap Foundation (OSMF) is a non-profit company based in the UK that supports the project. The foundation exists to own the project's infrastructure, accept donations, organize the annual conference, and provide arbitration in the event of disputes. It was established in 2006 as a Company Limited by Guarantee—a type of company in the UK that is suited to non-profit-making organizations. This type of company doesn't have shareholders; rather its members or guarantors are expected to pay a small amount (currently £5) in the event of the company becoming insolvent. The foundation's Memorandum of Association forbids it from paying dividends or otherwise distributing any profits.

Anyone may join the OSMF, although it's not necessary to use OpenStreetMap or contribute towards it. Neither does the OSMF dictate what can or can't be mapped, or how mappers work. Although it owns the project's infrastructure, the foundation doesn't own the data stored on them unless mappers have explicitly chosen to reassign the copyright on their contributions to the foundation.

The OSMF is governed by a board of directors, elected by the membership, which oversees the general running of the foundation. There are also a number of working groups made up of members of the foundation in addition to board members, which provide recommendations about particular aspects of the project, such as licensing, promotion of the project, the annual conference, and a data working group, responsible for ensuring the accuracy of the data as a whole. The data working group will intervene if unresolvable content disputes occur, or for cases of persistent vandalism, but, in general, most issues are solved by the OpenStreetMap community.

The foundation also administers the GPStogo,scheme, which provides GPS receivers to mappers in developing countries. The scheme is aimed at improving OpenStreetMap's data in countries where the equipment needed is too expensive to buy by lending receivers to mappers who have already made some contribution to the project.



In five years, OpenStreetMap has gone from a small project run by a few enthusiasts in London to being a global resource with thousands of users and the start of an industry based around the data it collects. It's no longer just a hobby for a few, but a serious project attracting the attention of companies and governments.

Many specialist maps have been created, including OpenCycleMap ( showing cycle networks and routes, a Piste map for skiers and snowboarders, a hiking site combining maps with photos for guidance, and a nautical chart.

When the Beijing 2008 Olympic Games started, the photo-sharing website Flickr ( began using OpenStreetMap mapping of the city for its users to plot the location of their photos, and has continued to do so.

OpenStreetMap has also made an impact in humanitarian aid. The project has produced mapping of the Gaza Strip in the middle-east (seen in the previous screenshot) through tracing aerial images and information from aid workers in the region. The dangers faced by people working in the region and the rate at which the landscape changes has made up-to-date mapping difficult to obtain. It's hoped that OpenStreetMap's way of producing maps will change this.



The OpenStreetMap project, its data, and its community can provide maps and mapping data from a simple static image to a custom-rendered dynamic map of the world, to anyone, for any purpose, without restrictions. The data is accurate, detailed in places, and continually improving. The only limit to what you can do with the data is your own ability, and in this book we'll show you how to create, edit, and view the data, and how to turn it into a map showing the information you want, in the style you want.

About the Author

  • Jonathan Bennett

    Jonathan Bennett is a British journalist, writer, and developer. He has been involved in the OpenStreetMap project since 2006, and is a member of the OpenStreetMap Foundation. He has written for print and online technical publications including PC Magazine, ZDNet, CNET, and has appeared on television and radio as a technology commentator. He has an extensive collection of out-of-date printed maps.

    Browse publications by this author

Latest Reviews

(3 reviews total)
Very easy and very fast. Good service.
A good book to learn how to edit the maps and how to retrieve information from OpenStreetMap database.
Unlock this book and the full library for $5 a month*
Start now