Billing
Customers
Customer Tax IDs

Customer Tax IDs

Storing, validating, and rendering customer tax ID numbers with Stripe Billing.

Displaying a customer’s tax ID on invoice documents is a common requirement.

With Stripe, you can add one or multiple tax IDs to a customer. A customer’s tax IDs are displayed in the header of invoice and credit note PDFs.

Supported Tax ID types

Currently, Stripe Billing supports the following Tax ID types in the following regions:

Country Enum Description Example
United Arab Emirates ae_trn United Arab Emirates TRN 123456789012345
Australia au_abn Australian Business Number (AU ABN) 12345678912
Brazil br_cnpj Brazilian CNPJ number 01.234.456/5432-10
Brazil br_cpf Brazilian CPF number 123.456.789-87
Canada ca_bn Canadian BN 123456789
Canada ca_qst Canadian QST number 1234567890TQ1234
Switzerland ch_vat Switzerland VAT number CHE-123.456.789 MWST
Chile cl_tin Chilean TIN 12.345.678-K
Spain es_cif Spanish CIF number A12345678
Austria eu_vat European VAT number ATU12345678
Belgium eu_vat European VAT number BE0123456789
Bulgaria eu_vat European VAT number BG0123456789
Cyprus eu_vat European VAT number CY12345678Z
Czech Republic eu_vat European VAT number CZ1234567890
Germany eu_vat European VAT number DE123456789
Denmark eu_vat European VAT number DK12345678
Estonia eu_vat European VAT number EE123456789
Spain eu_vat European VAT number ESA1234567Z
Finland eu_vat European VAT number FI12345678
France eu_vat European VAT number FRAB123456789
United Kingdom eu_vat European VAT number GB123456789
Greece eu_vat European VAT number EL123456789
Croatia eu_vat European VAT number HR12345678912
Hungary eu_vat European VAT number HU12345678912
Ireland eu_vat European VAT number IE1234567AB
Italy eu_vat European VAT number IT12345678912
Lithuania eu_vat European VAT number LT123456789123
Luxembourg eu_vat European VAT number LU12345678
Latvia eu_vat European VAT number LV12345678912
Malta eu_vat European VAT number MT12345678
Netherlands eu_vat European VAT number NL123456789B12
Poland eu_vat European VAT number PL1234567890
Portugal eu_vat European VAT number PT123456789
Romania eu_vat European VAT number RO1234567891
Sweden eu_vat European VAT number SE123456789123
Slovenia eu_vat European VAT number SI12345678
Slovakia eu_vat European VAT number SK1234567891
Hong Kong hk_br Hong Kong BR number 12345678
Indonesia id_npwp Indonesian NPWP number 12.345.678.9-012.345
India in_gst Indian GST number 12ABCDE3456FGZH
Japan jp_cn Japanese Corporate Number (Hōjin Bangō) 1234567891234
Japan jp_rn Japanese Registered Foreign Businesses’ Registration Number (Tōroku Kokugai Jigyōsha no Tōroku Bangō) 12345
Korea, Republic of kr_brn Korean BRN 123-45-67890
Liechtenstein li_uid Liechtensteinian UID number CHE123456789
Mexico mx_rfc Mexican RFC number ABC010203AB9
Malaysia my_frp Malaysian FRP number 12345678
Malaysia my_itn Malaysian ITN C 1234567890
Malaysia my_sst Malaysian SST number A12-3456-78912345
Norway no_vat Norwegian VAT number 123456789MVA
New Zealand nz_gst New Zealand GST number 123456789
Russian Federation ru_inn Russian INN 1234567891
Russian Federation ru_kpp Russian KPP 123456789
Saudi Arabia sa_vat Saudi Arabia VAT 123456789012345
Singapore sg_gst Singaporean GST M12345678X
Singapore sg_uen Singaporean UEN 123456789F
Thailand th_vat Thai VAT 1234567891234
Taiwan tw_vat Taiwanese VAT 12345678
United States us_ein United States EIN 12-3456789
South Africa za_vat South African VAT number 4123456789

Validation

You are responsible for ensuring customer information, including their tax identification number, is accurate. Stripe will display a customer tax ID on an invoice, regardless of whether or not it is valid.

Stripe Billing provides automatic validation to help determine if formatting is correct. Stripe also provides automatic validation with government databases for the tax ID types below.

European Value-Added-Tax (EU VAT) Numbers

Stripe automatically validates all European Value-Added-Tax (EU VAT) numbers with the European Commission’s VAT Information Exchange System (VIES). This process only validates whether or not the tax ID is valid—you’ll still need to verify the customer’s name and address to make sure it matches the registration information.

VIES validation usually takes only a few seconds, but depending on the availability of various government databases, may take longer. Stripe will automatically handle VIES downtime and attempt retries for you.

Australian Business Numbers (ABN)

Stripe also automatically validates all Australian Business Numbers (ABNs) with the Australian Business Register (ABR).

Validation webhooks and Dashboard display

Because this validation process happens asynchronously, you will be notified of validation updates via the customer.tax_id.updated webhook.

Hover over a customer’s EU VAT number to display their VIES information.

The results of the validation are displayed in the Dashboard while displaying the customer details, including details returned from the government databases, as well as the registered name and address.

When automatic validation is not available, we strongly recommend that you manually verify these IDs.

Managing

Tax IDs can be managed via the Customer page on the Dashboard, or via the Tax ID API.

The Customer detail page and Tax ID field.

Navigate to the Customer page, clicking the Update details button in the top of the Details panel. The Update customer invoice details modal will appear, with the Tax ID section visible.

Clicking the Add tax ID link will add a row to the Tax ID list, where you can select the ID type and value.

Removing a Tax ID from a customer is as simple as removing the row.

Using the API

You can add or delete Tax IDs using the API.

The following example shows how to create a new Tax ID on a Customer, storing their VAT number.

curl https://api.stripe.com/v1/customers/cus_4fdAW5ftNQow1a/tax_ids \ -u sk_test_4eC39HqLyjWDarjtT1zdp7dc: \ -d value=DE123456789 \ -d type=eu_vat
# Set your secret key. Remember to switch to your live secret key in production! # See your keys here: https://dashboard.stripe.com/account/apikeys Stripe.api_key = 'sk_test_4eC39HqLyjWDarjtT1zdp7dc' Stripe::Customer.create_tax_id( 'cus_4fdAW5ftNQow1a', { type: 'eu_vat', value: 'DE123456789', } )
# Set your secret key. Remember to switch to your live secret key in production! # See your keys here: https://dashboard.stripe.com/account/apikeys stripe.api_key = 'sk_test_4eC39HqLyjWDarjtT1zdp7dc' stripe.Customer.create_tax_id( 'cus_4fdAW5ftNQow1a', type='eu_vat', value='DE123456789', )
// Set your secret key. Remember to switch to your live secret key in production! // See your keys here: https://dashboard.stripe.com/account/apikeys \Stripe\Stripe::setApiKey('sk_test_4eC39HqLyjWDarjtT1zdp7dc'); \Stripe\Customer::createTaxId( 'cus_4fdAW5ftNQow1a', [ 'type' => 'eu_vat', 'value' => 'DE123456789', ] );
// Set your secret key. Remember to switch to your live secret key in production! // See your keys here: https://dashboard.stripe.com/account/apikeys Stripe.apiKey = "sk_test_4eC39HqLyjWDarjtT1zdp7dc"; CustomerRetrieveParams customerParams = CustomerRetrieveParams.builder() .addExpand("tax_ids") .build(); Customer customer = Customer.retrieve( "cus_4fdAW5ftNQow1a, customerParams, null ); TaxIdCollectionCreateParams params = TaxIdCollectionCreateParams.builder() .setType(TaxIdCollectionCreateParams.Type.EU_VAT) .setValue("DE123456789") .build(); TaxId taxId = customer.getTaxIds().create(params);
// Set your secret key. Remember to switch to your live secret key in production! // See your keys here: https://dashboard.stripe.com/account/apikeys const stripe = require('stripe')('sk_test_4eC39HqLyjWDarjtT1zdp7dc'); stripe.customers.createTaxId( 'cus_DqZrTNCO4puf2p', { type: 'eu_vat', value: 'DE123456789', }, function(err, taxId) { // asynchronously called } );
// Set your secret key. Remember to switch to your live secret key in production! // See your keys here: https://dashboard.stripe.com/account/apikeys stripe.Key = "sk_test_4eC39HqLyjWDarjtT1zdp7dc" params := &stripe.TaxIDParams{ Customer: stripe.String("cus_4fdAW5ftNQow1a"), Type: stripe.String(string(stripe.TaxIDTypeEUVAT)), Value: stripe.String("DE123456789"), } taxId, err := taxid.New(params)
// Set your secret key. Remember to switch to your live secret key in production! // See your keys here: https://dashboard.stripe.com/account/apikeys StripeConfiguration.ApiKey = "sk_test_4eC39HqLyjWDarjtT1zdp7dc"; var options = new TaxIdCreateOptions { Type = "eu_vat", Value = "DE123456789", }; var service = new TaxIdService(); var taxId = service.Create("cus_4fdAW5ftNQow1a", options);

You can delete a Tax ID, as shown in the this example:

curl https://api.stripe.com/v1/customers/cus_Euql8T6KrknXwN/tax_ids/txi_123456789 \ -u sk_test_4eC39HqLyjWDarjtT1zdp7dc: \ -X DELETE
# Set your secret key. Remember to switch to your live secret key in production! # See your keys here: https://dashboard.stripe.com/account/apikeys Stripe.api_key = 'sk_test_4eC39HqLyjWDarjtT1zdp7dc' Stripe::Customer.delete_tax_id( 'cus_4fdAW5ftNQow1a', 'txi_123456789', )
# Set your secret key. Remember to switch to your live secret key in production! # See your keys here: https://dashboard.stripe.com/account/apikeys stripe.api_key = 'sk_test_4eC39HqLyjWDarjtT1zdp7dc' stripe.Customer.delete_tax_id( 'cus_4fdAW5ftNQow1a', 'txi_123456789', )
// Set your secret key. Remember to switch to your live secret key in production! // See your keys here: https://dashboard.stripe.com/account/apikeys \Stripe\Stripe::setApiKey('sk_test_4eC39HqLyjWDarjtT1zdp7dc'); \Stripe\Customer::deleteTaxId( 'cus_4fdAW5ftNQow1a', 'txi_123456789', [] );
// Set your secret key. Remember to switch to your live secret key in production! // See your keys here: https://dashboard.stripe.com/account/apikeys Stripe.apiKey = "sk_test_4eC39HqLyjWDarjtT1zdp7dc"; CustomerRetrieveParams customerParams = CustomerRetrieveParams.builder() .addExpand("tax_ids") .build(); Customer customer = Customer.retrieve( "cus_4fdAW5ftNQow1a, customerParams, null ); TaxId taxId = customer.getTaxIds().retrieve("txi_123456789"); taxId.delete();
// Set your secret key. Remember to switch to your live secret key in production! // See your keys here: https://dashboard.stripe.com/account/apikeys const stripe = require('stripe')('sk_test_4eC39HqLyjWDarjtT1zdp7dc'); stripe.customers.deleteTaxId( 'cus_4fdAW5ftNQow1a', 'txi_123456789', function(err, confirmation) { // asynchronously called } );
// Set your secret key. Remember to switch to your live secret key in production! // See your keys here: https://dashboard.stripe.com/account/apikeys stripe.Key = "sk_test_4eC39HqLyjWDarjtT1zdp7dc" params := &stripe.TaxIDParams{ Customer: stripe.String("cus_4fdAW5ftNQow1a"), } taxid, err := taxid.Del("txi_123456789", params)
// Set your secret key. Remember to switch to your live secret key in production! // See your keys here: https://dashboard.stripe.com/account/apikeys StripeConfiguration.ApiKey = "sk_test_4eC39HqLyjWDarjtT1zdp7dc"; var service = new TaxIdService(); service.Delete("cus_4fdAW5ftNQow1a", "txi_123456789");

To update a Tax ID, delete the old ID and create another.