How to use ULID / KSUID
- 1. Pick a kind. ULID and KSUID sort by time. Snowflake needs a worker id. ObjectId matches Mongo.
- 2. Set count. Up to 200 values.
- 3. Generate. Web Crypto fills the random bits.
- 4. Download. Newline-separated file.
About this tool
UUIDv4 is random and painful to index. ULID, KSUID, Snowflake, and ObjectId encode time so new rows roughly append. Generate them here when you are seeding fixtures.
Collision
These are not coordinated with your production generators. Do not mix worker ids casually in Snowflake.
Canonical ULID
Encoding uses Crockford base32. Inspect, don't treat this as a bit-for-bit library clone without tests in your stack.
Code examples
Use
const id = generateUlid();