Member; Membership; Roles; Child and Parent not explained properly. Any need to split Tags into two parts ?

Objects - The basic building blocks of OpenStreetMap data and maps

Please don't hurry reading this, you can consult this page again at any second.

Nodes, ways, and relations

Tags (also an OSM data primitive)

Tags provide meaning to the objects. Without them, any other object would be useless and meaningless. Each of three other data primitives can have multiple tags.

Often tags used in combinations; usually these combinations can be found in presets. But it may be true that tags you need to use are not in presets and you need to know them first.

Simplest example is drinking_water=yes - it is present globally and can be applied to every object that provides water. Other example is leaf_cycle=* of trees, it will have less coverage globally (as trees do not grow just everywhere).

From time to time you will encounter tags that found somewhere else but not in your locality; it is good idea to check wiki what is tag about, use: Essential links tagging as starting point.

We will cover tags in more detail below, but first will cover all other data primitives.

Nodes (also an OSM data primitive)

source:trunk/resources/images/data/node.svg A node is an individual point with a defined position. With respective tags it can be used to indicate shops, benches, individual trees or points of drinking water.

Only nodes have Coordinates in the OSM data model. Ways and relations simply refer to nodes.

Common nodes

Nodes can be re-used between multiple ways. Multiple ways can refer to a single node (common node).

A practical meaning of this is demonstrated at the Draw Nodes page. The Merge Nodes tool can be used to create common nodes.

Ways (also an OSM data primitive)

source:trunk/resources/images/data/way.svg A way is a sequence of nodes (a "polygonal chain" from ordinary geometry). OSM way used to represent linear objects, with respective tags it can used to describe: a river bank, tree row, kerbs in the streets (among other uses).


Since nodes are ordered in OSM; every way in OSM has a direction. This gives us possibility to add tags (details about object) such as conveying=* - to specify direction of escalators and moving walkways or incline=* which can be used toghter with roads and footways. There more examples and we can't cover them all.

Note: Rendering of direction in MapView can be set in Preferences under OSM Data.


Is a fragment between two consequent points of the way ("line segment" from ordinary geometry). This is not a part of OSM data model, but users often distinguish because of tools than operate on segment level (rather than on complete way); please, distinguish a segment(s) from complete "way"s.

Note: Rendering of segments in MapView can be set in Preferences under OSM Data.


source:trunk/resources/images/data/closedway.svg If a way is closed, i.e. if the last node is the same as the first node, it is also called an area. Old term for this is Closed Ways (it is still present at wiki, used in software and by some mappers; other part uses "geometry" when talking just about shape of the objects, without tags).

Sometimes single area is not enough to represent an object (for example, a lake with an island in it), then you have to use a multi-polygon

Relations (also an OSM data primitive)

In most cases you don't need them

If some object can be represented with single node or way and multiple tags supported by software, then there is no need in relations. But there are some rare cases where it is theoretically and practically impossible only with nodes, ways and tags (ex. turn restrictions, will be covered below).

This means you can skip this big "Relations" section, until you decide to add or edit a relation.

Simple explanation

source:trunk/resources/images/data/relation.svg A relation:

  • is a sequence of other objects (nodes, ways and relations)
  • as other objects (node, way) - every relation can have their own "tags"
  • can be used as members in other relations (nested or hierarchical structures)
  • tag type=* used to define one of many types of relations

Additionally, each object participating in a relation can be assigned a role, for instance "via" node and "from", "to" ways in type=restriction relation.

Relation Help covers the most basic tools to create relations in JOSM (Relations window, Selection, Relation editor).

Most popular types


A water object (natural=water), a building (building=*) or administrative boundary (admin_level=* tag) usually consist of the multiple spatially separated parts belonging to the one object. More importantly, each of these parts can have exclusions (enclaves/exclave or simply islands or swamps in the water basins).

  • Parts are created using "outer" role. Each multi-polygon should have at least one outer part.
  • Holes inside parts - using "inner" role. Each part can have from 0 to N holes.
  • Ways that form a ring where all ways are connected between each other using common nodes (JOSM will warn you about mistakes during validation)
  • Rarely, holes can be nested. If nesting is more complex than single outer and single inner ring, role swapping can continue: outer-inner-outer-inner-...
  • Outer and inner rings shouldn't have common nodes (but validator will warn you about this and other mistakes)

Multi-polygon specific tools:


Route-Relation describe common routes for all kind of transport modes and transportation services like roads, bicycle, hiking, public_transport or even electric power lines


Can be used to describe turn restrictions according to signs and road marking. JOSM has a plugin to support this type of relations: Turnrestrictions plugin,Examples


More precisely, a tag is a name/value pair assigned to an object. If we write foo=bar we mean The tag with key foo is assigned the value bar. Here are some examples:

  • name=Main road assigned to a way. This tag indicates that the name of the way is Main road.
  • natural=tree assigned to a node. This tag indicates that the node represents a tree in the real-world.
  • route=bus assigned to a relation. This tag indicates that the relation represents a bus route.

Tags can be combined. An object can carry as many tags as necessary. Here's a more complex example:

name=Main road
name:en=Main road

Assigned to a way, this set of tags indicate, that the way represents a road in a residential area with name Main road (the German name be Hauptstraße, the English name, which in this example equals to name, is Main road). Speed is limited to 30km/h and heavy goods vehicles (hgv) are not allowed. Furthermore, it's a one way street.

In the source:trunk/resources/images/dialogs/propertiesdialog.svg Tags/Membership panel you can assign tags to an object, remove tags from an object, or edit assigned tags.

Technical properties

Object id

The OSM server assigns each object a unique number, the object ID or OSM ID.

In JOSM, a new object doesn't have an ID (its ID is 0) until it is uploaded the first time to the OSM server.

  • Under source:trunk/resources/images/preference.svg Preferences (or F12) -> source:trunk/resources/images/preferences/display.svg Display it is possible to en- or disable the display of objects ids in the windows.
  • With File -> source:trunk/resources/images/downloadprimitive.svg Download object ... it is possible to download objects by Ids.

Note: The display of object ids in the Selection List can be set in Preferences under Display.

Object versions and history

Version numbers (versions) were introduced to simplify wiki-style editing. Unfortunately, to track changes to ways/relations you need to use more complex tools than simple comparison by version number.

  • Contents of the relation can change without change in version or id of the relation (a way can be changed, a node can be changed, a child relation can be changed).
  • Contents of the way can change without change in version or id of the way (a child node can be moved back and forth several times, but id of the way may stay the same).

But you can always track complete history of one node based on history. Also, you can use time sliced data (region extracts by date) to inspect how objects were changing (and refer to object id and point in time from the database).

Note: The display of object versions in the Selection List can be set in Preferences under Display.

Information about latest version

  • View -> source:trunk/resources/images/info.svg Advanced info (or Keyboard shortcut:Ctrl+I) opens separated windows with informations about selected objects in text format.
  • View -> source:trunk/resources/images/info.svg Advanced info (web) (or Keyboard shortcut:Ctrl+Shift+I) opens the objects pages of selected objects on the OSM website in your web browser.

Alternatively, you can browse the objects directly by entering following address in your web browser:[node/way/relation]/[ID]

History of the object

Each object has a version. The version is incremented whenever the object is uploaded to the server and the OSM server not only stores the most recent version of an object, but its complete history.

  • View -> source:trunk/resources/images/dialogs/history.svg History (or Keyboard shortcut:Ctrl+H) opens the History Browser. The History Browser will show you the versions of a particular object.
  • Alternatively, View -> source:trunk/resources/images/dialogs/history.svg History (web) (or Keyboard shortcut:Ctrl+Shift+H) opens a page on the OSM website in your web browser which displays the object history, too.

Back to Main Help

Last modified 3 years ago Last modified on 2021-03-23T22:40:05+01:00
Note: See TracWiki for help on using the wiki.