Guide to Using Cron Expressions Supported by EzyPlatform

Updated at 1781364127000
A cron expression is a string that describes a recurring schedule for a task. Instead of writing “run every day at 08:00” directly in code, you can represent it with a short expression like 0 8 * * *. The system parses each time component and calculates the next matching execution time.

Cron Expressions Supported by EzyPlatform

EzyPlatform supports 2 expression formats:
5 fields: minute hour day-of-month month day-of-week
6 fields: second minute hour day-of-month month day-of-week
For 5-field expressions, EzyPlatform automatically treats the second value as 0.
Examples:
* * * * *        every minute, at second 0
0 * * * *        every hour, at minute 0 and second 0
0 8 * * *        every day at 08:00:00
0/30 * * * * *   every 30 seconds

Time Fields

Second       0-59    only in 6-field expressions
Minute       0-59
Hour         0-23
Day of month 1-31
Month        1-12
Day of week  0-6     0 = Sunday, 1 = Monday, ..., 6 = Saturday
Important note: EzyPlatform uses 0 for Sunday. The value 7 is not treated as Sunday.

Field Syntax

EzyPlatform supports the following syntax:
*          every valid value
n          one exact value, for example 5
n-m        value range, for example 1-5
*/step     repeat by step from the minimum value, for example */15
n/step     repeat from n to the maximum value, for example 10/5
n-m/step   repeat by step within a range, for example 9-17/2
a,b,c      list of values, for example 1,15,30
You can combine lists with other forms, for example:
0 8,12,18 * * *      run every day at 08:00, 12:00, and 18:00
0 9-17/2 * * 1-5     run every 2 hours from 09:00 to 17:00, Monday to Friday
EzyPlatform does not support special Quartz syntax such as ?, L, W, #, and does not support the 7th year field.

Common Examples

0/30 * * * * *       every 30 seconds
* * * * *            every minute
0 * * * *            every hour
0 8 * * *            every day at 08:00
0 8 * * 1            every Monday at 08:00
0 0 1 * *            every month on day 1 at 00:00
0 0 1 1 *            every year on January 1 at 00:00
0 30 8 * * 1-5       08:30:00 from Monday to Friday
0 0 9-17/2 * * 1-5   09:00, 11:00, 13:00, 15:00, 17:00 on weekdays
One thing to remember: “day of month” and “day of week” are both checked. For example, 0 8 1 * 1 means 08:00 only on dates that are both day 1 of the month and Monday.

Cron Expression Checker Tool

Using AI to Convert Text to Cron Expressions

You can give this article to an AI assistant and ask it to generate only cron expressions that match EzyPlatform’s supported format.
Suggested prompt:
Read the EzyPlatform cron expression guide above.
Use only the 5-field or 6-field format.
Do not use ?, L, W, #, month names, weekday names, or the year field.
Use 0-6 for day of week, where 0 is Sunday.
Convert the following requirement into a cron expression and explain each field:
[write my requirement here]
Example: “run every 30 seconds” → 0/30 * * * * *.

Table Of Contents