Given the same namespace UUID and the same name, UUIDv5 (SHA-1) and UUIDv3 (MD5) always produce the same output UUID. Use them when you need to generate a stable identifier from something that isn’t already an ID — a URL, a DNS name, an internal path, an email — and you want two systems to agree on that ID without coordinating. Prefer v5 for new work; v3 exists mainly for compatibility with older systems.
One name per line. Blank lines are skipped. Namespace and version are taken from the single-mode inputs above.
namespace_bytes + name_bytes with SHA-1 (v5) or MD5 (v3).byte[6] & 0x0f | 0x50 (v5) or | 0x30 (v3).byte[8] & 0x3f | 0x80 — the RFC 9562 variant (10xx).Once a namespace is chosen for a system, don’t change it. Every downstream ID depends on the input pair; a different namespace UUID produces a completely different output for the same name.
These are checked against RFC 4122 Appendix B and independent implementations. Type www.example.org or python.org in the single form above with the DNS namespace to reproduce.
| Version | Namespace | Name | Expected UUID |
|---|---|---|---|
| v5 | DNS | www.example.org | 74738ff5-5367-5958-9aee-98fffdcd1876 |
| v5 | DNS | python.org | 886313e1-3b8a-5372-9b90-0c9aee199e5d |
| v3 | DNS | www.example.org | 0012416f-9eec-3ed4-a8b0-3bceecde1cd9 |
| v3 | DNS | python.org | 6fa459ea-ee8a-3ca4-894e-db77e160355e |