QStash requires a publicly available API to send messages to. During development when applications are not yet deployed, developers typically need to expose their local API by creating a public tunnel. While local tunneling works seamlessly, it requires code changes between development and production environments and increases friction for developers. To simplify the development process, Upstash provides QStash CLI, which allows you to run a development server locally for testing and development.Documentation Index
Fetch the complete documentation index at: https://upstash-dx-2595-qstash-auto-dev-server.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
The development server fully supports all QStash features including Schedules, URL Groups, Workflows, and Event Logs.
Since the development server operates entirely in-memory, all data is reset when the server restarts.
Automatic dev server (JavaScript SDK)
If you are using@upstash/qstash, you can just set QSTASH_DEV=true in your environment variables, and the SDK will download and connect to the dev server automatically.
.env
devMode: true to explicitly enable dev mode:
- Download the latest
qstashbinary on first use, cached in your OS cache directory:- macOS:
~/Library/Caches/upstash/qstash-dev - Linux:
~/.cache/upstash/qstash-dev - Windows:
%LOCALAPPDATA%\upstash\qstash-dev
- macOS:
- Spawn the server on port
8080(override withQSTASH_DEV_PORT). - Confirm the server is running on the configured port and skip spawning if it is.
- Override the
baseUrl,token, and signing keys you provide and use the dev server’s instead.
Next.js edge routes
If you are using edge routes in Next.js, the SDK cannot spawn the dev server from the edge runtime — it can only verify it is reachable. To start the server before any edge request hits, callregisterQStashDev() from instrumentation.ts:
Running the dev server manually
If you would rather run the dev server manually (Python, Go, plain HTTP, etc.), use the QStash CLI directly.@upstash/qstash-cli
Install the binary via the@upstash/qstash-cli NPM package:

Docker
QStash CLI is available as a Docker image through our public AWS ECR repository:Direct download
You can download the binary directly from our artifact repository without using a package manager: https://artifacts.upstash.com/#qstash/versions/ Select the appropriate version, architecture, and operating system for your platform. After extracting the archive file, run the executable:CLI reference
Currently, the only available command for QStash CLI isdev, which starts a development server instance.
Server Components
Runningqstash dev starts two components:
- QStash server — the main API server, defaults to port
8080. Use-portorQSTASH_DEV_PORTto change it. - Log server — serves logs and is used by the Upstash Console and Logs API. Defaults to
port + 1(i.e.,8081when using the default port). Use-log-portorQSTASH_DEV_LOG_PORTto change it.
Test users
There are predefined test users available. You can configure the quota type of users using the-quota option, with available options being payg and pro.
These quotas don’t affect performance but allow you to simulate different server limits based on the subscription tier.
After starting the development server using any of the methods above, it will display the necessary environment variables.
Select and copy the credentials from one of the following test users:
Currently, there is no GUI client available for the development server. You can use QStash SDKs to fetch resources like event logs.