Attributes · <input type="month">
Which HTML input type=month attributes matter?
These attributes decide how the <input type="month"> behaves and what actually gets emailed to your inbox when someone submits.
| Attribute | What it does | Docs |
|---|---|---|
value | The default month in YYYY-MM format (such as 2026-11). This is also the format the form submits. | MDN |
min | The earliest month allowed, in YYYY-MM format (such as 2026-01). | MDN |
max | The latest month allowed, in YYYY-MM format (such as 2027-12). | MDN |
step | The step in months. The default is 1. Use 3 to allow every third month, counted from min. | MDN |
required | Requires a month to be chosen before the form can be submitted. | MDN |
list | The id of a <datalist> with suggested months, each as a YYYY-MM value. | MDN |




