Cron example · Hours

Every 12 hours in cron

Runs at 00:00 and 12:00 every day.

0 */12 * * * Open in the generator

*/12 in the hour field yields 0 and 12. If you need two runs at times other than midnight and noon, a list is clearer: 0 8,20 * * * runs at 08:00 and 20:00.

A twelve-hour cadence is common for dependency-vulnerability scans and for syncing data that changes slowly but must never be more than half a day old.

Field by field

ValueFieldMeaning
0Minute
0–59
at minute 0
*/12Hour
0–23
every 12 hours
*Day of month
1–31
every day of the month
*Month
1–12 or JAN–DEC
every month
*Day of week
0–7 or SUN–SAT (0 and 7 are Sunday)
every day of the week

Next run times

Computed in your browser from the current time, so you can check the schedule against a clock you trust.

Your timezone (local)

  1. Needs JavaScript.

UTC (GitHub Actions, Kubernetes default)

    Variations

    • 0 8,20 * * *twice a day at 08:00 and 20:00 · see page
    • 0 0 * * *once a day at midnight · see page
    • 30 6,18 * * *twice a day at 06:30 and 18:30 · try it

    Where this expression works

    • Linux and macOS crontab: as written; times follow the system timezone.
    • Kubernetes CronJob: the same five fields; UTC unless spec.timeZone is set.
    • GitHub Actions: the same syntax in UTC, minimum interval five minutes, no @ shortcuts.
    • AWS EventBridge: a different six-field syntax; do not paste this expression unchanged.

    Full platform comparison · Cron tutorial

    FAQ

    Is 0 0,12 * * * the same as 0 */12 * * *?

    Yes. Both fire at 00:00 and 12:00.