Stripe Tax Setup for SaaS: Automatic Sales Tax & VAT Guide
Set up Stripe Tax for your SaaS: registrations, automatic_tax in Checkout, tax codes, and reverse charge VAT, with working API code for 2026.
You shipped a SaaS, got your first paying customers in three countries, and now you have a quiet, growing tax-compliance problem you’ve been ignoring. Stripe Tax is the feature that makes this tractable without hiring an accountant or wiring up a third-party tax engine. It calculates and collects the right sales tax, VAT, or GST on every charge based on where your customer is and what you’re selling.
This guide covers setting up Stripe Tax for a SaaS the way an indie hacker actually needs it: registrations, enabling automatic tax on Checkout and subscriptions, product tax codes, and the EU reverse-charge case that trips everyone up. Code is current for the 2026 Stripe API.
What Stripe Tax does (and what it doesn’t)
Stripe Tax automatically calculates tax on a transaction based on the customer’s location, your tax registrations, and the tax code of the product. It handles the math, applies the correct rate, collects the tax as part of the charge, and gives you reports for filing.
What it does not do: register your business with tax authorities, or file returns for you. Creating a Tax Registration object in Stripe tells Stripe you’re registered somewhere — it does not register you with the actual government. You still handle registration and filing (Stripe partners with services like Taxually for filing, but that’s separate). Keep that distinction clear or you’ll think you’re compliant when you aren’t.
One important 2026 note: starting April 29, 2026, Stripe processes transactions according to your Stripe Tax settings rather than defaulting to tax-exclusive pricing. Set your defaults deliberately.
Step 1: Set your origin and add registrations
In the Stripe Dashboard, go to the Tax section. First set your origin address (where your business operates from) — this determines some default tax behavior. Then add your tax registrations under the Registrations tab.
A registration tells Stripe “I am registered to collect tax in this jurisdiction, so calculate and collect it here.” Without a registration for a region, Stripe won’t collect tax there even if a sale would technically be taxable — because collecting tax you’re not registered to remit is itself a problem.
You can also create registrations via the API, and even schedule a future effective date:
await stripe.tax.registrations.create({
country: 'US',
country_options: {
us: {
state: 'CA',
type: 'state_sales_tax',
},
},
active_from: 'now',
});
For the EU, a single OSS (One Stop Shop) registration covers all member states:
await stripe.tax.registrations.create({
country: 'IE',
country_options: {
ie: { type: 'oss_union' },
},
active_from: 'now',
});
Start with the jurisdictions where you actually have a registration obligation — usually your home country first, then wherever you cross a sales threshold.
Step 2: Set a tax code on your products
Tax rules differ by what you sell. Most SaaS is “Software as a service (SaaS),” which has a specific Stripe tax code: txcd_10103001. Downloadable software, digital goods, and physical products all have different codes and different rates per jurisdiction.
Set the tax code on the Product (or default it on your account). Via API when creating a product:
await stripe.products.create({
name: 'Pro Plan',
tax_code: 'txcd_10103001', // SaaS
});
Getting the tax code right matters because, for example, SaaS is taxed differently from “downloadable software” in several US states. Pick the code that matches what your customer is actually buying.
Step 3: Enable automatic tax in Checkout
This is the line that turns it all on. When creating a Checkout Session, add automatic_tax:
const session = await stripe.checkout.sessions.create({
mode: 'subscription',
line_items: [{ price: 'price_proMonthly', quantity: 1 }],
customer_email: user.email,
client_reference_id: user.id,
automatic_tax: { enabled: true },
customer_update: { address: 'auto' },
success_url: `${origin}/billing/success?session_id={CHECKOUT_SESSION_ID}`,
cancel_url: `${origin}/pricing`,
});
Two details people miss:
customer_update: { address: 'auto' }is required when you’re updating an existing customer, so Stripe can save the address it collects and use it for tax. Without it, you can hit an error about saving the address to the customer.- Checkout will collect the customer’s address (and a VAT ID for business customers if you enable Tax ID collection) so it can determine the correct jurisdiction. Enable Tax ID collection with
tax_id_collection: { enabled: true }if you sell B2B.
Stripe then adds tax as a separate line on the hosted page, calculated live based on the address entered.
Wiring up billing for an MVP and dreading the tax plumbing? Beag bundles authentication and Stripe payments for micro-SaaS, with Checkout configured so you can flip on Stripe Tax without rebuilding your flow. Ship the product, not the tax engine.
Step 4: Handle subscriptions and existing prices
Enabling automatic tax on new Checkout Sessions does not retroactively apply tax to existing subscriptions, invoices, or Payment Links. Those have to be updated separately. For an existing subscription:
await stripe.subscriptions.update('sub_123', {
automatic_tax: { enabled: true },
});
For recurring billing, once automatic_tax is on, every future invoice for that subscription recalculates tax at renewal based on the customer’s current address and your registrations. If a customer moves countries or you add a registration, the next renewal reflects it automatically.
The reverse-charge / VAT ID case
For B2B sales in the EU, a business customer with a valid VAT ID is generally subject to reverse charge — meaning they account for the VAT, and you charge 0% but must note it. Stripe Tax handles this when you’ve enabled Tax ID collection: if a business customer enters a valid VAT ID in a different EU country than yours, Stripe validates it and applies reverse charge, showing tax as €0 with the correct exemption reason.
This is why B2B SaaS should almost always enable tax_id_collection. Without it, you’d overcharge EU business customers VAT they shouldn’t pay, and they’ll notice.
Inclusive vs exclusive pricing
Decide whether your listed prices include tax or add it on top. In the US, prices are typically tax-exclusive (tax added at checkout). In much of the EU and UK, B2C prices are expected to be tax-inclusive. Configure this per-price with tax_behavior:
await stripe.prices.create({
product: 'prod_123',
unit_amount: 1900,
currency: 'usd',
recurring: { interval: 'month' },
tax_behavior: 'exclusive', // or 'inclusive'
});
Set this when you create prices. Changing it later means creating new prices, since tax_behavior is immutable on an existing price.
Tradeoffs and cost
Stripe Tax isn’t free — it bills a per-transaction fee on top of standard processing. For an indie SaaS doing global sales, that’s usually far cheaper than a standalone tax engine or the risk of getting compliance wrong. The honest tradeoff: it removes the calculation and collection burden, but you still own registration decisions and filing. It’s a calculator and collector, not a tax department.
Wrapping up
The full Stripe Tax setup is: set your origin, add registrations for the jurisdictions where you’re obligated, tag products with the right tax code (txcd_10103001 for SaaS), and add automatic_tax: { enabled: true } plus customer_update: { address: 'auto' } to your Checkout Sessions. Enable Tax ID collection if you sell B2B so reverse charge works. Update existing subscriptions separately.
If you want auth and Stripe billing that’s ready for tax without the wiring, Beag adds both to your MVP in minutes →
Ready to Make Money From Your SaaS?
Turn your SaaS into cash with Beag.io. Get started now!
Start 7-day free trial →