How the schema is inferred
- Order and counts. Children keep the order the samples agree on, in an
xs:sequence. A child missing from some samples getsminOccurs="0", one that repeatsmaxOccurs="unbounded". When samples disagree on the order, the content becomes a repeatedxs:choice. - Types. Values that are all integers become
xs:integer, thenxs:decimal,xs:boolean,xs:date,xs:dateTimeandxs:time; anything else isxs:string. Codes with leading zeros (0042) stay strings. Turn off Infer types to type everything as a string. - Attributes. One present on every occurrence is
use="required". - Namespaces. Each namespace gets its own schema file, imported by the main one, with the prefixes the document uses.
More samples give a better schema: add several documents and everything they have in common, and everything they don't, is taken into account.
Russian doll, Venetian blind, Salami slice
- Russian doll
- One global element, everything else declared inside it. The schema reads like the document. Elements with the same name in different places get their own declarations.
- Venetian blind
- Local elements with named complex types (
PartyType), defined at the top level, so other schemas can reuse them. - Salami slice
- Every element global, referenced with
ref. Elements with the same name share one declaration wherever they appear.
After generating
An inferred schema describes your samples, not your intent: tighten it by hand where you know more, with enumerations, patterns and lengths. Then validate new documents against it in the validator or from code. If the format is a published standard (UBL, CII, ISO 20022), use its official schema from the catalog instead.
Questions
Is my XML uploaded?
No. The schema is inferred and the samples are validated in your browser.
Can it use several sample documents?
Yes, and it should: add files next to the pasted document, and the schema accepts all of them.
Which XSD version does it write?
XML Schema 1.0, which every validator reads.
What about DTD or RelaxNG?
It writes XSD only. The validator accepts all three if you already have a DTD or a RelaxNG schema.
Other tools
- XML formatter: Pretty-print or minify XML, keeping text, CDATA and comments as written.
- XML viewer: Read a document as a tree you can fold, search and copy XPaths from.
- XPath tester: Evaluate XPath 3.1 against a document and see each match with its line.
- XML from XSD: Generate a sample XML document from a schema, validated against it.
- XSLT transformer: Run XSLT 1.0, 2.0 or 3.0 on a document and see the result, the messages and the files it writes.
- XML diff: Compare two XML documents as trees: changed, added and removed elements, attributes and text.
- XML to JSON converter: Convert XML to JSON, with arrays where an element repeats or wherever its XSD allows.
- JSON to XML converter: Convert JSON to XML: @keys become attributes, arrays repeated elements.
- XML to CSV converter: Turn a repeating element into CSV rows: invoice lines, products, records.
- XML to PDF converter: Save any XML as a PDF to read, print or attach: indented, coloured, with line numbers.
- E-invoice viewer: Read an XRechnung, ZUGFeRD, Factur-X or Peppol invoice as a document, and save it as a PDF.
- E-invoice converter: Write an XRechnung, Peppol BIS, ZUGFeRD or Factur-X invoice in another of these formats, checked before you save it.
- ZUGFeRD validator: Check a ZUGFeRD or Factur-X PDF: the XML inside against its profile's rules, and the PDF around it.
- XRechnung validator: Check an XRechnung in UBL or CII against EN 16931 and KoSIT's XRechnung rules before you send it.
- UBL validator: Check a UBL invoice, order or any other UBL 2.1 document against its OASIS schema, and the business rules of the profile it names.
- Peppol validator: Check a Peppol BIS Billing 3.0 or PINT invoice against the OpenPeppol rules before your access point sends it.
- P7M viewer: open a .p7m file: Open a signed .p7m file: the PDF, invoice or document inside it, and who signed it.
- XRechnung examples to download: Example XRechnung and ZUGFeRD invoices to download, one for each common case.
- E-invoicing mandate in Germany: do I have to?: Find out whether your invoices in Germany must be e-invoices in 2026, 2027 and from 2028.
- Factur-X examples: Example Factur-X invoices of every profile and of the French reform, as XML and as PDF.
- Leitweg-ID check: Check the form and the check digits of a Leitweg-ID, the address of a German public buyer.
- Peppol lookup: Check whether a company is registered in Peppol, under which ID, and which invoices it can receive.
- PDF to XRechnung: Turn a PDF, scan or photo of an invoice into an XRechnung or ZUGFeRD e-invoice: AI fills the form, the rules check it.
- PDF to ZUGFeRD: Turn your own PDF invoice into ZUGFeRD: the XML goes inside your PDF, its pages as they are, checked against EN 16931 first.
- Self-billed invoices and credit notes: Write a self-billed invoice (a German Gutschrift, type 389) or a credit note as XRechnung or ZUGFeRD, checked before you download it.
- Receive e-invoices for free: An email address of your own for e-invoices: forward an XRechnung or ZUGFeRD invoice and get it back as a PDF to read, checked against its rules.
- XML validator: check a document against XSD, DTD, RelaxNG or Schematron, up to 1 GB.