Mock Data Generator

Generate sample JSON user records with names, emails and roles for tests and prototypes.

Mock Data Generator and Fake Name Generator: JSON, CSV or SQL

Choose the fields you need, how many records (1 to 100) and the output format, and the generator produces fictional people, with fake names, emails, phones and addresses, that you can paste into a test, a fixture file or a database. Pick female, male or mixed first names, click Regenerate for a fresh set, and Copy to take the result. Every value is built in your browser from built-in word lists and your browser's cryptographic random number generator. Emails, phone numbers and IP addresses come from ranges reserved for documentation, so a test record can never send mail to, call or connect to anyone real.

Fields and formats

Twenty fields are available: ID, UUID, first name, last name, full name, gender, email, username, phone, birth date, company, job title, street, city, postcode, country, IPv4, IPv6, an active flag and a created-at time. Columns always appear in that order, whatever order you tick them in. JSON output is an array of objects:

[
  {
    "id": 1,
    "fullName": "Hiro Levi",
    "email": "hiro.levi67@example.org",
    "phone": "+1-512-555-0157",
    "birthDate": "1995-03-15",
    "city": "Dublin",
    "country": "Ireland",
    "active": true
  }
]

IDs count from 1, UUIDs are random version 4, birth dates fall between 1950 and 2005, and created-at is an ISO 8601 UTC time within the last three years. About three records in four are active. Usernames are built from the name with accents removed, so Fernández becomes fernandez, and the email uses the same username. City and country always match each other, but the street and the five-digit postcode are random and do not correspond to the city.

CSV and SQL INSERT output

CSV output has a header row and quotes any value that contains a comma, quote or line break. SQL output is a single multi-row INSERT into a table named users, with strings in single quotes, embedded quotes doubled, and the active flag written as TRUE or FALSE:

INSERT INTO users (id, firstName, email, city, active) VALUES
  (1, 'Julia', 'julia.smith4@example.org', 'London', TRUE),
  (2, 'Ingrid', 'ingrid.schmidt21@example.com', 'Rome', TRUE),
  (3, 'Grace', 'grace.carter92@example.com', 'Buenos Aires', FALSE);

Rename the table and columns to match your schema before running it. Column names use the camelCase field names, and PostgreSQL folds unquoted identifiers to lowercase, so firstName addresses a column called firstname. TRUE and FALSE work in PostgreSQL, MySQL, MariaDB and SQLite 3.23 or later; SQL Server has no boolean literals, so replace them with 1 and 0 for a bit column.

Why emails, phones and IPs use reserved ranges

Test data leaks. It ends up in staging databases that send real emails, in screenshots, in public bug reports and in demo videos. If a generator produces plausible real-looking addresses, some of them belong to someone, and a test run that sends a password reset can reach a stranger's inbox. This generator uses only values that standards set aside for examples:

email   @example.com, @example.org, @example.net   RFC 2606
phone   +1-XXX-555-0100 to 555-0199                NANP, reserved for fictional use
IPv4    192.0.2.0/24, 198.51.100.0/24, 203.0.113.0/24   RFC 5737 (TEST-NET-1/2/3)
IPv6    2001:db8::/32                               RFC 3849

The example domains exist, but each publishes a null MX record (RFC 7505), which tells mail servers not to deliver to them. The North American Numbering Plan Administrator keeps 555-0100 through 555-0199 as fictitious numbers for film, television and advertising in every area code, which is why the area codes here are real, such as 202 or 415, while the numbers are not. Addresses in the documentation IP ranges are not routed on the public internet, so a firewall rule, log entry or test request using them never touches a real server.

If you need random IP addresses for a different purpose, such as load-testing your own routing, use a private range such as 10.0.0.0/8 instead; a truly random public address belongs to someone.

Fake names and fake identities: what the data is for

The records are fictional: first names, surnames, companies, jobs and streets are picked at random from built-in lists, and the company list is made of well-known fictional firms such as Acme Corp and Initech. Names are chosen from several languages and regions, which is useful for checking that your interface handles Müller, São Paulo and Fernández correctly. A random combination can coincide with a real person's name, but none of the records describes anyone.

That makes the output suitable for fixtures, seed data, UI mock-ups, demos and load tests. It is not a way to create an identity: the data will not pass identity or payment verification, and using fake details to deceive a service or a person is fraud in many jurisdictions. Nor is it meant to replace production data in analytics; random values have none of the distributions and correlations of real users.

Faker libraries for generating data in code

For test suites, generate data in code, where it is repeatable and can be as large as you need. The standard libraries are Faker for Python, FakerPHP for PHP, which Laravel uses in its model factories, and @faker-js/faker for JavaScript and TypeScript:

# Python: pip install Faker
from faker import Faker
Faker.seed(42)                  # same data on every run
fake = Faker()
fake.name(); fake.email(); fake.ipv4()

// PHP: composer require --dev fakerphp/faker
$faker = Faker\Factory::create();
$faker->name(); $faker->safeEmail();

// JavaScript: npm install --save-dev @faker-js/faker
import { faker } from '@faker-js/faker';
faker.seed(42);
faker.person.fullName(); faker.internet.email();

Seeding matters: a failing test that uses random data should fail the same way on the next run. Check each library's defaults against the reserved ranges above, too. Python Faker's ipv4(), for instance, returns addresses from the whole public space, such as 210.200.51.240, so use it only where nothing will actually connect to the address.

This generator suits the cases where writing code is overkill: a JSON fixture for a front-end component, a few rows for a demo table, or sample CSV to test an import.

No seed: save the sets you depend on

Values come from crypto.getRandomValues() without a seed, so a set cannot be recreated: Regenerate, a page reload or ticking another field gives you new people every time. If a test or a demo relies on particular records, commit the JSON or CSV as a fixture file instead of planning to generate the same data again. Nothing is sent to a server, so the copy you paste is the only one.

Frequently asked questions

How do I generate fake names?

Tick first name, last name or full name, choose female, male or mixed names, set the number of records and click Regenerate. Copy puts the result on the clipboard as JSON, CSV or SQL.

Can the fake emails reach real people?

No. Every email uses example.com, example.org or example.net, domains reserved by RFC 2606 for documentation, so messages sent to them are not delivered to anyone.

Are the phone numbers real?

No. All numbers are in the 555-0100 to 555-0199 range, which the North American Numbering Plan reserves for fictional use. The area codes are real, but the numbers do not connect to subscribers.

How do I generate a random IP address for testing?

Tick IPv4 or IPv6. IPv4 addresses come from the RFC 5737 documentation ranges such as 192.0.2.0/24, and IPv6 addresses from 2001:db8::/32, so they never belong to a real server.

Can I use this as a fake identity generator?

Only for testing. The records are random combinations from built-in lists and will not pass any verification. Using invented details to deceive a service or a person can be fraud.

How many records can I generate at once?

Between 1 and 100 per set. For larger data sets or repeatable test data, use a seeded Faker library in your test code.