Run a Cron Job Every 30 Minutes

Executes the job every 30 minutes (twice per hour).

crontab -e
*/30****
$*/30 * * * *

Field Breakdown

*/30

Minute

0–59

*

Hour

0–23

*

Day of Month

1–31

*

Month

1–12

*

Day of Week

0–6

How It Works

Using */30 in the minute field schedules the task at the top and middle of each hour (:00 and :30). Two executions per hour is efficient enough for batch processing, database maintenance, and summary generation. This schedule runs 48 times per day, making it a conservative choice that still provides reasonably frequent execution.

The step value 30 divides the hour into two halves. The job fires at minute 0 and minute 30 of every hour. With wildcards in the remaining fields, it runs throughout all 24 hours, every day of the year. This is equivalent to writing "0,30" in the minute field.

Platform Usage

Linux crontab: "*/30 * * * * /usr/bin/cleanup-temp.sh". In Kubernetes CronJobs, set schedule: "*/30 * * * *". For Azure Functions timer triggers, use "0 */30 * * * *" (note: Azure uses a 6-field format with seconds first).

Common Use Cases

1

Running database cleanup jobs

2

Generating half-hourly summary stats

3

Processing batch uploads

4

Checking SSL certificate expiry

try-it

$ crongen --customize "*/30 * * * *"

Want to tweak this schedule or see the next run times?

Open in Generator

Related Examples