DEV Community

Ishwar Sirvi
Ishwar Sirvi

Posted on

I open-sourced 2026 US state sales tax data — free API, MIT licensed

Every year I end up re-Googling "what's California's sales tax this year" or "is grocery taxed in Texas" and landing on a fragmented mix of state revenue PDFs, outdated Wikipedia tables, and SaaS calculators behind signup walls.

So I compiled all 50 states for 2026 into one clean dataset and put it on GitHub under MIT license: https://github.com/receiptedit/us-sales-tax-2026

It's also live as a free REST API (no auth, CORS enabled) at: https://receiptedit.com/api/sales-tax

What's in it

Per state:

  • Statewide sales tax rate
  • Average combined state + local rate
  • Lodging taxes (TOT, occupancy, tourism assessment)
  • Grocery taxation rule (true, false, or "reduced")
  • Top 5 cities
  • Official nickname

Total: ~29 KB of JSON or ~6 KB of CSV for all 50 states.

Three ways to consume it

1. REST API (free, no auth)

const res = await fetch('https://receiptedit.com/api/sales-tax/california');
const data = await res.json();
console.log(`${data.state}: ${data.state_sales_tax_pct}% state`);
Enter fullscreen mode Exit fullscreen mode

CORS is enabled. Cache responses for 24+ hours since the data changes once a year.

2. Direct file download

curl -O https://raw.githubusercontent.com/receiptedit/us-sales-tax-2026/main/us-sales-tax-2026.csv
curl -O https://raw.githubusercontent.com/receiptedit/us-sales-tax-2026/main/us-sales-tax-2026.json
Enter fullscreen mode Exit fullscreen mode

3. Embeddable calculator widget

<iframe src="https://receiptedit.com/api/embed/sales-tax/california" width="380" height="540" style="border:0;max-width:100%" loading="lazy" title="California Sales Tax Calculator"></iframe>
Enter fullscreen mode Exit fullscreen mode

Swap california for any state slug.

A few things that surprised me compiling this

  • 5 states have zero statewide sales tax: Alaska, Delaware, Montana, New Hampshire, Oregon
  • Louisiana and Tennessee are tied at the top: ~9.55% average combined rate
  • 26 states fully exempt groceries from state sales tax
  • Florida has the highest lodging tax burden at the state level

License + use

MIT. Free for any use, commercial or personal. No attribution required.

The repo: https://github.com/receiptedit/us-sales-tax-2026

About

I maintain ReceiptEdit, a free receipt generator with 500+ brand templates and built-in US state sales tax calculators. The dataset above is what powers the calculators on the site — open-sourcing the underlying data felt obvious.

Use it however helps you ship.

Top comments (0)