Toolman

Cron expression: twice a day

0 0,12 * * *

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

What each field means

FieldValueMeaning
minute0minute 0
hour0,12hour 0, 12
day of month*every day of month
month*every month
day of week*every day of week

Next runs

Starting from 1 January 2026, 00:00 UTC:

Things to watch

A comma-separated list in the hour field is clearer than a step here, and it makes the intent obvious to whoever reads the crontab next.

The same schedule elsewhere

# crontab
0 0,12 * * * /usr/local/bin/my-job >> /var/log/my-job.log 2>&1

# GitHub Actions (.github/workflows/job.yml) — always UTC
on:
  schedule:
    - cron: '0 0,12 * * *'

# Kubernetes CronJob
spec:
  schedule: "0 0,12 * * *"

# AWS EventBridge — six fields, and ? in one of the day fields
cron(0 0,12 * * ? *)

Frequently asked questions

What is the cron expression to run a job twice a day?

0 0,12 * * *

Which time zone does cron use?

The server's local time zone, unless the scheduler says otherwise. GitHub Actions always uses UTC. Kubernetes CronJobs use UTC unless you set spec.timeZone. Running servers in UTC and converting only for display avoids an entire class of daylight-saving bugs.

What happens if the previous run is still going?

Standard cron starts a new one regardless, so long-running jobs can pile up. Wrap the command in flock -n /var/lock/my-job.lock, or set concurrencyPolicy: Forbid on a Kubernetes CronJob.

Why did my cron job not run at all?

The three usual causes: the script is not executable, the command relies on a PATH or environment variable that cron does not set, or output went nowhere because no mail transport is configured. Redirect stdout and stderr to a log file and the reason usually becomes obvious.

Other schedules

Build a custom cron expression →