Weiter zum Inhalt
Konto erstellen
oder
anmelden
Das Logo der Stripe-Dokumentation
/
KI fragen
Konto erstellen
Anmelden
Jetzt starten
Zahlungen
Umsatz
Plattformen und Marktplätze
Geldmanagement
Entwicklerressourcen
Übersicht
Informationen zu Stripe Payments
Aktualisieren Sie Ihre Integration
Zahlungsanalysefunktionen
Online-Zahlungen
ÜbersichtIhren Use case findenUse Managed Payments
Payment Links verwenden
Vorgefertigte Bezahlseite verwenden
Build a custom integration with Elements
    Übersicht
    Compare Checkout Sessions and PaymentIntents
    Quickstart guides
    Erweiterte Integration entwerfen
    Erscheinungsbild anpassen
    Zahlungsmethoden verwalten
    Zusätzliche Informationen erfassen
    Abonnement-Integration erstellen
    Dynamic updates
    Rabatte hinzufügen
    Steuern auf Ihre Zahlungen einziehen
      Steuer-IDs erfassen
    Lassen Sie Kundinnen/Kunden in ihrer Landeswährung zahlen
    Zahlungsmethoden von Kundinnen und Kunden speichern und abrufen
    Belege und bezahlte Rechnungen senden
    Zahlungen auf Ihrem Server manuell genehmigen
    Eine Zahlung separat autorisieren und einziehen
    Elements mit Checkout Sessions API-Änderungsprotokoll (Beta)
In-App-Integration erstellen
Zahlungsmethoden
Zahlungsmethoden hinzufügen
Zahlungsmethoden verwalten
Schnellerer Bezahlvorgang mit Link
Zahlungsschnittstellen
Payment Links
Checkout
Web Elements
In-App Zahlungen
Zahlungsszenarien
Umgang mit mehreren Währungen
Nutzerdefinierte Zahlungsabläufe
Flexibles Acquiring
Orchestrierung
Präsenzzahlungen
Terminal
Mehr als Zahlungen
Unternehmensgründung
Krypto
Financial Connections
Climate
Betrug verstehen
Betrugsprävention von Radar
Zahlungsanfechtungen verwalten
Identitäten verifizieren
StartseiteZahlungenBuild a custom integration with ElementsCollect taxes on your payments

Notiz

Bis jetzt ist diese Seite noch nicht in dieser Sprache verfügbar. Wir arbeiten aber verstärkt daran, unsere Dokumentation in weiteren Sprachen bereitzustellen, und werden die Übersetzung sofort anzeigen, sobald diese verfügbar ist.

Collect customer tax IDs

Learn how to collect VAT and other customer tax IDs with Elements.

Payment Intents API

With the Payment Intents API, you must build your own UI components and functionality to collect and store tax IDs.

Displaying a customer’s tax ID and legal business name on invoices is a common requirement that you can satisfy by enabling tax ID collection. This guide assumes that you’ve integrated Elements with the Checkout Sessions API. If you haven’t completed this integration, see the quickstart guide.

Disclaimer

The Checkout Sessions API is designed to collect business tax IDs, which might have formats similar to personal tax IDs in certain jurisdictions. You must make sure that only business tax IDs, as designated for this field, are provided when using this feature.

Enable tax ID collection
Server-side

New customers

To enable tax ID collection for new customers, set tax_id_collection[enabled] to true when creating a Checkout Session.

Command Line
cURL
Stripe CLI
Ruby
Python
PHP
Java
Node.js
Go
.NET
No results
curl https://api.stripe.com/v1/checkout/sessions \ -u "
sk_test_BQokikJOvBiI2HlWgH4olfQ2
:"
\ -d ui_mode=custom \ -d "line_items[0][price]"=
{{PRICE_ID}}
\ -d "line_items[0][quantity]"=1 \ -d "tax_id_collection[enabled]"=true \ -d mode=payment \ --data-urlencode return_url="https://example.com/return"

Existing customers

Create a Checkout Session with an existing customer to add any tax ID information collected during checkout. The session saves the business name as the customer’s name, and adds the collected tax ID to customer.tax_ids.

When creating the Checkout Session, you must set customer_update.name to auto to prevent overriding the customer’s existing [name].

Command Line
cURL
Stripe CLI
Ruby
Python
PHP
Java
Node.js
Go
.NET
No results
curl https://api.stripe.com/v1/checkout/sessions \ -u "
sk_test_BQokikJOvBiI2HlWgH4olfQ2
:"
\ -d ui_mode=custom \ -d customer=
{{CUSTOMER_ID}}
\ -d "line_items[0][price]"=
{{PRICE_ID}}
\ -d "line_items[0][quantity]"=1 \ -d "tax_id_collection[enabled]"=true \ -d "customer_update[name]"=auto \ -d mode=payment \ --data-urlencode return_url="https://example.com/return"

If you don’t have saved addresses for existing customers, you can use the billing or shipping address entered during checkout to assess their location. To use the billing address, set customer_update.address to auto. Setting this parameter to auto replaces the customer’s previously saved addresses with the address entered during checkout.

Command Line
cURL
Stripe CLI
Ruby
Python
PHP
Java
Node.js
Go
.NET
No results
curl https://api.stripe.com/v1/checkout/sessions \ -u "
sk_test_BQokikJOvBiI2HlWgH4olfQ2
:"
\ -d ui_mode=custom \ -d customer=
{{CUSTOMER_ID}}
\ -d "line_items[0][price]"=
{{PRICE_ID}}
\ -d "line_items[0][quantity]"=1 \ -d "tax_id_collection[enabled]"=true \ -d "customer_update[name]"=auto \ -d "customer_update[address]"=auto \ -d mode=payment \ --data-urlencode return_url="https://example.com/return"

If you’re saving shipping addresses for existing customers, you can use the shipping address entered during checkout to assess their location. To use the shipping address, set customer_update.shipping to auto. Setting this parameter to auto replaces the customer’s previously saved shipping addresses with the address entered during checkout.

Command Line
cURL
Stripe CLI
Ruby
Python
PHP
Java
Node.js
Go
.NET
No results
curl https://api.stripe.com/v1/checkout/sessions \ -u "
sk_test_BQokikJOvBiI2HlWgH4olfQ2
:"
\ -d ui_mode=custom \ -d customer=
{{CUSTOMER_ID}}
\ -d "line_items[0][price]"=
{{PRICE_ID}}
\ -d "line_items[0][quantity]"=1 \ -d "tax_id_collection[enabled]"=true \ -d "customer_update[name]"=auto \ -d "customer_update[shipping]"=auto \ -d "shipping_address_collection[allowed_countries][0]"=DE \ -d mode=payment \ --data-urlencode return_url="https://example.com/return"

This example creates a session in payment mode with tax ID collection enabled. For subscriptions, make the same changes with the mode set to subscription.

Render the Tax ID Element
Client-side
Public preview

Use Stripe’s Tax ID Element to collect tax IDs.

App.jsx
import {useMemo} from 'react', import {loadStripe} from '@stripe/stripe-js'; import {CheckoutProvider, TaxIdElement} from '@stripe/react-stripe-js/checkout'; const stripePromise = loadStripe(
'pk_test_TYooMQauvdEDq54NiTphI7jx'
, { betas: [ 'custom_checkout_tax_id_1', ], }); const App = () => { const fetchClientSecret = useMemo(() => { return fetch('/create-checkout-session', {method: 'POST'}) .then((res) => res.json()) .then((data) => data.clientSecret) }, []); return ( <CheckoutProvider stripe={stripePromise} options={{ fetchClientSecret: () => fetchClientSecret, }} > <TaxIdElement /> <CheckoutProvider> ); };

OptionalCustom client-side implementation
Client-side

Rather than rendering the Tax ID Element, you can also implement your own custom form for full control over the UI and validation.

Create a form in your web application and use updateTaxIdInfo to collect the customer’s business name and tax ID.

App.jsx
import {useState} from 'react'; import {useCheckout} from '@stripe/react-stripe-js/checkout'; // Create a constant to list out the taxID types you'd like to support in your checkout const TAX_ID_TYPES = ['au_abn', 'eu_vat', ...] as const; const TaxIdCollectionForm = () => { const [isPurchaseAsBusiness, setIsPurchaseAsBusiness] = useState(false); const [isEditing, setIsEditing] = useState(true); const [businessName, setBusinessName] = useState(''); const [taxIdType, setTaxIdType] = useState(''); const [taxIdValue, setTaxIdValue] = useState(''); const [errorMessage, setErrorMessage] = useState(''); const checkoutState = useCheckout(); if (checkoutState.type === 'loading') { return ( <div>Loading...</div> ); } else if (checkoutState.type === 'error') { return ( <div>Error: {checkoutState.error.message}</div> ); } const {updateTaxIdInfo} = checkoutState.checkout; const validateAndUpdate = async () => { if (!businessName) { setErrorMessage('Business name is required'); return; }

Retrieve the customer tax ID details after a session

Checkout includes provided tax IDs on the resulting Session object. After each completed Session, Checkout emits a checkout.session.completed event that you can listen for in a webhook endpoint. If you want to retrieve the collected tax ID from the Session object, it’s available under the Session’s customer_details.tax_ids array:

{ "object": { "id": "cs_test_a1dJwt0TCJTBsDkbK7RcoyJ91vJxe2Y", "object": "checkout.session", ... "customer": "cus_id_of_new_customer", "customer_details": { ... "tax_ids": [ { "type": "eu_vat", "value": "FRAB123456789" } ] }, ... "tax_id_collection": { "enabled": true }, ... } }

Checkout also saves collected tax IDs and business names to the Customer object if one is associated with the Session. A tax ID collected during checkout is accessible under the Customer’s customer.tax_ids array. You can also retrieve all tax IDs saved to a Customer with the Tax IDs resource by specifying the owner.type parameter to customer and owner.customer to the Customer’s ID. Every new tax ID includes an associated legal business name, which Checkout saves to the Customer’s name property. In doing so, the collected legal business name is always visible on any subscription invoices for that Customer.

Test your integration

In testing environments, you can enter any alphanumeric string that is in the correct format of a supported tax ID type (for example, DE123456789 for eu_vat). For a full list of example tax IDs you can reference our Customer Tax ID guide. You can also use our test tax IDs to test various verification state flows.

Validation

During the Checkout Session, Stripe verifies that the provided tax IDs are formatted correctly, but not that they’re valid. You’re responsible for ensuring the validity of customer information collected during checkout. To help, Stripe automatically performs asynchronous validation against government databases for European Value Added Tax (EU VAT) and United Kingdom Value Added Tax (GB VAT) numbers. Learn more about the validation we perform, and how to consume the status of those checks.

If you use Stripe Tax and your customer provides a tax ID, Stripe Tax applies the reverse charge or zero rate according to applicable laws, as long as the tax ID conforms to the necessary number format, regardless of its validity.

Supported tax ID types

The Checkout Session collects the following tax ID types in the given regions:

LandEnumBeschreibungBeispiel
Auswirkungen auf die Steuerberechnung
Ägypteneg_tinÄgyptische Steueridentifikationsnummer123456789Ja
Albanienal_tinAlbanien SteueridentifikationsnummerJ12345678NJa
Angolaao_tinSteueridentifikationsnummer Angola5123456789Nein
Armenienam_tinSteueridentifikationsnummer Armenien02538904Ja
Arubaaw_tinSteueridentifikationsnummer Aruba12345678Ja
Aserbaidschanaz_tinSteueridentifikationsnummer Aserbaidschan0123456789Ja
Äthiopienet_tinSteueridentifikationsnummer Äthiopien1234567890Ja
Australienau_abnAustralian Business Number (AU ABN)12345678912Ja
Bahamasbs_tinSteueridentifikationsnummer Bahamas123.456.789Nein
Bahrainbh_vatBahrain, Umsatzsteuer-Identifikationsnummer123456789012345Ja
Bangladeschbd_binUnternehmens-Identifikationsnummer Bangladesch123456789-0123Ja
Barbadosbb_tinSteueridentifikationsnummer Barbados1123456789012Nein
Belarusby_tinWeißrussland TIN-Nummer123456789Ja
Belgieneu_vatEuropean VAT numberBE0123456789Ja
Beninbj_ifuSteueridentifikationsnummer Benin (Identifiant Fiscal Unique)1234567890123Ja
Bosnien und Herzegowinaba_tinSteueridentifikationsnummer Bosnien und Herzegowina123456789012Ja
Bulgarieneu_vatEuropean VAT numberBG0123456789Ja
Burkina Fasobf_ifuSteueridentifikationsnummer Burkina Faso (Numéro d'Identifiant Fiscal Unique)12345678AJa
Cabo Verdecv_nifSteueridentifikationsnummer Kap Verde (Número de Identificação Fiscal)213456789Nein
Chilecl_tinChilenische TIN12.345.678-KJa
Costa Ricacr_tinCosta-ricanische Steueridentifikationsnummer1-234-567890Nein
Dänemarkeu_vatEuropean VAT numberDK12345678Ja
Deutschlandeu_vatEuropean VAT numberDE123456789Ja
Ecuadorec_rucEcuadorianische RUC-Nummer1234567890001Nein
Estlandeu_vatEuropean VAT numberEE123456789Ja
Finnlandeu_vatEuropean VAT numberFI12345678Ja
Frankreicheu_vatEuropean VAT numberFRAB123456789Ja
Georgienge_vatGeorgische Umsatzsteuer123456789Ja
Griechenlandeu_vatEuropean VAT numberEL123456789Ja
Guineagn_nifSteueridentifikationsnummer Guinea (Número de Identificação Fiscal)123456789Ja
Indienin_gstIndische GST-Nummer12ABCDE3456FGZHJa
Irlandeu_vatEuropean VAT numberIE1234567ABJa
Islandis_vatIsländische Umsatzsteuer123456Ja
Italieneu_vatEuropean VAT numberIT12345678912Ja
Kambodschakh_tinSteueridentifikationsnummer Kambodscha1001-123456789Ja
Kameruncm_niuSteueridentifikationsnummer Kamerun (Numéro d'Identifiant fiscal Unique)M123456789000LNein
Kanadaca_bnKanadische BN123456789Nein
Kanadaca_gst_hstKanadische GST/HST-Nummer123456789RT0002Ja
Kanadaca_pst_bcKanadische PST-Nummer (British Columbia)PST-1234-5678Nein
Kanadaca_pst_mbKanadische PST-Nummer (Manitoba)123456-7Nein
Kanadaca_pst_skKanadische PST-Nummer (Saskatchewan)1234567Nein
Kanadaca_qstKanadische QST-Nummer (Québec)1234567890TQ1234Ja
Kasachstankz_binKasachstan, Unternehmens-Identifikationsnummer123456789012Ja
Keniake_pinPersönliche Identifikationsnummer der Kenya Revenue AuthorityP000111111ANein
Kirgisistankg_tinSteueridentifikationsnummer Kirgisistan12345678901234Nein
Kongo-Kinshasacd_nifSteueridentifikationsnummer Republik Kongo (Número de Identificação Fiscal)A0123456MNein
Kroatieneu_vatEuropean VAT numberHR12345678912Ja
Laosla_tinSteueridentifikationsnummer Laos123456789-000Nein
Lettlandeu_vatEuropean VAT numberLV12345678912Ja
Liechtensteinli_vatUmsatzsteuer-Identifikationsnummer in Liechtenstein12345Ja
Litaueneu_vatEuropean VAT numberLT123456789123Ja
Luxemburgeu_vatEuropean VAT numberLU12345678Ja
Maltaeu_vatEuropean VAT numberMT12345678Ja
Marokkoma_vatMarokko, Umsatzsteuer-Identifikationsnummer12345678Ja
Mauretanienmr_nifSteueridentifikationsnummer Mauretanien (Número de Identificação Fiscal)12345678Nein
Mexikomx_rfcMexikanische RFC-NummerABC010203AB9Nein
Montenegrome_pibMontenegro PIB-Nummer12345678Nein
Nepalnp_panPAN-Nummer Nepal123456789Ja
Neuseelandnz_gstNeuseeländische GST-Nummer123456789Ja
Niederlandeeu_vatEuropean VAT numberNL123456789B12Ja
Nigeriang_tinNigeria, Steueridentifizierungsnummer12345678-0001Nein
Nordmazedonienmk_vatUmsatzsteuer-Identifikationsnummer NordmazedonienMK1234567890123Ja
Norwegenno_vatNorwegische Umsatzsteuer-Identifikationsnummer (USt-IdNr.)123456789MVAJa
Omanom_vatOman, Umsatzsteuer-IdentifikationsnummerOM1234567890Ja
Österreicheu_vatEuropean VAT numberATU12345678Ja
Perupe_rucPeruanische RUC-Nummer12345678901Ja
Philippinenph_tinPhilippinische Steueridentifikationsnummer123456789012Ja
Poleneu_vatEuropean VAT numberPL1234567890Ja
Portugaleu_vatEuropean VAT numberPT123456789Ja
Republik Moldaumd_vatRepublik Moldau, Umsatzsteuer-Identifikationsnummer1234567Ja
Rumänieneu_vatEuropean VAT numberRO1234567891Ja
Russlandru_innRussische INN1234567891Ja
Russlandru_kppRussische KPP123456789Ja
Sambiazm_tinSteueridentifikationsnummer Sambia1004751879Nein
Saudi-Arabiensa_vatSaudi-arabische Umsatzsteuer123456789012345Ja
Schwedeneu_vatEuropean VAT numberSE123456789123Ja
Schweizch_vatUmsatzsteuer-Identifikationsnummer (USt-IdNr.) in der SchweizCHE-123.456.789 MWSTJa
Senegalsn_nineaNINEA-Nummer Senegal12345672A2Nein
Serbienrs_pibSerbische PIB-Nummer123456789Nein
Simbabwezw_tinSteueridentifikationsnummer Simbabwe1234567890Nein
Singapursg_gstSingapurische GSTM12345678XJa
Slowakeieu_vatEuropean VAT numberSK1234567891Ja
Slowenieneu_vatEuropean VAT numberSI12345678Ja
Spanienes_cifSpanische NIF-Nummer (früher spanische CIF-Nummer)A12345678Nein
Spanieneu_vatEuropean VAT numberESA1234567ZJa
Südafrikaza_vatSüdafrikanische Umsatzsteuer-Identifikationsnummer (USt-IdNr.)4123456789Ja
Südkoreakr_brnKoreanische BRN123-45-67890Ja
Surinamesr_finFIN-Nummer Suriname1234567890Ja
Tadschikistantj_tinSteueridentifikationsnummer Tadschikistan123456789Ja
Taiwantw_vatTaiwanesische Umsatzsteuer12345678Ja
Tansaniatz_vatTansania, Umsatzsteuer-Identifikationsnummer12345678AJa
Thailandth_vatThailändische Umsatzsteuer1234567891234Ja
Tschechische Republikeu_vatEuropean VAT numberCZ1234567890Ja
Türkeitr_tinTürkische Steueridentifikationsnummer0123456789Ja
Ugandaug_tinSteueridentifikationsnummer Uganda1014751879Ja
Ukraineua_vatUkrainische Umsatzsteuer123456789Ja
Ungarneu_vatEuropean VAT numberHU12345678Ja
Uruguayuy_rucUruguayische RUC-Nummer123456789012Ja
Usbekistanuz_tinUsbekistan, TIN-Nummer123456789Nein
Usbekistanuz_vatUsbekistan, Umsatzsteuer-Identifikationsnummer123456789012Ja
Vereinigte Arabische Emirateae_trnVereinigte Arabische Emirate TRN123456789012345Ja
Vereinigtes Königreicheu_vatNorthern Ireland VAT numberXI123456789Ja
Vereinigtes Königreichgb_vatUmsatzsteuer-Identifikationsnummer (USt-IdNr.) im Vereinigten KönigreichGB123456789Ja
Zyperneu_vatEuropean VAT numberCY12345678ZJa
War diese Seite hilfreich?
JaNein
  • Benötigen Sie Hilfe? Kontaktieren Sie den Kundensupport.
  • Nehmen Sie an unserem Programm für frühzeitigen Zugriff teil.
  • Schauen Sie sich unser Änderungsprotokoll an.
  • Fragen? Sales-Team kontaktieren.
  • LLM? Lesen Sie llms.txt.
  • Unterstützt von Markdoc