TechCompare LogoTechCompare

AWS EventBridge cron vs rate expressions: which scheduler syntax to use

Use rate() for simple recurring intervals (every 5 minutes, every hour, every day). Use cron() for wall-clock schedules (midnight UTC, first Monday of the month, 9 AM weekdays). Always specify a timezone on the rule to avoid the UTC surprise.

AWS EventBridge (formerly CloudWatch Events) supports two schedule expression types: cron(fields) for precise wall-clock scheduling and rate(value unit) for simple recurring intervals. Despite the name, EventBridge cron expressions use 6 fields (not 5), adding a year field. The extra field catches people migrating from Linux cron.

By TechCompare · Updated

Schedule pattern
AWS EventBridge schedules
aws-eventbridge
Category
Platforms
Cloud and container scheduling

How this is calculated

EventBridge cron: cron(0 0 * * ? *) runs at midnight UTC every day. The 6 fields are minute, hour, day-of-month, month, day-of-week, year. The ? placeholder means 'no specific value' and is required in either the day-of-month or day-of-week field (one must be ?, the other a value). EventBridge rate: rate(5 minutes) is equivalent to every-5-minutes cron. Rate expressions only support minute, hour, and day units. For anything more complex than a fixed interval, use cron. EventBridge also supports timezone configuration per rule via the ScheduleExpressionTimezone parameter.

Verdict

EventBridge's cron syntax uses six fields, with a year slot that catches people migrating from Linux cron, and the ? placeholder is mandatory in either day-of-month or day-of-week. rate() handles fixed intervals like 'every 5 minutes' but tops out at day units, so it won't express 'first Monday' or '9 AM weekdays.' Set ScheduleExpressionTimezone on every rule or you'll hit the default-UTC trap.

More Cron scenarios

Frequently asked questions

What's the difference between EventBridge cron() and rate() expressions?
rate() expresses simple fixed intervals: rate(5 minutes), rate(1 hour), rate(7 days), and nothing more complex. cron() expresses wall-clock schedules: midnight UTC daily, 9 AM on weekdays, the first of the month. If you can say it as 'every N units,' use rate(). If it references a clock time or a calendar pattern, you need cron().
Why does EventBridge cron have 6 fields instead of 5?
EventBridge adds a year field at the end: minute, hour, day-of-month, month, day-of-week, year. It also requires a ? placeholder in either the day-of-month or day-of-week field. Linux cron's 5-field expressions don't paste in directly - 0 0 * * * becomes cron(0 0 * * ? *), and every ? versus * mistake shows up as a validation error at deploy time.
Why did my EventBridge schedule fire at the wrong time?
EventBridge evaluates schedules in UTC unless you set the ScheduleExpressionTimezone parameter on the rule. A cron() meant for 9 AM New York fires at 9 AM UTC otherwise, four or five hours early depending on daylight saving. Set the timezone on the rule itself rather than converting the hours by hand, because the parameter also handles DST shifts correctly.