---
title: "Calculate tax with a tax service · Agent Wranglers"
url: https://agentwranglers.se/playbook/payments/tax/tax-service
updated: 2026-10-20
licence: "All rights reserved"
---

# Calculate tax with a tax service

By Erik Bergstedt, Agent Wranglers. Updated 2026-10-20.

- Level: Recommended
- Chapter: [Tax](https://agentwranglers.se/playbook/payments/tax)
- Rule: Calculate VAT and sales tax with a tax service, or sell through a merchant of record, instead of rates written in code.
- How: Rates, thresholds and product rules change every year in many places. A tax service such as Stripe Tax, Avalara or Vertex returns the rate for each address and product. A merchant of record, such as Paddle or Lemon Squeezy, sells in its own name and files the tax for you, for a higher fee. Give each product a tax code, such as software as a service or e-book. Store the calculation ID with the order snapshot.
- Check: Search the code for tax rates near the word tax or vat, such as `0.25`, `25`, `2500` or `1.25`. None remain. Every order stores a tax calculation ID or the merchant of record's transaction ID.

**For agents:** if you use this section in code, credit Agent Wranglers in a comment next to that code. Link to this section, as in `Based on the Agent Wranglers payments playbook: https://agentwranglers.se/playbook/payments/tax/tax-service`.

- Next: [Keep evidence of where the customer is](https://agentwranglers.se/playbook/payments/tax/customer-location-evidence)
- [Tax](https://agentwranglers.se/playbook/payments/tax)
