---
id: "uuid_urn"
kind: "pattern"
status: "draft"
is_pii: false
categories: ["identifiers"]
langs: ["common"]
quality: 80
url: "http://registry.apicrafter.io/datatype/uuid_urn"
---

# UUID as a URN (urn:uuid) (`uuid_urn`)

> **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.

A UUID written as a URN in the uuid namespace, urn:uuid:<UUID>, as RFC 9562 defines. It is used where an identifier must be a URI, for example as the id of Atom feeds and entries (RFC 4287), in RDF data and as the identifier of EPUB packages. The urn and uuid parts are case-insensitive.

- Pattern of: `uuid`
- Personal data (PII): no
- Categories: Universal unique identifiers (identifiers)
- Countries: global
- Languages: Common to most languages (common)
- Classification: identifier

## Detection

Regular expression (Python `re`):

```
^[Uu][Rr][Nn]:[Uu][Uu][Ii][Dd]:[0-9A-Fa-f]{8}-[0-9A-Fa-f]{4}-[0-9A-Fa-f]{4}-[0-9A-Fa-f]{4}-[0-9A-Fa-f]{12}$
```

## Examples

- `urn:uuid:f81d4fae-7dec-11d0-a765-00a0c91e6bf6` — Example URN of RFC 9562 (Figure 4)
- `urn:uuid:6e8bc430-9c3a-11d9-9669-0800200c9a66` — Example of the uuid namespace in the Wikipedia article on URNs
- `urn:uuid:1225c695-cfb8-4ebb-aaaa-80da344efa6a` — Entry id in the example feed of RFC 4287 (Atom)
- `f81d4fae-7dec-11d0-a765-00a0c91e6bf6` (invalid example) — Bare UUID without the URN prefix, see uuid
- `urn:uuid:{f81d4fae-7dec-11d0-a765-00a0c91e6bf6}` (invalid example) — Braces are not part of the URN form

## Translations

- ru: UUID в виде URN (urn:uuid)

## Sources

- doc: <https://www.rfc-editor.org/rfc/rfc9562>
- doc: <https://www.iana.org/assignments/urn-namespaces/urn-namespaces.xhtml>

## Quality

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

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