> ## Documentation Index
> Fetch the complete documentation index at: https://docs.abbyy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ZUGFeRD-compliant electronic invoices

> Create ZUGFeRD-compliant electronic invoices with ABBYY FineReader Engine — a PDF/A-3 hybrid format that carries both visual PDF and machine-readable XML invoice data.

ZUGFeRD is a German standard dedicated to simplifying the processing of electronic invoices and to improving accounting efficiency. This standard deals with hybrid data about e-invoices combined into a single PDF that fully conforms to the PDF/A-3 standard (ISO 19005-3). Each ZUGFeRD-compliant PDF carries e-invoices in two formats:

* PDF format to visualize the e-invoice contents;
* XML format to extract and parse the relevant data from e-invoice by a machine.

ZUGFeRD-compliant PDF may also include spreadsheets, images, and other data related to a target e-invoice.

To create ZUGFeRD-compliant PDF with ABBYY FineReader Engine:

1. Create a [FRDocument](/fine-reader/engine/api-reference/document-related-objects/frdocument) object with the [CreateFRDocument](/fine-reader/engine/api-reference/engine-object-iengine-interface/creation-methods/createlessobjectgreater-methods) method.
2. Add one or several pages of the target invoice to the created FRDocument using the [AddImageFile](/fine-reader/engine/api-reference/document-related-objects/frdocument/addimagefile-method) method of the FRDocument object.
3. Call the [Process](/fine-reader/engine/api-reference/document-related-objects/frdocument/process-method) method of the FRDocument object.

<Note>
  To learn more on how to process the documents with ABBYY FineReader Engine, see [Tuning Parameters of Preprocessing, Analysis, Recognition, and Synthesis](/fine-reader/engine/guided-tour/advanced-techniques/tuning-parameters-of-preprocessing-analysis-recognition-and-synthesis).
</Note>

4. Add the XML version of the invoice as an attachment to the created FRDocument using the [PDFAttachment](/fine-reader/engine/api-reference/document-related-objects/pdfattachment) object.
5. Create a [PDFExportParams](/fine-reader/engine/api-reference/parameter-objects/export-parameters/pdfexportparams) object with the [CreatePDFExportParams](/fine-reader/engine/api-reference/engine-object-iengine-interface/creation-methods/createlessobjectgreater-methods) method of the Engine object.
6. Set the ZUGFeRD-specific parameters:
   * ZUGFeRD compliance enabled: [PDFExportFeatures::EnableZugferdCompliance](/fine-reader/engine/api-reference/parameter-objects/export-parameters/pdfexportfeatures) must be set to TRUE;
   * PDF/A-3 compliant document: [PDFExportParams::PDFAComplianceMode](/fine-reader/engine/api-reference/parameter-objects/export-parameters/pdfexportparams#pdfacompliancemode) must be set to [PCM\_Pdfa\_3a](/fine-reader/engine/api-reference/enumerations/pdfacompliancemodeenum#pcm_pdfa_3a), [PCM\_Pdfa\_3b](/fine-reader/engine/api-reference/enumerations/pdfacompliancemodeenum#pcm_pdfa_3b), or [PCM\_Pdfa\_3u](/fine-reader/engine/api-reference/enumerations/pdfacompliancemodeenum#pcm_pdfa_3u);
   * Writing PDF attachments enabled: [PDFExportFeatures::WriteSourceAttachments](/fine-reader/engine/api-reference/parameter-objects/export-parameters/pdfexportfeatures#writesourceattachments) must be set to TRUE.

<Note>
  See more useful information about fine-tuning the document export in [Tuning Export Parameters](/fine-reader/engine/guided-tour/advanced-techniques/tuning-export-parameters).
</Note>

7. Save the ZUGFeRD-compliant PDF with the [Export](/fine-reader/engine/api-reference/document-related-objects/frdocument/export-method) method of the FRDocument object.

To check the validity of the output, you may use the [ZUGFeRD validation portal](http://din-zugferd-validation.org).

## See also

[Tuning Parameters of Page Preprocessing, Analysis, Recognition, and Synthesis](/fine-reader/engine/guided-tour/advanced-techniques/tuning-parameters-of-preprocessing-analysis-recognition-and-synthesis)

[Tuning Export Parameters](/fine-reader/engine/guided-tour/advanced-techniques/tuning-export-parameters)
