Trigger cron error but work on


I’m trying to make some cron jobs run every 30m between 8am and 6pm on weekdays.

0 /30 8-18 ? * MON,TUE,WED,THU,FRI *

On www.cronmaker it works but on n8n it doesn’t, it gave me this error:
ERROR: Invalid cron expression

NodeOperationError: Invalid cron expression
    at Object.trigger (/usr/local/lib/node_modules/n8n/node_modules/n8n-nodes-base/dist/nodes/Schedule/ScheduleTrigger.node.js:448:27)
    at Workflow.runTrigger (/usr/local/lib/node_modules/n8n/node_modules/n8n-workflow/dist/Workflow.js:535:60)
    at Workflow.runNode (/usr/local/lib/node_modules/n8n/node_modules/n8n-workflow/dist/Workflow.js:664:52)
    at /usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/WorkflowExecute.js:590:68
    at processTicksAndRejections (node:internal/process/task_queues:96:5)

what can be wrong

Information on my n8n setup

  • n8n version: 0.222.3
  • Running n8n via (Docker)
  • Operating system: ubuntu

Hi @bruno_alves - welcome to the community! :tada:

Can you try this Cron expression instead and see if that fixes this up?
0,30 8-18 * * 1-5

When I’m copying your expression into Crontab, it doesn’t seem to be valid because it looks like you might have the * in the wrong place - but that should do what you’re looking for.

1 Like

Thanks, that worked.


Hi, i have the same need. a cron to run every 2 minutes between 7 to 21 on some days.

This is not working for me…

2,2 7-21 * * 0-5

Also this

2/2 7-21 * * 0-5

Update: after reading this i change it to

*/2 7-21 * * 0-5

and it works!


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.