Avoiding Classic Azure TimerTrigger NCRONTAB Mistakes
Azure Functions TimerTrigger parses schedules with the NCRONTAB library, which requires exactly 6 fields starting with Seconds. Pasting a 5-field POSIX string like */5 * * * * fails function indexing, while pasting a Quartz string containing ? also fails because NCRONTAB rejects question marks.
Be careful when choosing the Seconds field: writing * */5 * * * * triggers 60 times in a row during every 5th minute. Prefixing a fixed second (0 */5 * * * *) ensures exactly one invocation per interval. In Consumption and Flex Consumption plans, remember that WEBSITE_TIME_ZONE expects IANA names on Linux hosts and Windows timezone names on Windows hosts.
- 6-Field NCRONTAB{second} {minute} {hour} {day} {month} {day-of-week} — 0=Sunday..6=Saturday (or SUN–SAT).
- No ? or Year FieldUnlike Quartz and AWS, NCRONTAB does NOT support ? or a 7th Year field; always use * for wildcards.
- Timezone DefaultRuns in UTC by default; override via WEBSITE_TIME_ZONE (Windows ID on Windows plans, IANA ID on Linux plans).
Why does Azure Functions reject 0 0 9 ? * MON-FRI?
NCRONTAB does not support the Quartz/AWS ? character. Replace ? with * to get 0 0 9 * * MON-FRI (or 0 0 9 * * 1-5).
Does NCRONTAB support L (last day of month) or # (nth weekday)?
No. Standard NCRONTAB only supports *, /, -, and , operators. For last-day-of-month logic in Azure Functions, trigger on days 28-31 (0 0 0 28-31 * *) and check DateTime.AddDays(1).Day == 1 inside your function.