Fix Midjourney API Error 429 Rate Limit Exceeded
Updated 9/24/2026
Midjourney does not currently offer a public, official REST API. Developers who programmatically generate images must rely on Discord's API, self-hosted automation, or third-party API gateways. When your integration triggers an HTTP Error 429: Too Many Requests, it means your code is sending requests faster than either Discord's gateway or your integration gateway allows.
This guide explains how to identify the exact cause of your Midjourney 429 errors and implement architectural fixes to keep your generation pipeline running smoothly.
Why you are seeing Error 429
Midjourney imposes strict concurrent job limits based on your subscription tier: * Basic and Standard plans: Max 3 concurrent Fast jobs. * Pro plan: Max 12 concurrent Fast jobs. * Mega plan: Max 15 concurrent Fast jobs.
If your integration attempts to trigger more concurrent /imagine commands than your plan allows, or if your script spams the Discord gateway with more than 5 requests per second, the server will block your connection with a 429 status code.
Follow these steps to resolve the rate limit and stabilize your app.
Step 1: Check your subscription tier and concurrent limits
Ensure your application's concurrency logic matches your active Midjourney plan.
- Open Discord and go to any channel where the Midjourney bot is present.
- Type /info and press Enter.
- Note your active subscription level and check your current queue usage.
- If your app is designed to process 10 concurrent requests but you are on a Standard plan (which limits you to 3 concurrent jobs), you must throttle your application's output to match the 3-job limit.
Step 2: Implement exponential backoff in your code
Do not immediately retry failed requests. Rapid retries during a 429 error will extend your rate-limit penalty.
Implement an exponential backoff algorithm with jitter (randomized delay). When your script receives a 429 error code: 1. Pause execution for a baseline duration (e.g., 2 seconds). 2. If the next attempt also fails, double the wait time (4 seconds, then 8 seconds, etc.). 3. Add a small random variance (jitter) to prevent multiple queued requests from hitting the server at the exact same millisecond.
Example logic structure: ` wait_time = base_delay * (2 ^ attempt) + random_jitter `
Step 3: Implement a message broker queue
Directly sending user requests to Midjourney as they arrive will inevitably cause rate limits during peak usage. You must decouple your front-end requests from your generation execution using a queue system.
- Install a message broker like Redis, RabbitMQ, or BullMQ.
- When a user requests an image, write the payload to your queue rather than executing the Discord interaction immediately.
- Configure a worker process to pull items from the queue at a controlled rate (e.g., maximum 1 task every 3 to 5 seconds per account).
- Monitor the queue size and process execution times to keep generation latency predictable.
Step 4: Monitor Discord gateway rate limits
If you are interacting with Midjourney via Discord bot commands, your code must respect Discord's rate limits, which are separate from Midjourney's generation limits.
- Check the response headers of your failed API calls. Look for X-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset.
- Parse the Retry-After header. This value tells your script exactly how many seconds it must wait before sending another request.
- Ensure your automation does not exceed 5 requests per second per channel, as this is Discord's standard rate-limiting threshold.
When to escalate
- If you are using a third-party Midjourney API wrapper: Check their dedicated status page. A 429 error often means the wrapper service has run out of active Midjourney accounts in their pool or their master accounts have been rate-limited by Discord.
- If you are using self-hosted bots: Check the [Discord Status Page](https://discordstatus.com/). Global Discord API degradations can cause erratic 429 responses that are out of your control.