Bulk UUID Generator – Generate Hundreds of UUIDs for Test Fixtures
Generate one or hundreds of UUIDs in v4 or v7 format instantly
No signup • Runs in browser • Free
Test fixtures need stable, known UUIDs. Database seed files need unique IDs for every row. API mock servers need realistic-looking resource identifiers. Clicking a UUID generator button fifty times is not a workflow — bulk generation is. A UUID generator that produces a batch of UUIDs in a single operation, formatted as a JSON array, newline-separated list, or SQL VALUES clause, eliminates the manual step entirely.
Bulk UUID generation is simpler than it sounds because UUID v4 is stateless — each UUID is generated independently with no coordination, no sequence, and no connection to any other UUID in the batch. You can generate ten thousand v4 UUIDs in the same browser tab without any risk of collision between them or with any UUID ever generated anywhere else. The math is straightforward: with 2^122 possible v4 values, generating ten million UUIDs per second for the entire age of the universe would still leave collision probability effectively at zero.
// Output as JSON array — paste directly into a fixture file:
[
"f47ac10b-58cc-4372-a567-0e02b2c3d479",
"3d721b2e-9c04-4f8a-b835-12a47c9e6d01",
"a1e3908c-2b55-47dc-8f91-c67d4e823b44",
"7c9e6679-7425-40de-944b-e07fc1f90ae7",
"6ba7b810-9dad-11d1-80b4-00c04fd430c8"
]
// Output as SQL VALUES — paste into a seed migration:
INSERT INTO users (id, name) VALUES
('f47ac10b-58cc-4372-a567-0e02b2c3d479', 'Alice'),
('3d721b2e-9c04-4f8a-b835-12a47c9e6d01', 'Bob'),
('a1e3908c-2b55-47dc-8f91-c67d4e823b44', 'Carol');
Quick summary
- ✓UUID v4 generation is stateless — each UUID is independent, no coordination required, no collision risk in practice.
- ✓Bulk generation is useful for test fixtures, database seeds, mock API responses, and load test data.
- ✓Use v4 for opaque fixture IDs; use v7 if you need seed data that sorts in a meaningful order.
- ✓DevToolBox tools run entirely in your browser — no signup.
Why Generate UUIDs in Bulk?
Single UUID generation covers one-off needs — an idempotency key for an API call, a new record ID before insertion. Bulk generation covers the class of problems where you need many unique IDs at once, before any database is involved.
- Test fixtures and factory data. Automated test suites that depend on specific UUIDs need those UUIDs to be stable — the same every test run. Generating a batch, hardcoding them into fixture files, and referencing them by variable name throughout the test suite gives you reproducible tests with realistic-looking IDs.
- Database seed migrations. The initial data load for a development or staging environment needs unique IDs for every row. Generating a batch and embedding them in the migration file makes the seed deterministic and reviewable in version control.
- Mock API servers. Tools like Mock Service Worker and Prism serve realistic-looking API responses during frontend development. Pre-generating a set of resource UUIDs and embedding them in response fixtures makes the mock data internally consistent — the same user ID appears in the user detail response and in the list response.
- Load test data. Performance tests that insert thousands of rows need unique IDs for each row. Generating them in bulk before the test run is faster than generating them during the run, and avoids timing-dependent behavior in the test results.
v4 vs v7 for Bulk Generation
The choice between v4 and v7 for bulk generation depends on how the IDs will be used in the data.
Use UUID v4 when:
- The IDs are opaque tokens — session IDs, event IDs, fixture identifiers where no meaningful order is implied.
- The IDs will be used in tests that assert on specific values, and the values should look like typical production UUIDs (which are overwhelmingly v4 today).
- You are generating IDs for a table that already uses v4 primary keys and you need the fixture IDs to be the same format.
Use UUID v7 when:
- The seed data should sort in a meaningful order — for example, a set of seed users that were "created" at different times and should sort by creation time.
- The fixtures will be used in tests that rely on cursor-based pagination, which depends on IDs sorting correctly.
- You are seeding a table that uses v7 primary keys in production and want realistic test data.
See our guide on UUID v4 vs UUID v7 for the full comparison, including database index performance implications.
Output Formats for Different Use Cases
The same batch of UUIDs needs to appear in different formats depending on where it goes. Common formats and their uses:
# Newline-separated — pipe into scripts, paste into text files:
f47ac10b-58cc-4372-a567-0e02b2c3d479
3d721b2e-9c04-4f8a-b835-12a47c9e6d01
a1e3908c-2b55-47dc-8f91-c67d4e823b44
# JSON array — paste into fixture files, JavaScript constants:
["f47ac10b-...", "3d721b2e-...", "a1e3908c-..."]
# Comma-separated — SQL IN clauses, CSV imports:
f47ac10b-..., 3d721b2e-..., a1e3908c-...
# Without hyphens — for databases storing BINARY(16):
f47ac10b58cc4372a5670e02b2c3d479
How to Generate Bulk UUIDs
Using the DevToolBox UUID Generator to produce a batch takes under ten seconds.
- Open the generator in your browser. No account, no install.
- Select the UUID version — v4 for random IDs, v7 if you need chronological ordering.
- Set the quantity — how many UUIDs to generate.
- Select the output format — JSON array, newline-separated, or comma-separated.
- Click generate and copy the output into your fixture file, seed migration, or test setup.
DevToolBox generates UUIDs using the browser's crypto.randomUUID() API — no server involvement, no logging.
Frequently Asked Questions
Can two UUIDs in a bulk batch collide?
In practice, no. UUID v4 uses 122 bits of cryptographically random data. The probability of any two v4 UUIDs colliding is approximately 1 in 5.3 × 10^36. Generating one trillion UUIDs per second for a trillion years would still give you less than a 0.000001% chance of a single collision. The DevToolBox generator uses the browser's built-in crypto.randomUUID(), which is backed by the OS's cryptographically secure random number generator.
How do I use bulk UUIDs in a database seed file?
Generate the batch, choose your preferred format, and embed the UUIDs directly in the seed SQL or ORM factory. In SQL: INSERT INTO table (id, ...) VALUES ('uuid-1', ...), ('uuid-2', ...);. In a JavaScript ORM factory, export an array constant with the pre-generated UUIDs and reference them by index. Hardcoding IDs in seed files makes tests reproducible and diffs readable in version control.
Is it better to generate UUIDs in the database or in the application?
Either works. PostgreSQL's gen_random_uuid() and MySQL's UUID() generate v4 UUIDs in the database on insert. Application-generated UUIDs (using crypto.randomUUID() or a UUID library) let you know the ID before the insert, which is useful for offline-first patterns, idempotency, and returning the ID to the client before confirming persistence. For bulk test data, application generation is more convenient since you can embed the IDs in fixture files.
Conclusion
Bulk UUID generation is a utility task that comes up repeatedly in development workflows — fixtures, seeds, mocks, load tests. The generation itself is trivial; what matters is getting the output in the right format for the target use case and choosing the right version (v4 for opacity, v7 for ordering). Pre-generating and hardcoding UUIDs in fixture files produces reproducible, reviewable test data that does not depend on runtime generation.
If you need to generate a batch of UUIDs instantly in any format, the DevToolBox UUID Generator does exactly that. DevToolBox tools run entirely in your browser — no signup, no install, nothing sent to a server.
Generate bulk UUIDs in seconds
Set a quantity, choose v4 or v7, and copy the output as JSON, newline-separated, or comma-separated. Free, no signup, browser-only.
Generate Bulk UUIDs Now →