Document Automation
ZUGFeRD & Factur-X EU Invoices from Google Sheets
- ZUGFeRD
- Factur-X
- EU invoice
- compliance
- DocForge
Why "just send a PDF" stopped being good enough in Europe
Public-sector buyers across the EU now require structured electronic invoices that comply with the EN 16931 standard. Germany's ZUGFeRD and France's Factur-X profiles embed the XML inside a regular PDF/A-3, giving you one file that humans read and machines parse.
Suppliers that keep sending plain PDF face rejection notices, payment delays, and, increasingly, lost contracts. Doing this from a spreadsheet is possible—if the generator understands the standard.
Anatomy of a hybrid PDF/XML invoice
- PDF/A-3 container: archive-grade PDF with attachments allowed.
- Cross-Industry Invoice (CII) XML: the structured payload aligned with EN 16931.
- Conformance profile:
BASIC,EN16931, orEXTENDED—pick the minimum your buyer accepts. - Schematron validation: the safety net that catches missing buyer reference, wrong tax category, or invalid country code.
The mapping problem—solved once, reused forever
Most teams fail here. They have a perfect-looking PDF that ships without the XML, or the XML uses the wrong currency. A robust generator separates two concerns:
- Visual template (logo, layout, line items) for the human-readable PDF.
- Field mapping from Sheet columns to EN 16931 codes (
BT-1 Invoice number,BT-31 Seller VAT,BT-48 Buyer VAT, etc.).
Once mapped, every batch produces both layers in lockstep.
Profile selection cheat sheet
- BASIC: minimum for many B2B exchanges; lightest payload.
- EN 16931: required for most public-sector buyers and Peppol routing.
- EXTENDED: needed when you carry delivery, payment terms, or allowance details with item-level granularity.
Country specifics that bite
- Germany (XRechnung): mandatory profile for federal contracts; ZUGFeRD 2.x EN 16931 covers most cases.
- France (Chorus Pro): Factur-X EN 16931; specific buyer routing codes required.
- Italy (FatturaPA): separate format; consider it a downstream conversion from your EN 16931 source.
- Spain (FACe / Verifactu): evolving rules; keep the source EN 16931 and convert at the edge.
Validation strategy
- Run Schematron before you sign or send—catch 90% of structural issues.
- Test against a buyer sandbox (Peppol, Chorus Pro, etc.) before going live.
- Keep validation logs per invoice; auditors love them.
- Reject the batch on the first invalid invoice rather than send "best effort" PDFs that lack the XML.
Why this is impossible to maintain in Apps Script
The EN 16931 schema is large, the Schematron rules evolve, and country variants drift quarterly. An Apps Script project that works in May breaks in November when a buyer updates its rules. The pragmatic move is to let a maintained engine handle ZUGFeRD/Factur-X and keep your spreadsheet workflow intact.
Where DocForge fits
DocForge embeds ZUGFeRD and Factur-X XML in every invoice rendered from Google Sheets, validates against Schematron, and stores the validation log in Drive alongside the PDF. Install from Google Workspace Marketplace and run your next EU invoice batch with confidence.
Related articles
Document Automation
Google Sheets to PDF in Bulk: The Complete 2026 Guide
Stop exporting rows one by one. Learn how to turn a Google Sheets tab into hundreds of branded PDFs—invoices, quotes, contracts—with template variables, auto numbering, and Drive delivery.
Document Automation
Invoice Numbering Without Pain: Automation for Google Sheets
Sequential, gap-free, audit-ready invoice numbers from Google Sheets—without the duplicate disasters every finance team has seen.
Document Automation
E-Sign From Google Sheets With a Real Audit Trail
How to add legally-defensible e-signature to documents generated from Google Sheets—hash chain, IP capture, signer identity, and a court-ready audit pack ZIP.