Skip to main content

What is Hatchet?

Hatchet is a platform for running background tasks and durable workflows, built on top of Postgres. It bundles a durable task queue, observability, alerting, a real-time dashboard, and a CLI into a single platform. Background tasks are critical for offloading work from your main web application. Usually background tasks are sent through a FIFO queue, which helps guard against traffic spikes and ensures that tasks are retried when your task handlers error out. Most stacks begin with a library-based queue backed by Redis or RabbitMQ (like Celery or BullMQ). But as your tasks become more complex, these queues become difficult to debug, monitor, and start to fail in unexpected ways. Hatchet persists the full execution history of every task to Postgres. This gives you complete visibility into what ran, when it ran, and what it returned — without relying on external logging services or third-party UI tools. It also powers durability features like automatic retries, durable sleep, and waiting for external events.

When should I use Hatchet?

Hatchet is a durable task queue, meaning it persists the history of all executions (up to a retention period), which allows for easy monitoring and debugging and powers a range of durability features. This is not the default behavior of Celery and BullMQ.Use Hatchet when you want results persisted and observable in a UI.Use BullMQ/Celery when you need very high throughput (>10k/s) without retention, or you want to use a single library rather than a standalone service.
Hatchet is a general-purpose task orchestration platform — it can be used as a queue, a DAG-based orchestrator, a durable execution engine, or all three. It covers a wider array of use-cases including multiple queueing strategies, rate limiting, DAG features, conditional triggering, and streaming.Temporal is narrowly focused on durable execution and supports a wider range of database backends including Apache Cassandra, MySQL, PostgreSQL, and SQLite.Use Hatchet when you want more control over queue logic, run DAG-based workflows, or want to simplify self-hosting with only the Hatchet engine and Postgres.Use Temporal when you need a non-Postgres result store, or your workload is exclusively suited for durable execution.
These tools are built with data engineers in mind and are not designed to run as part of a high-volume application. They are typically higher latency and higher cost, with their primary selling point being integrations with common data stores and connectors.Use Hatchet when you want a DAG-based framework, write your own integrations and functions, and require higher throughput (>100/s).Use Airflow/Prefect/Dagster when you need out-of-the-box connectors to common data stores.

Key features

Durable task queue

Every task execution is persisted to Postgres with full history, automatic retries, and crash recovery — you never lose a task.

Workflow orchestration

Chain tasks into DAGs, fan out to parallel workers, and compose multi-step pipelines with parent-child dependencies.

Durable execution

Tasks can sleep for arbitrary durations and pause to wait for external events, resuming exactly where they left off.

Flow control

Set per-user or per-tenant concurrency limits and rate limits to protect your system from overload.

Flexible scheduling

Run tasks on cron schedules, at a specific future time, or triggered by external events.

Real-time dashboard

Monitor all tasks and workflows in a live web UI with structured logs and Slack/email alerting built in.

Next steps

Quickstart

Get a working task running in under 5 minutes across Python, TypeScript, or Go.

Core concepts

Understand tasks, workflows, workers, DAGs, durable execution, and flow control.

Build docs developers (and LLMs) love