---
id: "week_of_year"
kind: "datatype"
status: "draft"
is_pii: false
categories: ["datetime"]
langs: ["common"]
quality: 80
url: "https://registry.apicrafter.io/datatype/week_of_year"
---

# Week number in a year (`week_of_year`)

> **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.

Number of a week within a year, from 1 to 53, sometimes written with a leading zero. Most years have 52 weeks. The rule for week 1 depends on the system; ISO 8601 weeks start on Monday and week 1 contains the first Thursday of the year. Data catalogs keep it in columns such as week, semaine or semana.

- Personal data (PII): no
- Categories: Date and time (datetime)
- Countries: global
- Languages: Common to most languages (common)
- Classification: categorical

## Detection

Regular expression (Python `re`):

```
^(?:0?[1-9]|[1-4]\d|5[0-3])$
```

## Examples

- `1` — first week of the year
- `05` — fifth week, with a leading zero
- `53` — last week of a 53-week year
- `54` (invalid example) — no year has 54 weeks

## Translations

- ru: Номер недели в году
- fr: Numéro de semaine

## Sources

- wikipedia: <https://en.wikipedia.org/wiki/ISO_week_date>

## Quality

Score 80/100. Missing: mapping (Wikidata, Schema.org, ...), detector coverage.

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