Cron tools › Platforms
Azure Functions timer (NCRONTAB)
Type the schedule of an Azure Functions timer trigger. See what it means, when it fires in UTC or in the zone set by
WEBSITE_TIME_ZONE, and copy the binding for function.json, C# or JavaScript.
Next runs
Binding
Convert from Linux cron
Try one
How to write an Azure Functions timer schedule
- Type the expression with six fields, seconds first.
0 */5 * * * *is every five minutes; five-field expressions are accepted too. - Leave the zone on UTC, the default, or pick the zone you set in
WEBSITE_TIME_ZONE. Check that your plan supports it (table below). - Read the meaning and the next runs. Azure's NCRONTAB has no
?,L,Wor#, and the checker says so if you use them. - Copy the binding for your programming model:
function.json, the C# isolated worker attribute, or the JavaScript v4app.timercall. - Starting from a Linux crontab line? Paste it under Convert from Linux cron.
NCRONTAB fields
| Position | Field | Values |
|---|---|---|
| 1 | second | 0-59 |
| 2 | minute | 0-59 |
| 3 | hour | 0-23 |
| 4 | day | 1-31 |
| 5 | month | 1-12 or names |
| 6 | day-of-week | 0-6 (0 = Sunday) or names |
Each field takes *, lists (,), ranges (-) and steps (/). When day and day-of-week are
both set, both must match: 0 0 0 1 * 1 runs only when the 1st is a Monday.
Time zones and hosting plans
Timer schedules are evaluated in UTC unless the app setting WEBSITE_TIME_ZONE says otherwise, and what it accepts depends on the plan:
| Plan | WEBSITE_TIME_ZONE |
|---|---|
| Windows | a Windows time zone name, as listed by tzutil |
| Linux, Premium or Dedicated | a tz database name, e.g. America/New_York |
| Linux, Consumption or Flex Consumption | not supported: schedules stay in UTC |
From Linux cron to NCRONTAB
Add a seconds field in front (30 9 * * 1-5 becomes 0 30 9 * * 1-5) and write Sunday as 0, since Azure
rejects 7. As with Spring, a Linux line that sets both day fields means "either" on Linux and "both" on Azure, so the converter splits it into
two schedules, one per function. The same line for other schedulers is on cron to code.
FAQ
Why does Azure use six fields?
NCRONTAB starts with a seconds field: {second} {minute} {hour} {day} {month} {day-of-week}. A five-field expression
(no seconds) is also accepted.
How do I run an Azure Function every 5 minutes?
0 */5 * * * *. Note the leading 0: */5 * * * * * would run every five seconds.
Does WEBSITE_TIME_ZONE work on the Linux Consumption plan?
No. It is not supported on Linux Consumption or Flex Consumption, so schedules there run in UTC. Convert the local time to UTC yourself, for example with the time zone converter.
Can I say "last day of the month" in NCRONTAB?
No: there is no L, W or #. Schedule the function on days 28-31 and return early unless tomorrow is the 1st.