Look at almost any modern system's internal data — a database record, an API response, a session token — and you'll likely find a UUID somewhere: a long string like f47ac10b-58cc-4372-a567-0e02b2c3d479. It looks arbitrary, and in a sense it is — that's actually the entire point.
The problem UUIDs solve
The obvious alternative to a random ID is a simple incrementing counter — record 1, record 2, record 3. That works fine in a single, centralized system. It breaks down the moment multiple systems need to generate IDs independently without coordinating with each other — two separate services both trying to create "record 1" would collide. A UUID sidesteps this entirely: it's generated using enough randomness that two independently generated UUIDs are, for all practical purposes, guaranteed never to collide, with no central coordination required at all.
Why "practically guaranteed" is good enough
A version 4 UUID (the common random type) has so many possible combinations that the odds of two independently generated ones colliding are astronomically small — small enough that in practice, it's treated as effectively impossible for real-world systems, even at massive scale.
Where UUIDs actually get used
- Database primary keys, especially in distributed systems where multiple servers might be inserting records simultaneously.
- API keys and access tokens, where unpredictability is a security feature, not just a technical convenience.
- Session identifiers, tracking a specific user session without any two sessions ever accidentally sharing an ID.
- File and object identifiers in storage systems, where uniqueness across the entire system matters more than sequential ordering.
Generating one
- Choose how many you need — useful for seeding test data or generating several IDs in one batch instead of one at a time.
- Pick your formatting preference (standard, uppercase, or without the dashes).
- Copy the result.
Generation happens using your browser's built-in cryptographically secure random number generator, so no server round-trip is needed just to get a random ID.
Need a unique identifier right now? Try the UUID Generator — everything is generated locally in your browser.