Rule uk_minimum_wage v1
The UK hourly minimum wage from 1 April 2026, transcribed from GOV.UK
Try a case
Enter the inputs: the rows that match light up and the outputs appear. What runs is the generated code itself, and the line it would write to a log is shown as it is.
Inputs
| Name | Type | Range | Notes |
|---|---|---|---|
| age | number | 16 to 70 | |
| apprentice | bool | ||
| first_year | bool |
Outputs
| Name | Type | Rounding | Notes |
|---|---|---|---|
| hourly | money[GBPc] | down(1GBPc) (rounded down to 1GBPc) |
Table by_age (policy unique)
Source: gov table1 (sources/uk-nmw.md, sha256:bc45eedf7f908896)
Age group Hourly rate 21 and over £12.71 18 to 20 £10.85 Under 18 £8 Apprentice £8
| Column | Source |
|---|---|
| age | Input |
| → hourly | Output of this rule |
| # | age | → hourly (money[GBPc] / down(1GBPc)) |
|---|---|---|
| 1 | <18 (less than 18) | 800GBPc |
| 2 | >=18 <=20 (from 18 to 20) | 1085GBPc |
| 3 | >=21 (21 or more) | 1271GBPc |
What rulec check verified is under "How hourly is decided".
Table apprentice_rate (policy unique)
Source: gov table1 (sources/uk-nmw.md, sha256:bc45eedf7f908896)
Age group Hourly rate 21 and over £12.71 18 to 20 £10.85 Under 18 £8 Apprentice £8
| Column | Source |
|---|---|
| apprentice | Input |
| first_year | Input |
| age | Input |
| → hourly | Output of this rule |
| # | apprentice | first_year | age | → hourly (money[GBPc] / down(1GBPc)) |
|---|---|---|---|---|
| 1 | true (yes) | - | <19 (less than 19) | 800GBPc |
| 2 | true (yes) | true (yes) | >=19 (19 or more) | 800GBPc |
A - means the column may be any value.
What rulec check verified is under "How hourly is decided".
How hourly is decided
hourly is defined by table by_age, table apprentice_rate; they are tried in the order table apprentice_rate, table by_age, and the first that applies is the answer.
- table apprentice_rate takes precedence over table by_age. in some of the 4 pairs that meet, the rows of table apprentice_rate reach beyond the other's (precedence)
What rulec check verified
- Every combination of inputs matches some row of table by_age, table apprentice_rate (E101 completeness)
- There is no row that can never match (E102 unreachable row)
- No overlap is left without a precedence (E105). An input that matches two definitions is decided by the precedence above
Examples (verified)
| age | apprentice | first_year | → hourly |
|---|---|---|---|
| 25 | false | false | 1271GBPc |
| 19 | false | false | 1085GBPc |
| 17 | false | false | 800GBPc |
| 25 | true | true | 800GBPc |
| 25 | true | false | 1271GBPc |
| 18 | true | false | 800GBPc |
rulec check ran these 6 examples through the reference evaluator, and every one produced the declared values (E107). The examples are an executable specification.