---
title: "Reverse-charge B2B sales with a checked · Agent Wranglers"
url: https://agentwranglers.se/playbook/payments/tax/reverse-charge-vies
updated: 2026-10-20
licence: "All rights reserved"
---

# Reverse-charge B2B sales with a checked VAT number

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

- Level: Required
- Chapter: [Tax](https://agentwranglers.se/playbook/payments/tax)
- Rule: For services sold to a business in another EU country, check the buyer's VAT number in VIES. Charge no VAT and print "Reverse charge" on the invoice.
- How: Ask for the VAT number at checkout. Check it with the European Commission's VIES service, through its REST API or your tax service. Send your own VAT number with the request to get a consultation number, and store it with the date. If VIES is down, charge VAT or hold the order, then check again. Sales to businesses in your own country still carry VAT.
- Check: A checkout test with an invalid VAT number charges VAT. A valid number from another EU country gives zero VAT, a stored consultation number and the reverse charge note on the invoice.

Example:

```js
async function checkVatNumber(countryCode, vatNumber) {
  const response = await fetch('https://ec.europa.eu/taxation_customs/vies/rest-api/check-vat-number', {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({ countryCode, vatNumber, requesterMemberStateCode: 'SE', requesterNumber: '556677889901' }),
    signal: AbortSignal.timeout(10_000),
  })
  if (!response.ok) throw new Error(`VIES answered ${response.status}`)
  const result = await response.json()
  return { valid: result.valid, consultationNumber: result.requestIdentifier, checkedAt: new Date().toISOString() }
}
```

```python
import requests
from datetime import datetime, timezone

def check_vat_number(country_code: str, vat_number: str) -> dict:
    response = requests.post(
        "https://ec.europa.eu/taxation_customs/vies/rest-api/check-vat-number",
        json={"countryCode": country_code, "vatNumber": vat_number,
              "requesterMemberStateCode": "SE", "requesterNumber": "556677889901"},
        timeout=10,
    )
    response.raise_for_status()
    result = response.json()
    return {"valid": result["valid"], "consultation_number": result.get("requestIdentifier"),
            "checked_at": datetime.now(timezone.utc).isoformat()}
```

**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/reverse-charge-vies`.

- Previous: [Charge EU VAT by the customer's country](https://agentwranglers.se/playbook/payments/tax/eu-vat-oss)
- Next: [Track US sales tax nexus by state](https://agentwranglers.se/playbook/payments/tax/us-sales-tax-nexus)
- [Tax](https://agentwranglers.se/playbook/payments/tax)
