A reference list of cron expressions you’d actually use in production Apex schedules.
Daily
| Cron | Fires |
|---|
0 0 2 * * ? | 2:00 AM every day |
0 30 5 * * ? | 5:30 AM every day |
0 0 0 * * ? | Midnight every day |
0 0 12 * * ? | Noon every day |
0 0 23 * * ? | 11 PM every day |
Every N hours/minutes
| Cron | Fires |
|---|
0 0 * * * ? | Top of every hour |
0 0 */2 * * ? | Every 2 hours (12 AM, 2, 4, 6, …) |
0 0 */4 * * ? | Every 4 hours |
0 */5 * * * ? | Every 5 minutes |
0 */10 * * * ? | Every 10 minutes |
0 */15 * * * ? | Every 15 minutes |
0 */30 * * * ? | Every 30 minutes |
Specific days of the week
| Cron | Fires |
|---|
0 0 9 ? * MON | Mondays at 9 AM |
0 0 9 ? * MON-FRI | Weekdays at 9 AM |
0 0 9 ? * SAT,SUN | Weekends at 9 AM |
0 0 0 ? * FRI | Midnight every Friday |
0 0 18 ? * FRI | 6 PM every Friday (end-of-week summary) |
Monthly
| Cron | Fires |
|---|
0 0 0 1 * ? | Midnight on the 1st of every month |
0 0 0 15 * ? | Midnight on the 15th of every month |
0 0 0 L * ? | Midnight on the last day of every month |
0 0 9 1 * ? | 9 AM on the 1st of every month |
0 30 6 L * ? | 6:30 AM on the last day of every month |
Nth weekday of month
| Cron | Fires |
|---|
0 0 9 ? * 2#1 | 9 AM, first Monday of each month |
0 0 9 ? * 6#3 | 9 AM, third Friday of each month |
0 0 9 ? * 4#2 | 9 AM, second Wednesday |
0 0 0 ? * 1L | Midnight, last Sunday of each month |
0 0 0 ? * 6L | Midnight, last Friday of each month |
Quarterly / annual
| Cron | Fires |
|---|
0 0 6 1 1,4,7,10 ? | 6 AM on Jan 1, Apr 1, Jul 1, Oct 1 (quarterly) |
0 0 0 1 1 ? | Midnight on January 1 every year |
0 0 0 31 12 ? | Midnight on December 31 |
0 0 0 1 1 ? 2027 | Once: Jan 1, 2027 |
Business hours
| Cron | Fires |
|---|
0 0 9-17 ? * MON-FRI | Every hour, 9 AM through 5 PM, weekdays |
0 0,30 9-17 ? * MON-FRI | Every half hour, 9 AM through 5 PM, weekdays |
0 0 8,12,17 ? * MON-FRI | 8 AM, noon, 5 PM, weekdays |
Sample Apex usage
// Schedule a batch job nightly at 2 AM
System.schedule(
'Nightly Stale Case Cleanup',
'0 0 2 * * ?',
new NightlyCleanupSchedulable()
);
// Quarterly report — 6 AM on the first day of each quarter
System.schedule(
'Quarterly Sales Report',
'0 0 6 1 1,4,7,10 ?',
new QuarterReportSchedulable()
);
// Every 15 minutes
System.schedule(
'Every 15 Min Sync',
'0 */15 * * * ?',
new SyncSchedulable()
);
// Weekly status email — Mondays at 8 AM
System.schedule(
'Weekly Status Email',
'0 0 8 ? * MON',
new WeeklyStatusSchedulable()
);
// Last Friday of the month
System.schedule(
'Month-End Reconciliation',
'0 0 17 ? * 6L',
new MonthEndSchedulable()
);
Common interview follow-ups
- What’s
? for again? — Required in either Day-of-Month or Day-of-Week (never both, never neither). Means “ignore this field.”
- Is
* * * * * ? valid? — Yes — fires every second, but Salesforce rounds to the minute. Don’t actually do this.
- Can I run “every 2 minutes”? —
0 */2 * * * ?. But the platform fires roughly at minute boundaries, so be cautious about precision claims.
Verified against: Apex Developer Guide — Cron Expressions. Last reviewed 2026-05-17.