How to use XML Dataset Generator
- Describe the record fields.
- Set root/record names, attribute mode and namespace.
- Press Generate and download the XML.
XML Dataset Generator features
- Field schema shared with the CSV and SQL generators
- Configurable root and record element names
- Fields as elements, attributes or mixed (ids as attributes)
- Namespace URI with optional prefix on every element
- XML declaration and pretty-printing toggles; always well-formed and escaped
- Up to 5,000 records, seedable, with preview
XML Dataset Generator example
Product catalogue
Input:
id:id
name:product
price:price:5-900 · Root: catalog · Record: item · Mode: Mixed · Namespace: urn:example:cat (prefix c)Output:
<?xml version="1.0" encoding="UTF-8"?>
<c:catalog xmlns:c="urn:example:cat" count="2">
<c:item id="1">
<c:name>Wireless Keyboard</c:name>
<c:price>129.5</c:price>
</c:item>
…
</c:catalog>Frequently asked questions about XML Dataset Generator
Can fields be attributes instead of elements?
Yes — choose attributes, elements, or mixed (id-like fields as attributes, the rest as elements).
How do namespaces work?
Give a namespace URI and optionally a prefix; the root declares xmlns (or xmlns:prefix) and every element is prefixed. Special characters are escaped so the document is always well-formed.
Is the output valid XML?
Yes, it is produced by an XML builder with proper escaping and can be validated with the XML Validator tool.