Twice Daily (Midnight and Noon)
0 0,12 * * * 0 0 0,12 * * ? 0 0,12 * * * 0 0,12 * * ? * 0 0 0,12 * * * 0 0,12 * * * Runs twice a day at 00:00 and 12:00 — midnight and noon. 2 invocations per day.
Use in your stack
# Twice a day, midnight and noon
0 0,12 * * * /usr/local/bin/half-day-sync.sh
{ "cron": "0 0 0,12 * * ?", "timezone": "UTC" }
apiVersion: batch/v1
kind: CronJob
metadata:
name: half-day-sync
spec:
schedule: "0 0,12 * * *"
timeZone: "UTC"
jobTemplate:
spec:
template:
spec:
containers:
- name: sync
image: my-image:latest
restartPolicy: OnFailure
cron(0 0,12 * * ? *)
@Scheduled(cron = "0 0 0,12 * * *")
public void twiceDaily() { /* ... */ }
on:
schedule:
- cron: '0 0,12 * * *'
Next runs
Pick a timezone to see when this expression fires next.
Next 10 runs
- 012026-07-04T00:00:00.000Z
- 022026-07-04T12:00:00.000Z
- 032026-07-05T00:00:00.000Z
- 042026-07-05T12:00:00.000Z
- 052026-07-06T00:00:00.000Z
- 062026-07-06T12:00:00.000Z
- 072026-07-07T00:00:00.000Z
- 082026-07-07T12:00:00.000Z
- 092026-07-08T00:00:00.000Z
- 102026-07-08T12:00:00.000Z
Variations
Common use cases
- AM/PM data syncs.
- Twice-daily summary digests (overnight + midday).
- Rotating short-lived credentials twice a day.
- Half-day report generation.
Gotchas
- The comma list `0,12` in the hour field is what produces the two firing times. Functionally identical to `0 */12 * * *`.
- Timezone matters — "midnight and noon" is only meaningful in the timezone you intend.
- AWS EventBridge: `0 0,12 * * ? *`. Quartz: `0 0 0,12 * * ?`.
0 0,12 * * * is the twice-a-day schedule — AM and PM, midnight and noon. The comma list in the hour field is the cleanest way to express “these specific times,” and it scales to any number of daily firing times.
Frequently asked questions
What does `0 0,12 * * *` mean?
Minute `0`, hour `0,12` (a comma list — midnight and noon), day-of-month `*` (any), month `*` (any), day-of-week `*` (any). So the job fires at 00:00 and 12:00 every day — twice a day.
Is `0 0,12 * * *` the same as `0 */12 * * *`?
Yes — functionally identical. Both fire at 00:00 and 12:00. The comma form `0,12` lists the two hours explicitly; the step form `*/12` says "every 12th hour from 0." Many teams prefer the comma form because the firing times are obvious at a glance.
How do I run twice daily at different times, like 8 AM and 8 PM?
Change the hour list. `0 8,20 * * *` fires at 8 AM and 8 PM. `0 6,18 * * *` fires at 6 AM and 6 PM. Any two (or more) hours can go in the comma list: `0 9,13,17 * * *` fires three times.
What timezone does this use?
Depends on the scheduler. Linux crontab uses system time; Kubernetes CronJob defaults to UTC; AWS EventBridge and GitHub Actions are always UTC. Pin the timezone explicitly so "midnight and noon" fire at the local times you intend.
Browse all cron patterns
Every schedule Cronuru documents, with its expression and code snippets for six dialects.