CronTool
Cron expression editor & debugger
Question

Can I set up a cron job to run every 15 minutes throughout the day, except for 3:00 AM? I have another task that I want to run at 3:00 AM and don't want these two conflicting.

Answer

This is only possible with 3 separate crons:


# Every 15 minutes except for 3:00-3:59
*/15 0-2,4-23 * * * command
# 3:15, 3:30, 3:45
15-45/15 3 * * * command
# 3:00 dead
0 3 * * * other_command
Why this matters

Crontab evaluates each line independently. There's no way to say “every 15 minutes except these” in a single line — the minute field accepts a list (0,15,30,45), a step (*/15), and ranges, but it has no negation operator.


The pattern in the answer is the canonical workaround: split the day into two ranges of hours (0-2 and 4-23) and exclude the hour you don't want via the hour field. The second cron line handles the surviving slots within the excluded hour (3:15, 3:30, 3:45 — everything except 3:00). The third cron line schedules the conflicting job at exactly 3:00, ensuring it has the slot to itself.


A more advanced approach uses a wrapper script that exits early when the current time matches the exclusion window — but that hides the schedule from crontab -l, which often hurts more than it helps. Stick with multi-line cron when you want the schedule to be self-documenting, and use the multi-cron visualizer to confirm there's no overlap.

Read the dedicated guide: Cron every 15 minutes.

Cron schedules used

See this cron expression on the calendar → view example

Related cron questions

Other answers and worked examples for the most confusing cron expressions.

QuestionI want to execute a task every 20 minutes, starting at 5 past the hour, is it possible to achieve this with Cron?
QuestionIs it possible to use cron to accomplish the following particular use case? I desire for the scheduler to trigger every five minutes from a specific start time, such as 1:00 PM to 5:45 PM.
QuestionHow do I set a cron script for every 5 minutes without using the minutes divisible by 5?
QuestionI am looking to have a script run every 5 minutes, beginning at 13:02, and another script to run every 5 minutes starting at 13:04, so the second script runs two minutes after the start of the first job. How can I accomplish this?

Ready to schedule it?

Point Crontap at any URL. Pick any cron. Done.

WordPress, Shopify, Railway, Cloud Run, Vercel, HubSpot, Ghost, your own box. If it answers HTTP, Crontap can drive it on a clock you can read, in the timezone that actually matters, and page you when something breaks.

Free forever tier ・ No credit card required

Your next schedule
GET/wp-cron.php?doing_wp_cron=1

Schedule

every 5 minutes

Next run

in 23s

Permalink: https://tool.crontap.com/help/crontab-run-every-minute-except-at-hour

Apihustle Logo

This tool is part of the Apihustle suite - a collection of tools to test, improve and get to know your API inside and out.

  • Clobbr logo

    Clobbr

    The app & CLI tool to test API endpoint speed.

    Visit
  • Crontap logo

    Crontap

    Schedule recurring API calls using cron syntax.

    Visit
  • CronTool logo

    CronTool

    Debug multiple cron expressions on a calendar.

    Visit

  • Page AI

    AI Website Generator that designs and writes clean code.

    Visit
  • Shipixen

    Generate customized boilerplates in minutes.

    Visit
  • Page UI

    Landing page UI components for React & Next.js

    Visit