What Is a Digital Invoice? Formats, IRS Rules, and Retention

A digital invoice is a bill created, sent, and received in a structured electronic format that accounting software can read field by field without a human retyping anything. The word doing the work is “structured.” Every data point — invoice number, tax ID, line item, total — sits in a tagged, machine-readable slot, which is what separates a true digital invoice from a PDF someone emailed you. Businesses that use structured e-invoicing cut down on data-entry errors and line up more cleanly with IRS rules for electronic recordkeeping.

Why a PDF Is Not a Digital Invoice

This is the point most people get wrong, and getting it wrong can create compliance problems. A PDF sent by email is an electronic file, but it is not a digital invoice in the technical or regulatory sense. A PDF is essentially a picture of an invoice. Software cannot reliably pull the invoice number, line items, or tax amounts out of it without optical character recognition or manual review. A structured digital invoice stores each piece of data in a labeled field that any compatible system can read instantly.

The distinction matters because tax authorities and procurement systems increasingly require structured formats. The European standard EN 16931 explicitly distinguishes structured electronic invoices from PDFs when defining compliance for public procurement under EU Directive 2014/55/EU.1European Commission Digital. European Legislation on eInvoicing Sellers who invoice European government agencies or move documents through the Peppol network cannot submit PDFs and call it electronic invoicing. In the United States, the IRS does not mandate a specific invoice format for private transactions, but its electronic recordkeeping rules require that digital records be machine-readable and reproducible on demand — a bar a structured format clears more reliably than a static PDF.

What a Digital Invoice Has to Contain

The technical format can vary, but every digital invoice carries the same core set of information. The widely adopted frameworks — Peppol BIS Billing 3.0, which implements EN 16931, and the North American EDI 810 transaction set — require the same basic categories.

At a minimum, a compliant digital invoice includes:

  • A unique invoice number, typically sequential, that lets both parties and tax authorities track the transaction.
  • The issue date, which fixes the applicable tax period.
  • Seller identification: legal name, address, and tax identification number.
  • Buyer identification: name, address, and tax ID.
  • Line items describing the goods or services, with quantities, unit prices, and any discounts.
  • A tax breakdown showing the rate, taxable amount, and total tax for each category that applies.
  • The total amount due, both including and excluding tax.
  • Payment terms: due date, accepted methods, and any early-payment discounts.

Automated systems validate math and field completeness on receipt, so an invoice with a missing tax ID or a line-item total that doesn’t match quantity times price will bounce back immediately. Getting the fields right before the file is transmitted saves the back-and-forth.

The Formats That Make It “Structured”

The data above has to be encoded in a way software can parse without ambiguity. Two families of standards handle that: EDI and XML.

EDI and the ANSI X12 810

Electronic Data Interchange has been used for business-to-business document exchange since the 1970s. In North America, the dominant standard is ANSI X12, developed by the American National Standards Institute. Over 144,000 U.S. businesses use X12 or X12-derived formats to communicate with trading partners and financial institutions.2Federal Reserve Bank. Catalog of Electronic Invoice Technical Standards in the U.S. The invoice-specific transaction set is the 810, which defines segments for header information, line-item detail, and summary totals.

Several industry-specific EDI standards are subsets of ANSI X12. Retail uses the Voluntary Inter-industry Commerce Standard, grocery uses Uniform Communication Standards, and industrial suppliers use the Industrial/Commercial Standard.2Federal Reserve Bank. Catalog of Electronic Invoice Technical Standards in the U.S. Cross-border business may also involve UN/EDIFACT, the United Nations standard used widely in Europe and by multinational corporations.

XML and Peppol

XML-based invoicing uses human-readable tags to label each data element, which makes it more accessible than traditional EDI for smaller businesses and newer software platforms. The Peppol network, originally built for European public procurement, has expanded into a global interoperability framework. Its BIS Billing 3.0 specification implements EN 16931, so any invoice that complies with Peppol also complies with European requirements.3OpenPeppol AISBL. Peppol BIS Billing 3.0.14 Since July 2023, the Peppol International Invoice methodology has extended interoperability beyond Europe, allowing businesses in different countries to exchange structured invoices through a single network.4OpenPeppol. Global Interoperability for Electronic Invoicing Becomes a Reality

Which format you end up using usually depends on who you invoice. Large retailers and manufacturers with established supply chains tend to require X12 EDI. Government agencies and companies connected to international procurement networks lean toward Peppol or other XML schemas. Most modern accounting platforms can generate and receive both.

What the IRS Requires for Digital Invoices You Keep

Federal tax law does not mandate a specific invoice format for private-sector transactions, but it does impose strict requirements on how electronic business records are stored. Those rules apply to any digital invoice you keep as part of your tax documentation.

The foundation is 26 U.S.C. § 6001, which requires every taxpayer to keep records as the Secretary of the Treasury prescribes.5Office of the Law Revision Counsel. 26 USC 6001 – Notice or Regulations Requiring Records, Statements, and Special Returns The implementing regulation says the books and records must be sufficient to establish gross income, deductions, credits, and any other items on the return.6GovInfo. 26 CFR 1.6001-1 Records

Rules for Electronic Storage Systems

Revenue Procedure 97-22 sets the IRS’s technical standards for systems that store electronic records. Any system you use for digital invoices must meet several requirements:7IRS.gov. Rev. Proc. 97-22

  • Records must be transferred to electronic storage media accurately and completely.
  • Reasonable safeguards must prevent unauthorized creation, alteration, or deletion.
  • The storage system must be evaluated regularly, with periodic checks of stored records documented.
  • An indexing method must create a clear audit trail between the general ledger and source documents.
  • Stored records must be clearly readable on screen and reproducible as hard copies on request.
  • At examination, you must provide the IRS with the hardware, software, and personnel needed to locate, retrieve, and reproduce any stored record.

That last point catches some businesses off guard. Your storage arrangement cannot be subject to any contract or license that limits IRS access to the records, software, or documentation on your premises.7IRS.gov. Rev. Proc. 97-22 If you use a cloud-based invoicing platform, check your service agreement for any restriction on government access during an audit.

Keeping Records in Their Original Machine-Readable Form

Revenue Procedure 98-25 adds a separate layer for computerized records. If your invoicing data originates in an electronic system rather than as a scanned image of paper, you must retain it in its original machine-readable format and make it available to the IRS on request.8IRS.gov. Rev. Proc. 98-25 Printing digital invoices to PDF and deleting the source data does not satisfy this requirement. The original structured files have to be preserved for as long as their contents are relevant to the administration of tax law.

IRS Publication 583 puts it plainly: everything that applies to paper books and records also applies to electronic storage systems, and original paper records can only be destroyed after testing the electronic system to confirm it reproduces them in full compliance with IRS standards.9Internal Revenue Service. Publication 583, Starting a Business and Keeping Records

How Long to Keep Digital Invoices

The IRS does not set a single retention period. How long depends on the situation, and the clock starts when you file the return the records support:10Internal Revenue Service. How Long Should I Keep Records?

  • Three years from the filing date, or two years from the date you paid the tax (whichever is later), covers most situations.
  • Four years for employment tax records, measured from the date the tax becomes due or is paid.
  • Six years if you fail to report income exceeding 25% of the gross income shown on your return.
  • Seven years if you claim a deduction for worthless securities or bad debt.
  • Indefinitely if you do not file a return or file a fraudulent one.

For records tied to property, keep them until the statute of limitations expires for the year you dispose of the asset. Many businesses default to seven years across the board to cover the longest common scenario. Digital storage makes that easier than it was with paper, but the Rev. Proc. 97-22 rules on integrity and accessibility apply for the full retention period.

What Inadequate Records Actually Cost

The consequences of poor recordkeeping run past a messy audit. Under 26 U.S.C. § 6662, the IRS can impose an accuracy-related penalty equal to 20% of the portion of any tax underpayment attributable to negligence.11Office of the Law Revision Counsel. 26 USC 6662 – Imposition of Accuracy-Related Penalty on Underpayments The statute defines negligence broadly, and the IRS Internal Revenue Manual specifically lists failure to keep adequate books and records as an indicator of negligence during an audit.12Internal Revenue Service. IRM 4.10.6 Penalty Considerations

Play it out. If you claim $80,000 in business deductions but cannot produce the invoices to substantiate them, the IRS can disallow the deductions entirely. You then owe the additional tax on the disallowed amount, plus the 20% penalty on top of that underpayment. For gross valuation misstatements, the penalty doubles to 40%.11Office of the Law Revision Counsel. 26 USC 6662 – Imposition of Accuracy-Related Penalty on Underpayments A compliant, retrievable digital invoice system is the difference between defending your deductions and losing them.