What is a cron job?
A cron job is a task that runs automatically on a schedule — every minute, every night at 2am, or once a month — without anyone clicking anything.
The short answer
Cron is the time-based scheduler built into Unix-like systems (Linux, macOS). A cron job is one entry in its schedule: a command plus the times it should run. The file holding those entries is the crontab ("cron table"). The name comes from chronos, Greek for time.
What a cron job looks like
A crontab line is a schedule followed by the command to run:
That reads as: "at minute 0 of hour 2, every day, every month, every weekday — run the backup script." In other words, 2:00 AM every night.
How the schedule works
The schedule is five fields separated by spaces. A job runs only when every field matches the current time.
| Position | Field | Values |
|---|---|---|
| 1 | Minute | 0–59 |
| 2 | Hour | 0–23 |
| 3 | Day of month | 1–31 |
| 4 | Month | 1–12 |
| 5 | Day of week | 0–6 (Sunday = 0) |
An asterisk * means "every value", so * * * * * runs every single minute. Full reference: the cron cheat sheet.
What people actually use cron jobs for
- Backups — dump a database every night while traffic is low.
- Cleanup — delete expired sessions, temp files or old logs.
- Emails & digests — send a weekly summary every Monday morning.
- Cache warming — rebuild an expensive page before users hit it.
- Polling APIs — fetch exchange rates, stock levels or feeds on a schedule.
- Health checks — ping an endpoint regularly to confirm it's alive.
The problem nobody warns you about
Cron is reliable at starting jobs. It is terrible at telling you when they fail.
By default, cron does not notify you when a script errors, times out, or returns a 500. A broken nightly backup looks exactly like a working one — until the day you need to restore it. This is the single most common cron problem in production, and it's why silent failures can go unnoticed for weeks.
Do you still need a server?
Traditional cron runs on a machine you own and maintain. If that box is down, misconfigured, or gets rebuilt, your schedule quietly disappears with it. On shared hosting you may not even have crontab access.
A hosted cron service removes that dependency: you define the schedule and a URL or webhook, and the service calls it from its own infrastructure — logging every run and alerting you when something breaks. No server to keep alive, no crontab to migrate.
cronjobs.live runs your schedule, calls your URL, records every execution and emails you the moment one fails. Free — unlimited jobs, no credit card.
Related: Cron cheat sheet · How to monitor cron jobs