Shape nested samples under one root tag, pick a data profile or stay generic, then copy or download without leaving the tab.
Choose a profile or stay on Custom, then tune the fields.
Spreadsheets train your eyes on rows. XML asks for nested names, repeated siblings, and occasional attributes on the same node.
Hand-writing twenty opening and closing tags wastes time when you only need believable structure. You still get UTF-8 text you paste into a test harness, a readme snippet, or a CI fixture folder.
Each profile maps to a pair of root and item names (for example books and book). The script rolls random but coherent field values: titles, prices, departments, order totals, depending on which option you chose.
Custom mode ignores those specialized fields and emits three predictable children (name, value, category) so you always get a valid repeating pattern even without a domain story.
With pretty-print enabled, the output runs through the browser DOMParser and walks the tree to rebuild indentation. If parsing fails, you still see the raw string so nothing silently disappears.
Regenerate runs the same pipeline again, so ids and prices change. Treat every click as a fresh draw, not a stable database snapshot. Randomness helps fuzz layouts. Swap to fixed fixtures when you need deterministic regression baselines.
The byte size reflects UTF-8 encoding of the editor buffer. Line counts include blank lines the formatter inserts. The closing-tag tally is a rough proxy for depth and siblings, not a business record count.
Use those numbers to spot accidental bloat after you crank records toward one hundred, or to compare two generations side by side after you toggle attributes off and on.
Specifications, public APIs, and legal bundles often ship with XML where every attribute is deliberate. In those cases, start in your editor, keep the file under version control, and treat generated samples as disposable sandboxes.
For quick diffing or canonical formatting once you have real content, pair this workflow with XML Pretty Print or inspect structure with the XML Parser before you promote a file.
Generated children also avoid namespaces, xsi types, and CDATA blocks on purpose. The moment your partner sends a sample with prefixed elements, clone their header and default namespace declarations, then paste your body underneath. This tool never pretends to guess those policies for you.
| Preset | Typical consumer | Highlights |
|---|---|---|
| Books | Library demos | ISBN-style attribute, genre, page counts |
| Orders | Commerce dashboards | Status enums, totals, shipping strings |
| Employees | HR analytics mocks | Department, salary integers, hire dates |
If you already have messy input and need to prove validity, switch over to the XML Validator instead of relying on freshly invented rows.
Educators sometimes project a large font editor during workshops. The dark preview pane keeps angle brackets readable against glare, while the profile list gives students one tap to compare domains without editing long templates by hand.
Keep root names short and singular where possible. Match the repeating child name to the business noun your team already uses in JSON or SQL so conversations stay aligned.
Turn attributes off when you want the simplest possible tree for teaching. Turn them on when you want ids visible without extra child nodes.
After download, rename the file to match your pipeline convention (orders-seed.xml, catalog-fixture.xml) before you commit. The default name is generic on purpose so you never overwrite a production artifact by accident.
When you paste into Slack or email, wrap the snippet in a fenced code block in those tools so angle brackets survive transport. Plain-text paste without formatting sometimes strips markup in rich clients.
Practical answers before you paste output into a pipeline.
Yes for well-formedness: tags close, attributes quote values, and there is a single root. Output does not guarantee your external schema, DTD, or partner rules.
Large documents can freeze weaker devices while the editor paints thousands of lines. For bigger loads, generate a smaller file here, then duplicate or script locally.
Type new names anytime. The preset fills inner fields only. Outer tag names always follow the two text inputs.
The declaration reads UTF-8 and the Blob is saved with a UTF-8 charset. Open the file in an editor that respects that label.
If the parser hits an error node, the tool returns the unformatted string so you still see output. Fix tag balance or stray characters and regenerate.