About the ULID Generator
A ULID (Universally Unique Lexicographically Sortable Identifier) is a 128-bit ID written as 26 characters. The first 10 characters encode a 48-bit Unix timestamp in milliseconds and the last 16 encode 80 random bits, here taken from crypto.getRandomValues. Because the time comes first and the alphabet is in ASCII order, sorting ULIDs as plain strings sorts them by creation time, which keeps database indexes compact in the same way as UUID v7.
The text form is Crockford Base32: the digits and the upper-case letters without I, L, O and U, so an ID cannot be misread and is safe in URLs and file names. 26 characters could hold 130 bits, so the first character of a valid ULID is at most 7; the largest timestamp, 7ZZZZZZZZZ, falls in the year 10889. With the monotonic option, ULIDs made within the same millisecond take the previous random part plus one instead of new random bits, so even a batch generated in one go is strictly increasing.
A ULID and a UUID are both 128 bits, so every ULID has a UUID form and the reverse: the decoder shows both, which lets you store ULIDs in a native uuid column and show them as 26 characters. It also reads the timestamp as ISO 8601, local and relative time, and the random part in hex. Remember that the creation time is visible to anyone who sees the ID.
How to use it
- Set the count and choose monotonic order and lower case as needed.
- Tick “Custom time” to generate ULIDs for a given date and time instead of now.
- Click Generate, then Copy all or Download.
- Paste a ULID or a UUID into the inspector to decode it and convert it.