Qaynaq LABS · TOOLS

CRON · DECODE

0 0 1 * 4

Run once at midnight on the first day of every month, but only if that day is a Thursday (UTC).

Field-by-field

PositionValueMeaning
minute 0 At minute 0 (top of the hour).
hour 0 At hour 0 (midnight).
day-of-month 1 On the 1st day of the month.
month * Every month.
day-of-week 4 Only if the day is Thursday (0=Sunday, 1=Monday, ..., 4=Thursday).

Next fires (UTC)

  • 2024-01-04 00:00:00 UTC
  • 2024-02-01 00:00:00 UTC
  • 2024-03-07 00:00:00 UTC
  • 2024-04-04 00:00:00 UTC

Watch out for

  • The day-of-month and day-of-week fields are both specified, which creates a logical AND. This means the job will only run if the 1st of the month is a Thursday. If the 1st is not a Thursday, the job will not run that month.
  • Edge case: If the 1st of the month is a Thursday, it will run. Otherwise, it will skip.

Equivalent forms

  • 0 0 1 * 4
  • 0 0 1 * THU

About cron expressions

Cron is the standard format Unix-like systems use to schedule recurring jobs: five space-separated fields representing minute, hour, day of month, month, and day of week. The syntax is dense but unambiguous — once you can read it, you can express almost any schedule.

Qaynaq Labs' cron decoder works in both directions: paste an existing expression to read it out in English, or describe a schedule and get a valid cron string back. Each result includes the next few fire times, any caveats (like end-of-month edge cases), and equivalent alternative forms.

Frequently asked

Why does the job not run every month?

Because the day-of-month (1) and day-of-week (4/Thursday) are both specified, the job only runs when both conditions are met simultaneously. If the 1st of the month is not a Thursday, the job will not run.

Can I simplify this expression?

Yes, if you only care about the day of the week, you can omit the day-of-month field (e.g., '0 0 * * 4' to run every Thursday at midnight). If you only care about the 1st of the month, omit the day-of-week field (e.g., '0 0 1 * *').