---
id: "plus_code"
kind: "datatype"
status: "draft"
is_pii: false
categories: ["geo"]
langs: ["common"]
quality: 75
url: "http://registry.apicrafter.io/datatype/plus_code"
---

# Plus Code (Open Location Code) (`plus_code`)

> **Draft.** Draft records have not been reviewed yet and may be incomplete or wrong; do not treat them as authoritative for legal or compliance decisions.

Full Plus Code of the Open Location Code system published by Google, which encodes a WGS84 latitude and longitude as a grid cell. It uses 20 symbols (23456789CFGHJMPQRVWX): eight digits, the separator +, and usually two or more digits after it; a ten-digit code is a cell of about 14 by 14 metres. Shorter codes pad the eight positions before the separator with pairs of 0 and end with +. The first digit encodes latitude and the second longitude, which limits them to 2-9 and C, and to 2-9 and C-V. Codes are case-insensitive. Shortened codes that need a reference place are the pattern plus_code_short.

- Personal data (PII): no
- Categories: Geographic identifiers (geo)
- Countries: global
- Languages: Common to most languages (common)
- Classification: identifier
- Patterns: `plus_code_short`

## Detection

Regular expression (Python `re`):

```
^[2-9Cc][2-9CFGHJMPQRVcfghjmpqrv](?:000000\+|[2-9CFGHJMPQRVWXcfghjmpqrvwx]{2}(?:0000\+|[2-9CFGHJMPQRVWXcfghjmpqrvwx]{2}(?:00\+|[2-9CFGHJMPQRVWXcfghjmpqrvwx]{2}\+(?:[2-9CFGHJMPQRVWXcfghjmpqrvwx]{2,})?)))$
```

## Examples

- `8FVC9G8F+6W` — Example from the specification, centre 47.365562,8.524813 (Zurich)
- `796RWF8Q+WF` — Example from the specification (Praia)
- `8FWCX400+` — Padded code from the reference validity tests
- `849VGJQF+VX7QR3J` — Fifteen-digit code from the reference validity tests
- `8FWC2345+G` (invalid example) — One digit after the separator
- `84900000+` (invalid example) — Padding must come in pairs
- `9G8F+6W` (invalid example) — Short code: the pattern plus_code_short

## Sources

- doc: <https://github.com/google/open-location-code/blob/main/Documentation/Specification/specification.md>
- other: <https://github.com/google/open-location-code/blob/main/test_data/validityTests.csv>
- wikipedia: <https://en.wikipedia.org/wiki/Open_Location_Code>

## Quality

Score 75/100. Missing: mapping (Wikidata, Schema.org, ...), translation, detector coverage.

JSON: <http://registry.apicrafter.io/api/v1/datatypes/plus_code.json> · Edit: <https://github.com/apicrafter/metacrafter-registry/edit/main/data/datatypes/any/geo/plus_code.yaml>
