Skip to content
SpringCronTools

example · 6 fields

Spring Cron Expression for First weekday

Runs at 00:00:00 on the weekday nearest the 1st of the month, without leaving that month.

spring cron
0 0 0 1W * *

javaJava @Scheduled

@Scheduled(cron = "0 0 0 1W * *")

fieldsField breakdown

  • SEC0at second 00-59
  • MIN0at minute 00-59
  • HR0at 00:000-23
  • DOM1Won the weekday nearest day 1 of the month1-31 · L · W
  • MON*in every month1-12 · JAN-DEC
  • DOW*on every day of the week0-7 · MON-SUN · L · #

next runsNext executions (UTC)

Next execution times in UTC
timedatein
00:00:00Mon, 2 Nov 2026—
00:00:00Tue, 1 Dec 2026—
00:00:00Fri, 1 Jan 2027—
00:00:00Mon, 1 Feb 2027—
00:00:00Mon, 1 Mar 2027—

mistakesCommon mistakes

  • Assuming 1W is always the 1st. If the 1st is a Saturday or Sunday, W moves to the nearest Monday-Friday.
  • Expecting W to move into the next month: the nearest weekday is always inside the current month.

nextRelated Spring cron examples

nextRelated guides

nextRelated tools

Questions

When does 1W not run on the 1st?

When the 1st falls on a weekend. In March 2025 the 1st is a Saturday, so 1W runs on Monday the 3rd.