ULID Generator

Blog

ULID Generator

BlogCheatsheets
Loading...
Loading ULID generator...

Description

Generate Universally Unique Lexicographically Sortable Identifiers (ULID). Monotonic, time-sortable, and URL-safe alternative to UUIDs.

About ULID Generator

A ULID is a 128-bit identifier that is lexicographically sortable and time-ordered: its first 48 bits encode a millisecond Unix timestamp, and the remaining 80 bits are random. It is encoded as 26 characters using Crockford's base32, which is URL-safe and avoids ambiguous characters. ULIDs are a useful alternative to UUIDs when you want IDs that naturally sort by creation time, and this generator builds them locally in your browser.

How to use

  1. Open the tool to generate a ULID based on the current timestamp.
  2. Optionally choose how many ULIDs to generate at once.
  3. Click Generate; new ULIDs are created from the current time plus random bits.
  4. Copy the resulting 26-character identifiers for use in your application.

Examples

ExampleInputOutput
ULID shapeGenerate one ULIDA 26-character Crockford base32 string, e.g. 01ARZ3NDEKTSV4RRFFQ69G5FAV

Frequently asked questions

How is a ULID different from a UUID?

Both are 128-bit identifiers, but a ULID embeds a millisecond timestamp in its first 48 bits and is encoded in Crockford base32 (26 characters), making it lexicographically sortable by creation time. UUIDs (especially v4) are not time-sortable in their canonical text form.

Why is a ULID sortable?

The timestamp occupies the most significant bits, so sorting ULIDs as plain strings orders them by the time they were generated. This is convenient for database keys and logs.

Is a ULID URL-safe?

Yes. Crockford base32 uses only digits and a subset of uppercase letters, excluding characters like I, L, O, and U to avoid confusion, so a ULID can be placed in URLs and filenames without escaping.

What does 'monotonic' mean for ULIDs?

When multiple ULIDs are generated within the same millisecond, a monotonic generator increments the random component so the IDs still sort in the order they were created instead of being purely random within that millisecond.