---
title: "TaxNumber – API-Referenz · Quittio"
description: "German tax number (Steuernummer, BT-32) as described in \"Prüfung der Steuer- und Steueridentifikationsnummer\" of the Bayerisches Landesamt für Steuern (ELSTER, as of 2 September 2026): the 13-digit ELSTER format FFFF0BBBUUUUP (NRW: FFFF0BBBBUUUP), the 12-digit federal format without the 0, and the notation of the federal states on tax notices (e.g. 181/815/08155 in Bavaria, 133/8150/8159 in NRW)."
canonical_url: "https://quittio.dev/docs/api/Quittio/Country/DE/Support/TaxNumber"
locale: de
meta:
  "og:description": "German tax number (Steuernummer, BT-32) as described in \"Prüfung der Steuer- und Steueridentifikationsnummer\" of the Bayerisches Landesamt für Steuern (ELSTER, as of 2 September 2026): the 13-digit ELSTER format FFFF0BBBUUUUP (NRW: FFFF0BBBBUUUP), the 12-digit federal format without the 0, and the notation of the federal states on tax notices (e.g. 181/815/08155 in Bavaria, 133/8150/8159 in NRW)."
  "og:image": "https://quittio.dev/og/quittio-de.jpg"
  "og:image:alt": "Quittio: E-Rechnungen für PHP und Laravel. Rechtssicher, validiert, archiviert, mit geprüfter Beispielrechnung."
  "og:image:height": "630"
  "og:image:type": image/jpeg
  "og:image:width": "1200"
  "og:title": "TaxNumber – API-Referenz · Quittio"
  "twitter:image": "https://quittio.dev/og/quittio-de.jpg"
  "twitter:image:alt": "Quittio: E-Rechnungen für PHP und Laravel. Rechtssicher, validiert, archiviert, mit geprüfter Beispielrechnung."
---

> Index of every page on this site: [llms.txt](https://quittio.dev/llms.txt)

[API reference](https://quittio.dev/docs/api) / [Quittio](https://quittio.dev/docs/api/Quittio) \\ [Country](https://quittio.dev/docs/api/Quittio/Country) \\ [DE](https://quittio.dev/docs/api/Quittio/Country/DE) \\ [Support](https://quittio.dev/docs/api/Quittio/Country/DE/Support)

# TaxNumber

final readonly class in quittio/country-de

`Quittio\Country\DE\Support\TaxNumber` · [Source](https://github.com/Quittio/quittio/blob/v0.7.1/packages/country-de/src/Support/TaxNumber.php#L22)

German tax number (Steuernummer, BT-32) as described in "Prüfung der Steuer- und Steueridentifikationsnummer" of the Bayerisches Landesamt für Steuern (ELSTER, as of 2 September 2026): the 13-digit ELSTER format FFFF0BBBUUUUP (NRW: FFFF0BBBBUUUP), the 12-digit federal format without the 0, and the notation of the federal states on tax notices (e.g. 181/815/08155 in Bavaria, 133/8150/8159 in NRW).

A number is valid when it passes the formal checks and the check digit procedure of its state: the modified 11 procedure (Rhineland-Palatinate), the 2 procedure (Baden-Württemberg, Hesse, Schleswig-Holstein) or the 11 procedure with the factors of the state (all others, Berlin with the variants A and B). A state notation without the state is checked against every state that uses it; as several states share a notation (e.g. FF/BBB/UUUUP), parse() then returns the first valid interpretation unless the state is given. Whether the tax office exists (ELSTER list of tax offices) is not checked.

## Constants \#

| Constant | Value | Description |
| --- | --- | --- |
| `STATE_PREFIXES` | `['10' => 'SL', '11' => 'BE', '21' => 'SH', '22' => 'HH', '23' => 'NI', '24' => 'HB', '26' => 'HE', '27' => 'RP', '28' => 'BW', '30' => 'BB', '31' => 'ST', '32' …` | First digits of the ELSTER format (Bundesfinanzamtsnummer) => state (ISO 3166-2:DE). |

## Methods \#

| Method | Description |
| --- | --- |
| `->formatted()` | Notation on tax notices, e.g. 181/815/08155 or 133/8150/8159. |
| `::looksLikeVatId()` | A VAT identification number (DE + 9 digits) given as tax number. |
| `::parse()` | The valid tax number in any notation, or null when it is invalid or cannot be checked. |
| `::validate()` | true = valid, false = invalid, null = plausible but not checkable (a Bavarian notation without the tax office number, BBB/UUUUP). |

### `formatted()`#

```
public function formatted(): string
```

Notation on tax notices, e.g. 181/815/08155 or 133/8150/8159.

<dl><dt>Returns</dt>
<dd><code>string</code></dd>
</dl>

### `looksLikeVatId()`#

```
public static function looksLikeVatId(string $value): bool
```

static

A VAT identification number (DE + 9 digits) given as tax number.

| Parameter | Type | Description |
| --- | --- | --- |
| `$value` | `string` | |

<dl><dt>Returns</dt>
<dd><code>bool</code></dd>
</dl>

### `parse()`#

```
public static function parse(string $value, string|null $state = null): ?self
```

static

The valid tax number in any notation, or null when it is invalid or cannot be checked.

| Parameter | Type | Description |
| --- | --- | --- |
| `$value` | `string` | |
| `$state` | `string\|null` = `null` | ISO 3166-2:DE code (e.g. BY) to read a state notation |

<dl><dt>Returns</dt>
<dd><code>?self</code></dd>
</dl>

### `validate()`#

```
public static function validate(string $value, ?string $state = null): ?bool
```

static

true = valid, false = invalid, null = plausible but not checkable (a Bavarian notation without the tax office number, BBB/UUUUP).

| Parameter | Type | Description |
| --- | --- | --- |
| `$value` | `string` | |
| `$state` | `?string` = `null` | |

<dl><dt>Returns</dt>
<dd><code>?bool</code></dd>
</dl>

```json
{"@context":"https://schema.org","@graph":[{"@id":"https://quittio.dev/#website","@type":"WebSite","description":"E-Rechnungen für PHP und Laravel: ZUGFeRD, XRechnung und Peppol erstellen, prüfen, lesen und archivieren.","inLanguage":"de-DE","name":"Quittio","url":"https://quittio.dev/","publisher":{"@id":"https://quittio.dev/#identity"},"workTranslation":{"@id":"https://quittio.dev/en#website"}},{"@id":"https://quittio.dev/docs/api/Quittio/Country/DE/Support/TaxNumber#webpage","@type":"WebPage","description":"German tax number (Steuernummer, BT-32) as described in \"Prüfung der Steuer- und Steueridentifikationsnummer\" of the Bayerisches Landesamt für Steuern (ELSTER, as of 2 September 2026): the 13-digit ELSTER format FFFF0BBBUUUUP (NRW: FFFF0BBBBUUUP), the 12-digit federal format without the 0, and the notation of the federal states on tax notices (e.g. 181/815/08155 in Bavaria, 133/8150/8159 in NRW).","name":"TaxNumber – API-Referenz","url":"https://quittio.dev/docs/api/Quittio/Country/DE/Support/TaxNumber","isPartOf":{"@id":"https://quittio.dev/#website"},"potentialAction":[{"@type":"ReadAction","target":["https://quittio.dev/docs/api/Quittio/Country/DE/Support/TaxNumber"]}],"primaryImageOfPage":{"@id":"https://quittio.dev/#logo"}},{"@id":"https://quittio.dev/#identity","@type":"Organization","description":"Open-Source-Bibliothek für E-Rechnungen in PHP und Laravel (ZUGFeRD, XRechnung, Peppol) und Quittio Managed.","email":"kontakt@niklasforst.de","legalName":"Niklas Forst – Softwareentwicklung","name":"Quittio","url":"https://quittio.dev","founder":{"@type":"Person","name":"Niklas Forst","url":"https://quittio.dev/ueber"},"logo":{"@id":"https://quittio.dev/#logo"},"sameAs":["https://github.com/Quittio/quittio","https://packagist.org/packages/quittio/quittio"]},{"@id":"https://quittio.dev/#logo","@type":"ImageObject","caption":"Quittio","contentUrl":"https://quittio.dev/logo.png","inLanguage":"de-DE","url":"https://quittio.dev/logo.png"}]}
```