> ## Documentation Index
> Fetch the complete documentation index at: https://docs.vibeflow.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Cron Node

> Schedule workflows to run automatically at specific times

## Overview

The **Cron Node** is a powerful trigger node that automatically starts workflows on a schedule. It enables you to build automated tasks that run at specific intervals, from every second to monthly, without any manual intervention.

## Required Configuration

### Basic Settings

* **Label:** Display name for the node
* **Identifier:** Unique ID for this cron job (must be unique across your entire app)
* **Trigger Interval:** Schedule type: `custom`, `seconds`, `minutes`, `hours`, `days`, `weeks`, or `monthly`

### Schedule Configuration

The configuration varies based on your selected trigger interval:

#### Custom Cron Expression

* **Cron Expression:** Standard 5-part cron format: `minute hour day month weekday`
* Examples:
  * `0 0 * * *`: Daily at midnight UTC
  * `0 9 * * 1-5`: Weekdays at 9:00 AM UTC
  * `*/15 * * * *`: Every 15 minutes
  * `0 0 1 * *`: First day of each month at midnight

#### Seconds

* **Interval:** Number of seconds between runs (e.g., 30 = every 30 seconds)

#### Minutes

* **Interval:** Number of minutes between runs (e.g., 5 = every 5 minutes)

#### Hours

* **Days Interval:** Number of hours between runs
* **Trigger Minute** (Optional): Minute of the hour to run at

#### Days

* **Days Interval:** Number of days between runs
* **Trigger Hour:** Hour of the day (0-23, UTC)
* **Trigger Minute:** Minute of the hour (0-59)

#### Weeks

* **Trigger Hour:** Hour of the day (0-23, UTC)
* **Trigger Minute:** Minute of the hour (0-59)
* Runs every Monday by default

#### Monthly

* **Trigger Hour:** Hour of the day (0-23, UTC)
* **Trigger Minute:** Minute of the hour (0-59)
* Runs on the 1st of each month

## How It Works

### Step 1: Create the Trigger

Drag a Cron Node onto your canvas. This will be the starting point of your automated workflow.

### Step 2: Configure the Schedule

1. Set a unique identifier (e.g., "daily-cleanup" or "hourly-sync")
2. Choose your trigger interval type
3. Configure the specific timing based on your selected interval
4. Remember: all times are in UTC, not your local timezone

### Step 3: Build Your Workflow

Connect the Cron Node to other nodes to define what happens when the schedule triggers. Unlike Frontend Element nodes, cron jobs start with empty input data (`{}`).

## Important Notes

### UTC Timezone

All cron schedules run in UTC (Coordinated Universal Time), not your local timezone. Make sure to convert your desired local time to UTC:

* 9:00 AM PST = 5:00 PM UTC
* 9:00 AM EST = 2:00 PM UTC
* Use a timezone converter when setting up your schedules

### No Input Data

Unlike webhooks or frontend triggers, cron jobs don't receive any input data. To work with data in cron-triggered flows:

* Use fixed values in downstream nodes
* Query data from your collections
* Fetch data from external APIs using HTTP Request nodes

### No Return Node Needed

Cron flows are backend-only and run automatically. There's no caller waiting for a response. End your flows with:

* Mutation nodes (to save results)
* HTTP Request nodes (to call external APIs)
* Email/notification nodes

**Do NOT add Return nodes to cron flows.**

## Common Use Cases

### 1. Daily Data Cleanup

```
Cron (daily at midnight)
→ Query (fetch expired sessions)
→ Mutation (delete expired records)
```

Clean up old data every day to keep your database optimized.

### 2. Hourly External Sync

```
Cron (every hour)
→ HTTP Request (fetch latest data from API)
→ Mutation (save to database)
```

Keep your app synchronized with external data sources.

### 3. Weekly Reports

```
Cron (Monday at 9 AM UTC)
→ Query (fetch weekly metrics)
→ Agent (generate summary)
→ Mutation (save report)
```

Automatically generate and store weekly reports.

### 4. Batch Notifications

```
Cron (custom: "0 9 * * 1-5")
→ Query (fetch active users)
→ For Loop
  → HTTP Request (send reminder email)
```

Send scheduled reminders to users on weekdays.

### 5. Every 15 Minutes Check

```
Cron (*/15 * * * *)
→ Query (fetch pending tasks)
→ If-Else (check if overdue)
  → Mutation (update status)
```

Monitor and update task statuses frequently.

## Connections

Cron nodes are starting points for workflows. They have no inputs, only outputs.

**Output to:** Any node type:

* Query nodes (fetch data to process)
* Mutation nodes (perform scheduled updates)
* Agent nodes (AI-powered scheduled tasks)
* HTTP Request nodes (call external APIs)
* For Loop nodes (batch processing)
* If-Else nodes (conditional logic)

**Cannot connect to:**

* Frontend Element nodes (cron is backend-only)
* Return nodes (no caller to return to)

## Cron vs Other Triggers

| Feature         | Cron Node     | Frontend Element  | Webhook             |
| --------------- | ------------- | ----------------- | ------------------- |
| **Trigger**     | Time-based    | User action       | HTTP request        |
| **Input Data**  | None ({})     | Form/UI data      | body/params/headers |
| **Runs When**   | On schedule   | On user click     | On API call         |
| **Environment** | Deployed only | Always            | Always              |
| **Return Node** | No            | Yes               | Yes                 |
| **Use Case**    | Automation    | User interactions | External events     |

## Related Nodes

<CardGroup cols={2}>
  <Card title="Query Node" icon="search" href="/nodes/query-node">
    Fetch data to process on schedule
  </Card>

  <Card title="Mutation Node" icon="edit" href="/nodes/mutation-node">
    Save automated task results
  </Card>

  <Card title="HTTP Request Node" icon="globe" href="/nodes/http-request-node">
    Call external APIs on schedule
  </Card>

  <Card title="Agent Node" icon="robot" href="/nodes/agent-node">
    Run AI tasks automatically
  </Card>
</CardGroup>
