The five fields

A common cron expression has five fields: minute, hour, day of month, month, and day of week. Each field narrows when a scheduled job should run.

The most important habit is reading the expression from left to right. A value in the first field controls the minute, not the hour.

  • * * * * * means every minute
  • 0 * * * * means at minute 0 of every hour
  • 0 9 * * 1 means every Monday at 09:00

Common cron examples

Cron is compact, which is useful for configuration but easy to misread during review. Keep a set of known examples nearby and compare your expression with the schedule you expect.

Previewing future run times is a good safety check before deploying reminders, cleanup jobs, billing tasks, reports, or integrations.

  • Every 15 minutes: */15 * * * *
  • Every day at midnight: 0 0 * * *
  • Every weekday at 09:30: 30 9 * * 1-5

Timezone matters

Cron expressions describe calendar times, but the timezone depends on the scheduler. One platform may run jobs in UTC while another uses the server timezone or a configured project timezone.

If a job fires at the wrong local hour, the expression may be correct and the timezone may be the real issue. Check the scheduler documentation and compare the next run times against UTC and local time.

Avoid accidental over-scheduling

A small cron typo can run a job far more often than intended. For example, * in the minute field means every minute, while 0 in the minute field means once per hour at minute zero.

For costly or user-visible jobs, add safeguards in the application code too. The scheduler should trigger work, but the job should still be idempotent and safe to retry.

FAQ

Does cron use seconds?

Classic cron uses five fields and does not include seconds. Some platforms support a sixth seconds field, so always check the scheduler format.

What does */5 mean?

It means every five units in that field. In the minute field, */5 means every five minutes.

Why does my cron job run at the wrong hour?

The most common cause is timezone mismatch between your expectation, the server, and the scheduler configuration.

Use the related tool