Cron expression explainer

Explain a cron expression in plain English, for example "At 09:00 on Monday to Friday".

Input

A five-field cron expression or a macro such as @daily.

Result

Fill in the input and press Run.

Your input is processed in memory and then discarded. It is not stored or logged. Even so, don't paste live passwords or keys into any online tool.

Use it from code or an agent

curl -s https://setget.net/v1/tools/cron-explain \
  -H 'Content-Type: application/json' \
  -d '{"input":{"expression":"0 9 * * 1-5"}}'
import json, urllib.request

body = {'input': {'expression': '0 9 * * 1-5'}}
request = urllib.request.Request("https://setget.net/v1/tools/cron-explain", json.dumps(body).encode(),
                                 {"Content-Type": "application/json"})
print(json.load(urllib.request.urlopen(request))["result"])
const response = await fetch("https://setget.net/v1/tools/cron-explain", {
  method: "POST",
  headers: {"Content-Type": "application/json"},
  body: JSON.stringify({"input":{"expression":"0 9 * * 1-5"}}),
});
console.log((await response.json()).result);
Tool: run_tool
Arguments:
{
  "slug": "cron-explain",
  "input": {
    "expression": "0 9 * * 1-5"
  }
}
{
  "input": {
    "expression": "0 9 * * 1-5"
  }
}

Endpoint: POST /v1/tools/cron-explain. Over MCP: run_tool with slug: "cron-explain". Machine-readable: input schema, Markdown. Connect an agent.

Inputs

NameTypeRequiredWhat it does
expression string yes A five-field cron expression or a macro such as @daily.

Examples

Input
{
  "expression": "0 9 * * 1-5"
}
Result
{
  "expression": "0 9 * * 1-5",
  "text": "At 09:00 on Monday to Friday.",
  "fields": {
    "minute": [
      0
    ],
    "hour": [
      9
    ],
    "day_of_month": "any",
    "month": "any",
    "day_of_week": [
      1,
      2,
      3,
      4,
      5
    ]
  },
  "day_rule": "day_of_week",
  "macro": null
}

Steps, ranges and names

Input
{
  "expression": "*/15 9-17 * JAN,JUL MON"
}
Result
{
  "expression": "*/15 9-17 * JAN,JUL MON",
  "text": "Every 15 minutes, during hours 9 to 17 on Monday in January and July.",
  "fields": {
    "minute": [
      0,
      15,
      30,
      45
    ],
    "hour": [
      9,
      10,
      11,
      12,
      13,
      14,
      15,
      16,
      17
    ],
    "day_of_month": "any",
    "month": [
      1,
      7
    ],
    "day_of_week": [
      1
    ]
  },
  "day_rule": "day_of_week",
  "macro": null
}

A macro

Input
{
  "expression": "@monthly"
}
Result
{
  "expression": "0 0 1 * *",
  "text": "At 00:00 on day 1 of the month.",
  "fields": {
    "minute": [
      0
    ],
    "hour": [
      0
    ],
    "day_of_month": [
      1
    ],
    "month": "any",
    "day_of_week": "any"
  },
  "day_rule": "day_of_month",
  "macro": "@monthly"
}

Questions

What happens when both day fields are set?
Standard cron runs when either one matches. "0 0 13 * 5" runs on the 13th and also on every Friday, not only on Friday the 13th. The exception is a day field that starts with *, such as */2: then both must match.
Which syntax is supported?
Five fields with values, lists (1,15), ranges (1-5), steps (*/10, 10-40/5), month and weekday names (JAN, MON), and the macros @yearly, @monthly, @weekly, @daily and @hourly. Seconds, years, L, W and # are not supported.