---
id: "us_tin"
kind: "datatype"
status: "draft"
is_pii: true
categories: ["finances", "pii"]
country: ["US"]
langs: ["en"]
quality: 95
url: "https://registry.apicrafter.io/datatype/us_tin"
---

# US taxpayer identification number (TIN) (`us_tin`)

> **Draft.** Draft records have not been reviewed yet and may be incomplete or wrong; do not treat them as authoritative for legal or compliance decisions.

Any number that the US tax system uses to identify a taxpayer: a Social Security Number (usssn), an Individual Taxpayer Identification Number (usitin), an Employer Identification Number (usein), a Preparer Tax Identification Number (usptin) or an Adoption Taxpayer Identification Number (usatin). Use it for columns that mix these kinds.

- Parent datatype: `taxid`
- Personal data (PII): yes
- Categories: Finances and banking (finances), Personally identifiable information (pii)
- Countries: United States (US)
- Languages: English (en)
- Classification: identifier

## Detection

Regular expression (Python `re`):

```
^(?:\d{3}-?\d{2}-?\d{4}|\d{2}-?\d{7}|P-?\d{8})$
```

## Examples

- `536-90-4399` — SSN or ATIN, example from the python-stdnum documentation
- `04-2103594` — EIN, example from the python-stdnum documentation
- `P01594846` — PTIN, example from the python-stdnum documentation
- `00634642` (invalid example) — Eight digits: a PTIN without the P (python-stdnum example)

## Mappings

- stdnum: `us.tin`

## Supported by tools

- `pythonstdnum`

## Sources

- doc: <https://www.irs.gov/individuals/international-taxpayers/taxpayer-identification-numbers-tin>
- doc: <https://arthurdejong.org/python-stdnum/doc/2.2/stdnum.us.tin.html>

## Quality

Score 95/100. Missing: translation.

JSON: <https://registry.apicrafter.io/api/v1/datatypes/us_tin.json> · Edit: <https://github.com/apicrafter/metacrafter-registry/edit/main/data/datatypes/US/finances/us_tin.yaml>
