---
title: "macOS Cron Silently Drops Jobs During Sleep"
aliases: [macos-cron-sleep, cron-missed-jobs-macos]
tags: [macos, cron, scheduling, launchd, sleep]
sources:
  - "daily/2026-05-07.md"
created: 2026-05-07
updated: 2026-05-08
---

# macOS Cron Silently Drops Jobs During Sleep

## The Problem

macOS cron jobs are skipped without any catch-up if the machine is asleep at the scheduled trigger time. Unlike Linux servers, MacBooks regularly sleep — making standard cron unreliable for time-sensitive scripts.

**Symptom:** Scheduled scripts appear to run only occasionally. Log files show gaps that align with periods when the laptop was closed/sleeping.

## Diagnosis

Check the system log for cron activity:

```bash
log show --predicate 'process == "cron"' --last 24h
# or
log show --predicate 'process == "cron"' --style compact --last 48h
```

If runs are missing for times the machine was asleep → confirmed cron sleep-drop behavior.

## Key Behavior

| Condition | cron behavior |
|-----------|--------------|
| Machine awake at trigger time | Job runs normally |
| Machine asleep at trigger time | Job is **silently skipped**, no retry |
| Machine wakes up after missed trigger | No catch-up |

## Solution

Replace cron with [[wiki/concepts/macos-launchd-catchup-cron-replacement|launchd + RunCatchUpIfMissed=true]].

## Related Concepts

- [[wiki/concepts/macos-launchd-catchup-cron-replacement]] — correct cron replacement for macOS laptops with sleep catch-up
- [[wiki/concepts/macos-python-version-hooks]] — macOS-specific script execution gotchas

## Sources

- [[daily/2026-05-07.md]] — sync_to_forgejo.sh was missing scheduled runs; diagnosed as cron sleep-drop; migrated to launchd agent
