Editorial illustration of Mexico's XML schema and technical format requirements for the mexico cfdi 40 xml requirements guide
    Tax and Compliance

    CFDI 4.0 XML Requirements: Mandatory Fields & Validation Rules Explained

    Updated:
    10 min read

    Tax & Compliance Series

    This guide is part of a comprehensive series. Explore all 202 topics:

    Mexico's CFDI 4.0 XML schema contains over 100 data fields with strict validation rules enforced by SAT through the PAC certification process. The most common rejection cause is RFC-name mismatch — the receiver's legal name must match SAT records character-for-character, including accent marks and legal entity suffixes.

    What Is the CFDI 4.0 XML Structure?

    the CFDI 4.

    The CFDI 4.0 XML follows a hierarchical structure defined by SAT's Anexo 20 technical specification:
    • cfdi:Comprobante (Root): Version, date, payment method, currency, total amounts, export flag
    • cfdi:Emisor (Issuer): RFC, legal name, fiscal regime
    • cfdi:Receptor (Receiver): RFC, legal name, fiscal regime, postal code, Uso CFDI
    • cfdi:Conceptos (Line Items): Product/service code (ClaveProdServ from SAT catalog), unit code, description, quantity, unit price, amounts
    • cfdi:Impuestos (Taxes): IVA rates, ISR withholdings, IEPS where applicable
    • cfdi:Complemento (Supplements): Optional structured extensions like Complemento de Pago, Nómina, Comercio Exterior
    • tfd:TimbreFiscalDigital: SAT's digital stamp added by the PAC after certification

    What Are the Most Critical Validation Rules?

    RFC Validation (New in CFDI 4.0)

    CFDI 4.0 validates both issuer and receiver RFC against SAT's Lista de Contribuyentes:
    • The RFC must be active (not cancelled or suspended)
    • The legal name (Nombre) must match SAT records exactly — including accents (é, ñ), legal suffixes (S.A. de C.V., S.C.), and spacing
    • The receiver's fiscal regime must match their SAT registration
    • The receiver's postal code must match their registered fiscal domicile

    ClaveProdServ (Product/Service Code)

    Every line item must include a ClaveProdServ code from SAT's catalog of ~52,000 product and service codes. Common errors:
    • Using deprecated codes from previous catalog versions
    • Selecting overly generic codes that trigger SAT review flags
    • Mismatching the code with the actual product/service description

    Uso CFDI Validation

    The Uso CFDI field indicates the receiver's intended tax deduction purpose. In CFDI 4.0, this must be compatible with the receiver's fiscal regime:
    Uso CFDI CodeDescriptionValid Regimes
    G01Adquisición de mercancías601, 603, 606, 612, 620, 621, 622, 623, 624, 625, 626
    G03Gastos en generalAll regimes
    I01Construcciones601, 603, 606, 612, 620, 621, 622, 623, 624, 625, 626
    S01Sin efectos fiscalesAll regimes — use when receiver won't deduct

    Common CFDI 4.0 Rejection Errors

    Common CFDI 4. 0 Rejection Errors — CFDI33105: Receiver RFC not found in SAT database — Verify RFC spelling and that receiver is registered.

    ErrorCauseSolution
    CFDI33105Receiver RFC not found in SAT databaseVerify RFC spelling and that receiver is registered
    CFDI33106Receiver name doesn't match SAT recordsRequest exact legal name from receiver's Constancia de Situación Fiscal
    CFDI40101Uso CFDI incompatible with receiver's regimeVerify regime code with receiver before issuing
    CFDI40103Receiver postal code doesn't match fiscal domicileUse the 5-digit postal code from receiver's SAT registration

    How Invoicemonk Handles CFDI 4.0 XML

    Invoicemonk automatically generates CFDI 4.0-compliant XML with real-time RFC validation against SAT records, ClaveProdServ catalog lookup, and Uso CFDI compatibility checks — preventing the most common rejection errors before PAC submission.
    OO
    Olayinka Olayokun

    Digital Marketing, SEO Specialist, Content Creator & Product Professional

    CIM Certified
    MBA in Digital Marketing and Business Transformation

    Olayinka is a digital marketer, content creator, growth and SEO specialist with 10+ years helping businesses in Nigeria, the UK, the US, Australia, and Dubai achieve their goals online.

    More from Tax & Compliance