Overview
Trigger.dev exists because agent workloads do not fit serverless timeouts. It is an open-source TypeScript platform for background tasks that run as long as they need to — no timeout at all, unlike AWS Lambda or Vercel — with durability, automatic retries, queues and idempotency built into the primitive rather than bolted on afterwards. You keep writing normal code with whatever LLMs, frameworks and services you already use; the platform supplies the execution guarantees around it.
Tasks live in your codebase, not in a web UI: you export a task from a file, version-control it, run it on localhost, and review it like any other code. Around that sit the pieces long-running agents actually need. Waits and waitpoints pause a run for a duration or until a human approves, rejects or gives feedback. Realtime lets a frontend subscribe to a run and stream LLM output back to the user. Build extensions hook into the build so a deployed task can use system packages — a browser, Python, FFmpeg. Checkpointing makes runs resumable, atomic versioning deploys new code without disturbing runs already in flight, and machines let you set vCPU and RAM per task.
Operationally it gives every run full tracing and logs, tags (up to ten per run) for filtering from the dashboard, SDK or realtime API, run metadata that updates as the run progresses, bulk actions for replaying or cancelling many runs at once, and configurable alerts on failures and deployments. Environments cover DEV, PREVIEW, STAGING and PROD, with preview branches that integrate with Vercel and git workflows.
The code is Apache-2.0 and the SDK ships on npm as @trigger.dev/sdk. You can deploy to the managed cloud and have no infrastructure to run, or self-host the whole platform.
What it does
- No timeouts — tasks run as long as they need, with checkpoint/resume making them durable across restarts
- Automatic retries, queues, concurrency controls and idempotency as first-class task behaviour
- Waits and waitpoints, including human-in-the-loop approval, rejection or feedback mid-run
- Realtime: subscribe to runs from your frontend and stream LLM responses to users, with React hooks provided
- Build extensions that add system packages to a deployed task — browsers, Python scripts, FFmpeg and more
- Full tracing, logging, tags, run metadata, bulk replay/cancel and failure alerts for every run
- DEV / PREVIEW / STAGING / PROD environments plus preview branches wired into Vercel and git workflows
- Managed cloud with no infrastructure to run, or full self-hosting
Getting started
Tasks are ordinary TypeScript modules in your own repository. The pattern below is the README's minimal example.
Install the SDK
npm install @trigger.dev/sdkExport a task
Every task is exported and carries a unique id; the run function is the body, and it can run for as long as it needs.
import { task } from "@trigger.dev/sdk";
//1. You need to export each task
export const helloWorld = task({
//2. Use a unique id for each task
id: "hello-world",
//3. The run function is the main function of the task
run: async (payload: { message: string }) => {
//4. You can write code that runs for a long time here, there are no timeouts
console.log(payload.message);
},
});Deploy, or self-host
Deploy to the managed cloud and tasks scale automatically with no infrastructure to manage; the self-hosting guide covers running the platform yourself.
# managed cloud: https://trigger.dev/docs
# self-hosting: https://trigger.dev/docs/self-hosting/overviewCommands and code are distilled from the project's own documentation — always check the official repo for the latest.
When to use it
- Agent loops that run for minutes or hours, where a serverless timeout would kill the job halfway
- Workflows that must pause for a human to approve or correct a step before continuing
- Streaming LLM output from a background run straight into a web frontend
- Media, browser or Python workloads that need real system packages in the execution environment
- Scheduled and recurring jobs with durable cron schedules of up to a year
How Trigger.dev compares
Trigger.dev alongside other open-source workflow automation tools AI/TLDR tracks, ranked by GitHub stars.
| Tool | Stars | What it does |
|---|---|---|
| n8n | ★ 205k | A self-hostable workflow automation tool with a visual node editor that connects 400+ apps and APIs and adds native AI steps, letting technical teams build automations without writing most of the glue code. |
| Huginn | ★ 50k | A self-hosted system of "agents" that watch websites, feeds, and events and take automated actions on your behalf, similar to a private IFTTT. |
| GitHub MCP Server | ★ 33k | GitHub's official MCP server, hosted or self-run, that gives an agent scoped toolsets for repositories, issues, pull requests, Actions runs and code-security alerts. |
| gws (Google Workspace CLI) | ★ 31k | A command-line tool for every Google Workspace API, built at runtime from Google’s Discovery Service, returning structured JSON and shipping 40+ agent skills. Not an officially supported Google product. |
| Kestra | ★ 28.1k | An event-driven orchestration platform that defines data, AI, and infrastructure pipelines as declarative YAML and runs them through a web UI. |
| Activepieces | ★ 24.5k | An open-source Zapier alternative where you build automations from reusable TypeScript "pieces", with support for AI agents and self-hosting. |
| n8n-MCP | ★ 22.9k | An MCP server that gives coding assistants structured access to n8n's node catalogue, schemas, docs and workflow templates so they can build and validate n8n workflows. |
| Trigger.dev | ★ 16.3k | Write long-running AI agents and background tasks as TypeScript in your own repo, and get durability, retries, queues and tracing without managing infrastructure |