Structure
0-59
*
0-59
*
0-23
*
1-31
*
1-12
*
0-7
?
1970-2099
*
Cron Expression
0 * * * * ? *
Human-readable description
Every minute
Next 0 run times (fr)
No matching run times
Previous 0 run times (fr)
No matching run times
Calendar preview
juillet 2026
dim.
lun.
mar.
mer.
jeu.
ven.
sam.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
No matches this month
Common presets
Import crontab
支持注释(#)、空行、MAILTO= 环境变量、多任务;自动取第一个有效表达式
Export
crontab line
0 * * * * ? *
systemd OnCalendar
? *-* *:*:00
GitHub Actions
on:
  schedule:
    - cron: '* * * * ?'
Fill the command field above to enable the install command export
Common examples

Cron Expression Complete Guide

A comprehensive guide to understanding and using cron expressions in Quartz format

7 Fields

Core Concepts

Quartz cron expression format consists of 7 fields, representing seconds, minutes, hours, day of month, month, day of week, and year from left to right. Each field supports specific value ranges and special characters, allowing you to precisely schedule task execution times.

Full Format (7 fields)

Seconds(0-59)
Minutes(0-59)
Hours(0-23)
DayofMonth(1-31)
Month(1-12)
DayofWeek(1-7 (1=Sunday))
Year(1970-2099)

Many systems omit the seconds field, using the simplified 6-field format: minutes hours day month day-of-week year

Field Rules

FieldAllowed ValuesSpecial Characters
Seconds (0-59)0-59*/-,
Minutes (0-59)0-59*/-,
Hours (0-23)0-23*/-,
Day of Month (1-31)1-31*/-,LW?
Month (1-12)1-12*/-,
Day of Week (1-7)1-7 (1=Sunday)*/-,L#?
Year (optional)1970-2099*/-,

Special Characters Reference

*Meaning of *

pages.cronGuide.specialChars.any

?Meaning of ?

pages.cronGuide.specialChars.question

-Meaning of -

pages.cronGuide.specialChars.range

/Meaning of /

pages.cronGuide.specialChars.step

,Meaning of ,

pages.cronGuide.specialChars.list

LMeaning of L

pages.cronGuide.specialChars.last

WMeaning of W

pages.cronGuide.specialChars.weekday

LWMeaning of LW

pages.cronGuide.specialChars.lastWeekday

#Meaning of #

pages.cronGuide.specialChars.nthWeekday

Common Scheduling Scenarios

High Frequency Execution

High Frequency
0/2 * * * * ?
Every 2 seconds
📌 Real-time data sync, heartbeat detection
0/10 * * * * ?
Every 10 seconds
📌 Cache refresh, status polling
0/30 * * * * ?
Every 30 seconds
📌 Log collection, health checks
0 * * * * ?
Every minute (0 second)
📌 Minute-level monitoring, data aggregation
0 0/1 * * * ?
Every 5 minutes
📌 Report generation, scheduled analysis
0 0/5 * * * ?
Every 5 minutes
📌 Batch data sync, report delivery

Fixed Hour Execution

Hourly
0 0 0 * * ?
Every hour (0 min)
📌 Hourly system cleanup, cache sweep
0 0 1 * * ?
Every hour (1 min)
📌 Statistical report, rolling window
0 30 6 * * ?
Daily at 6:30 AM
📌 Morning batch, ETL pipeline
0 0 8 * * ?
Daily at 8:00 AM
📌 Daily report generation
0 0 12 * * ?
Daily at noon
📌 Midday summary, system health check
0 0 18 * * ?
Daily at 6:00 PM
📌 End-of-day report, data backup
0 0 22 * * ?
Daily at 10:00 PM
📌 Night batch processing

Multiple Times a Day

Multi-time
0 0 9,13,17 * * ?
9 AM, 1 PM, 5 PM daily
📌 Morning/midday/evening reports
0 30 8,12,18 * * ?
8:30, 12:30, 6:30 PM
📌 Multi-time business reports
0 0 10,15,20 * * ?
10 AM, 3 PM, 8 PM daily
📌 Shift-based task scheduling
0 15 10,14,16 * * ?
10:15, 2:15, 4:15 PM
📌 Periodic status updates
0 45 9,11,15 * * ?
9:45, 11:45, 3:45 PM
📌 Quarterly business notifications

Weekly & Monthly Scheduling

Date/Week
0 0 12 1 * ?
12:00 on 1st of every month
📌 Monthly billing cycle start
0 0 9 15 * ?
9:00 on 15th of every month
📌 Mid-month payroll processing
0 0 0 L * ?
Midnight last day of month
📌 Month-end batch, data archiving
0 30 17 LW * ?
5:30 PM last weekday of month
📌 Month-end reports, settlement
0 0 12 ? * WED
12:00 PM every Wednesday
📌 Weekly team sync
0 30 15 ? * FRI
3:30 PM every Friday
📌 End of week summary
0 0 8 ? * MON
8:00 AM every Monday
📌 Weekly start reminders

Business Hours Scheduling

Business Hours
0 0 9-18/1 * * MON-FRI
Every hour during 9AM-6PM
📌 Hourly customer notifications
0 0/30 9-17 * * MON-FRI
Every 30min during 9AM-5PM
📌 Business hour data sync
0 0 12 ? * MON-FRI
Noon on weekdays
📌 Midday report, system status
0 0 8 ? * 1-5
Every weekday at 8AM
📌 Weekday morning reminders
0 15 10 ? * MON-FRI
10:15 on weekdays
📌 Standup reminder notifications
0 45 17 ? * FRI
5:45 PM on Fridays
📌 Weekend shutdown tasks

Interval & Window Scheduling

Interval Windows
0 0-5 * * * ?
First 6 minutes every hour
📌 Startup tasks, initialization
0 0-30/5 * * * ?
Every 5 minutes in first 30min
📌 Frequent early-hour checks
0 0 14-16 * * ?
Every hour 2PM-4PM
📌 Afternoon batch window
0 0 14-16/2 * * ?
Every 2 hours 2PM-4PM
📌 Bi-hourly afternoon processing
0 30 13-17/1 * * ?
Every hour 1:30-5:30 PM
📌 Extended afternoon batch

Advanced Special Scheduling

Advanced
0 0 12 L * ?
Noon on last day of month
📌 Month-end accounting close
0 0 18 LW * ?
6PM last weekday of month
📌 Month-end financial reports
0 0 10 ? * 6L
10 AM on last Friday
📌 Monthly team retrospective
0 0 10 ? * 5#3
10 AM on 3rd Thursday
📌 Monthly business review
0 0 9 15W * ?
9 AM on nearest weekday to 15th
📌 Mid-month payroll processing
0 0 0 L-2 * ?
2 days before month end
📌 Pre-month-end preparations

Year Constraints

Year-specific
0 0 12 * * ? 2025
Daily at noon in 2025
📌 2025 annual reports
0 0 0 1 1 ? 2026-2028
New Year's Day 2026-2028
📌 Yearly recurring holidays
0 0 9 ? * 6L 2025-2027
9 AM last Fri 2025-2027
📌 Annual team events
0 30 18 31 12 ? 2030
6:30 PM Dec 31 2030
📌 Millennium celebration

Common Mistakes to Avoid

0 0 12 * * 1
0 0 12 ? * 1
Day of week uses number 1-7 (Sunday=1), not 0
0 0 12 L * 6
0 0 12 L * ?
L only works with day of month or day of week, not both
0 0 12 1#2 * ?
0 0 12 ? * 1#2
# must be used with day of week, not day of month
0 0 0 31 2 ?
0 0 0 L 2 ?
For last day of February, use L not 31
0/5 * * * *
0/5 * * * * ?
Standard format requires 6 fields, add ? for Quartz
0 0 0 * * 7
0 0 0 * * 0
Use 0 for Sunday, not 7

Quick Reference Cheatsheet

Every minute0 */1 * * * ?
Every 5 minutes0 */5 * * * ?
Every hour0 0 */1 * * ?
Daily at midnight0 0 0 * * ?
Every Monday morning0 0 8 ? * MON
1st of every month0 0 10 1 * ?
Last Friday of month0 0 12 ? * 6L
Business hours weekdays0 0 9-18/1 * * MON-FRI