Queuebase
← Back to blog

The Best Background Job Libraries for Next.js in 2026

By Brock Herion

Next.js is great for building full-stack apps, but it runs on serverless infrastructure — which means you can’t run long-running tasks inside a request. Sending emails, processing uploads, syncing with APIs, running scheduled reports — these all need to happen outside the request cycle.

There are a lot of options, and they’re all different. Some need Redis, some need Kubernetes, some are free, some start at $100/month. Here’s a practical breakdown of the major options in 2026.

What to Look For

Before evaluating specific tools, here are the things that actually matter:

  • Does it work on Vercel? If you’re deploying to Vercel (or any serverless platform), your background job solution can’t rely on persistent processes.
  • How much infrastructure do you manage? Redis? Kubernetes? A separate worker process? Or nothing?
  • Type safety. If you’re writing TypeScript, you want your job payloads typed end-to-end.
  • Scheduling. Do you need cron jobs? How are they configured and managed?
  • Pricing at your scale. Free tier for getting started, predictable costs as you grow.

The Options

Queuebase

Queuebase is a job queue built specifically for Next.js. It uses a callback model — you define job handlers in your app, and Queuebase calls back to your endpoint to execute them. Jobs run on your own infrastructure.

import { createJobRouter, job } from "@queuebase/nextjs";
import { z } from "zod";

export const jobs = createJobRouter({
  sendEmail: job({
    input: z.object({
      to: z.string().email(),
      subject: z.string(),
    }),
    handler: async ({ input }) => {
      await sendEmail(input.to, input.subject);
      return { sent: true };
    },
    defaults: { retries: 3, backoff: "exponential" },
  }),
});

Best for: Next.js developers who want the simplest possible setup for background jobs. Define jobs, enqueue with a typed client, done.

Strengths:

  • tRPC-style router with Zod validation — full type safety from definition to enqueue
  • No Redis, no separate workers, no additional infrastructure
  • CRON scheduling with plain English expressions (“every weekday at 9am”)
  • Built-in monitoring dashboard
  • Works on Vercel, Railway, any Node.js hosting
  • Free tier: 10,000 jobs/month

Tradeoffs:

  • Next.js-focused (Node.js package available, more frameworks coming)
  • No multi-step workflows or durable execution
  • Newer project — actively developed but earlier stage than BullMQ or Temporal

Compare Queuebase to other options →


BullMQ

BullMQ is the most mature job queue in the Node.js ecosystem. It’s been around for years, is battle-tested at scale, and offers the deepest feature set of any Node.js queue library.

Best for: Teams running persistent servers (not Vercel) who already have Redis and need advanced queue features.

Strengths:

  • Extremely mature and well-tested
  • Priority queues, rate limiting, parent-child job flows
  • Handles 50k+ jobs/second with horizontal scaling
  • Free and open source (MIT)

Tradeoffs:

  • Requires Redis — must provision, secure, and pay for a Redis instance
  • Requires persistent workers — does not work on Vercel or serverless platforms
  • No built-in type safetyjob.data is any by default
  • Separate deployment for workers
  • Minimum infrastructure cost: Redis + worker hosting (~$20-50+/month)

Queuebase vs BullMQ →


Inngest

Inngest is an event-driven workflow platform. Functions are triggered by named events and can include multi-step execution with persisted state between steps.

Best for: Teams that need event-driven architectures and multi-step workflows with built-in state management.

Strengths:

  • Step functions with durable execution between steps
  • Event-driven model with fan-out (one event triggers multiple functions)
  • Sleep and wait primitives (pause for days, wait for external events)
  • Broad framework support (Next.js, SvelteKit, Nuxt, Express, etc.)
  • Strong local dev experience with event browser

Tradeoffs:

  • Event-driven model is more complex than direct enqueue for simple jobs
  • Pricing based on function runs + steps — can add up with multi-step workflows
  • Your job code runs on their infrastructure (for cloud version)
  • More concepts to learn (events, functions, steps, middleware)

Queuebase vs Inngest →


Trigger.dev

Trigger.dev (v3/v4) is a managed runtime for background tasks. When you deploy, it bundles your code into Docker images and runs them on their MicroVMs.

Best for: Teams that need long-running tasks with no timeout limits and don’t want to manage their own execution infrastructure.

Strengths:

  • No timeouts — tasks can run for minutes or hours
  • Checkpoint-resume (pause execution, snapshot state, resume later)
  • Managed infrastructure — they handle scaling, containers, and execution
  • Good developer experience with SDK and CLI

Tradeoffs:

  • Your code runs on their infrastructure — environment variables and secrets must be shared
  • Separate deploy step required (npx trigger.dev deploy)
  • Compute-based pricing (vCPU/second) — costs scale with execution time
  • Cold starts when spinning up containers

Queuebase vs Trigger.dev →


QStash (Upstash)

QStash is an HTTP-based messaging service from Upstash. It’s not a job queue per se — it’s a way to reliably deliver HTTP requests with retries, delays, and scheduling.

Best for: Teams already using the Upstash ecosystem (Redis, Kafka) who need simple HTTP-based message delivery.

Strengths:

  • Serverless-native — works anywhere that handles HTTP
  • Part of the Upstash ecosystem
  • FIFO queues, dead letter queues, deduplication
  • Generous free tier (500 messages/day)
  • Framework-agnostic — works with anything that has an HTTP endpoint

Tradeoffs:

  • Not a job queue framework — no job routers, no typed clients, no structured handlers
  • No input validation — you’re sending raw HTTP payloads
  • No built-in dashboard for job monitoring
  • Local dev requires a public URL for the core QStash service

Queuebase vs QStash →


Vercel Cron

Vercel Cron Jobs let you trigger serverless functions on a schedule using vercel.json configuration.

Best for: Simple scheduled tasks on Vercel where you just need “run this function every hour.”

Strengths:

  • Zero setup if you’re already on Vercel
  • No additional service or dependency
  • Free on all Vercel plans (with limits)
  • Simple vercel.json configuration

Tradeoffs:

  • Scheduling only — no delayed jobs, no one-off background processing, no retries
  • Subject to Vercel function timeouts (10s on Hobby, 60s on Pro)
  • No job queue, no monitoring, no status tracking
  • Limited cron expressions (minimum 1 minute interval on Pro)
  • No type safety or input validation

Queuebase vs Vercel Cron →


Temporal

Temporal is an enterprise durable execution platform for building reliable distributed applications. It was created by the original authors of Uber’s Cadence.

Best for: Enterprise teams with complex multi-step workflows, long-running processes, and dedicated platform engineering capacity.

Strengths:

  • Durable execution — workflows survive crashes and resume exactly where they left off
  • Multi-step workflows with signals, queries, child workflows
  • Workflows can run for months or years
  • Polyglot SDKs (Go, Java, TypeScript, Python, PHP, .NET)
  • Battle-tested at enterprise scale

Tradeoffs:

  • Significant operational overhead — self-hosting requires Kubernetes, a database (Postgres/Cassandra), and Elasticsearch
  • Steep learning curve — determinism constraints, replay semantics, workflow vs. activity separation
  • Cloud starts at $100/month — no free tier
  • Overkill for simple background jobs
  • Weeks of ramp-up time for a team

Queuebase vs Temporal →


Quirrel

Quirrel was a job queue designed specifically for serverless apps, using the same HTTP callback pattern as Queuebase. It was created by Simon Knott and acquired by Netlify in 2022.

Best for: Existing projects that already have Quirrel self-hosted and working.

Strengths:

  • Pioneered the callback model for serverless background jobs
  • Support for cron, delayed jobs, and idempotent enqueue
  • Open source

Tradeoffs:

  • Hosted service shut down in July 2022
  • No active development — maintenance mode only
  • Self-hosting requires Docker + Redis
  • No production monitoring dashboard
  • Documentation references the defunct hosted service

Queuebase vs Quirrel →


Summary

Works on VercelType SafetyCRONStarting Price
QueuebaseYesBuilt-in (Zod)YesFree
BullMQNoManualYesRedis + hosting
InngestYesOptionalYesFree
Trigger.devYesTypeScriptYesFree
QStashYesNoYesFree
Vercel CronYesNoYes (only)Free
TemporalNoTypeScriptYes$100/mo
QuirrelYesBasicYesShut down

How to Choose

You just need background jobs in Next.js → Queuebase. Simplest setup, type-safe, works on Vercel, free tier to start.

You need multi-step workflows with durable execution → Inngest or Trigger.dev, depending on whether you want event-driven (Inngest) or managed runtime (Trigger.dev).

You need enterprise workflow orchestration → Temporal. But make sure you actually need it — the operational investment is significant.

You’re already running Redis on persistent servers → BullMQ is the mature, feature-complete choice.

You just need simple scheduled tasks on Vercel → Vercel Cron is free and built-in. No reason to add another tool.

You need HTTP message delivery in the Upstash ecosystem → QStash is the natural fit.