# Sample & Dummy File Generator — Any Size, Any Format

> Create valid test files of an exact size in 22 formats — text, data, code, images, audio, PDF and ZIP.

A sample file generator creates valid, openable test files at a size you choose. Pick a format — text, CSV, JSON, XML, SQL, code, PNG, GIF, WAV, PDF or ZIP — set the target size and how many files you need, and each one is built in your browser to that exact byte count.

**URL:** https://convertto.tech/t/sample-file-generator
**Category:** Samples & Mock Data (https://convertto.tech/c/sample-data)
**Privacy:** Runs entirely in the browser; no upload
**Cost:** Free, no sign-up
**Last updated:** 2026-08-01

## Key facts

- **Formats:** 22 — TXT, MD, LOG, CSV, TSV, JSON, NDJSON, XML, YAML, SQL, HTML, JS, TS, PY, ENV, PNG, BMP, GIF, WAV, PDF, ZIP and raw BIN
- **Size range:** 1 byte to 64 MB per file, up to 256 MB per batch
- **Batch size:** Up to 200 files per run, optionally varied around the target
- **Validity:** Real encoders — every image, audio file, PDF and archive opens normally
- **Privacy:** Runs entirely in your browser — nothing is uploaded
- **Cost:** Free, unlimited, no sign-up

## How to use

1. Choose the file format.
2. Set the how many files.
3. Choose the size driven by.
4. Set the pages per document.
5. Set the target size.
6. Choose the size unit.
7. Set the size variance.
8. Choose the content.
9. Choose the archive contents.
10. Enter or paste your file name pattern.
11. Enter or paste your seed.
12. Turn "Download batch as one ZIP" on or off as needed.
13. Press Run, then download the result when it is ready.

## FAQ

### Are the generated files actually valid?

Yes. PNG, BMP and GIF are encoded pixel by pixel, WAV contains real audio samples, PDFs are built with a proper PDF writer and ZIPs are real archives. They all open in ordinary software.

### Why is my ZIP not exactly the size I asked for?

Archive size depends on how well the contents compress. The generator stores entries uncompressed to keep it predictable, but the central directory adds a small fixed overhead per entry.

### What are the three content options for?

Random bytes are incompressible and represent the worst case for a compression or storage test. Zeros compress almost perfectly and represent the best case. Realistic content sits between the two, matching what real uploads do.

### Is anything uploaded?

No. The files are assembled in your browser and handed straight to the download — they never touch a server, which is also why there is no size cap beyond your device memory.

## Related tools

- [Sample File Library](https://convertto.tech/t/sample-file-library): Download a ready-made ladder of 15 sample files: size steps, page counts, aspect ratios, durations or row counts.
- [Mock Data Generator](https://convertto.tech/t/mock-data-generator): Generate realistic fake test data in 14 formats from 100+ field types, with reproducible seeds.
- [Sample Dataset Generator](https://convertto.tech/t/sample-dataset-generator): Download ready-made sample datasets — users, orders, products, transactions — as CSV, JSON, SQL or Excel-ready TSV.
- [CSV Column Extractor](https://convertto.tech/t/csv-column-extractor): Pull selected columns out of a CSV by name or position, and reorder them.
- [Wrap Lines in Quotes or Brackets](https://convertto.tech/t/line-wrapper): Add a prefix and suffix to every line and join them — build SQL IN lists, arrays and CSV rows.
- [PDF to CSV Converter](https://convertto.tech/t/pdf-to-csv): Extract PDF tables into properly quoted CSV, one row per table row.
- [PDF to JSON Converter](https://convertto.tech/t/pdf-to-json): Export a PDF as JSON — both the recovered document structure and the raw line geometry.
- [PDF to PNG Converter](https://convertto.tech/t/pdf-to-png): Convert PDF pages into crisp lossless PNG images.
- [Sample PDF Generator](https://convertto.tech/t/sample-pdf-generator): Build test PDFs with any page count, paper size, orientation, content type and file size.
- [Sample Audio File Generator](https://convertto.tech/t/sample-audio-generator): Generate WAV test audio: sine, square, sweep, noise or silence at any rate, depth and duration.
