Midjourney Text to image API

midjourney / Midjourney

Create images from text with Midjourney 8.2, 8.1, 7, or Niji 7. Start with a scene, choose your framing, and tune the visual direction.

Fast generation typically returns four images per task. Page artwork is illustrative; run a prompt to see your model results.

Model Type:Text to image
Pricing

Image generation

One generation typically returns four images. The amount is per task, independent of the number of returned images.

All four versions · per generation
$0.08
Input

Prompt, assets, and output parameters form one generation request.

Describe the subject, composition, lighting, and visual style.
Describe elements to exclude from the images.
VersionChoose a Midjourney version, or Niji 7 for anime and illustration.
Aspect ratioChoose the shape of the generated images.
Numeric controls
0–1,000

Higher values give the model more artistic freedom.

0–100

Higher values increase variation between the generated images.

0–3,000

Explore unusual, experimental shapes and visual ideas. Weird is not fully compatible with seeds, so a fixed seed may not reproduce the same result.

0–4,294,967,295

Leave empty for a random seed, or set a whole number to compare generations.

Switches

Model overview

Midjourney for visual exploration from text

Develop scenes, illustration, and design directions from a written brief. Choose a Midjourney version in the Playground and use the same parameters through the API. The artwork on this page illustrates creative directions rather than verified model outputs.

Midjourney generation example
01 · Image generation

Compose complete scenes

Describe a subject, environment, camera angle, materials, and lighting. Use the aspect ratio to frame a wide landscape, portrait, or square composition.

  • Supports Text to image and reference-asset generation workflows.
  • Fits product assets, ad previews, visual direction, and social content tests.
  • Adjust configured inputs, media, and switches before generation.
Reference asset control example
02 · Asset control

Explore illustration with Niji 7

Select Niji 7 for anime and illustrative directions. Specify character details, linework, palette, atmosphere, and background elements in your prompt.

Prompt-led generation
Unified model API and result management example
03 · API integration

Direct style and pattern

Adjust Stylize for artistic interpretation, Chaos for variation, and Weird for unconventional ideas. Turn on Tile to request artwork that repeats across its edges.

  • Compare available models from Alibaba, Black Forest Labs, Google, MiniMax, Midjourney, OpenAI, ByteDance, Kuaishou, SJolt AI, Suno, xAI in one place.
  • Copy the request body directly to the server to reduce frontend/backend parameter drift.
  • Failure states, retries, result preview, and review checkpoints stay in the same workflow.

Model characteristics

One text-to-image workflow, four model versions.

01

Version selection

Choose 8.2, 8.1, 7, niji7. New requests default to 8.2.

02

Creative controls

Use Raw for more direct prompt control and a negative prompt to describe unwanted elements. A seed helps compare experiments without guaranteeing identical results.

03

Multiple results

A task typically produces four images. Browse the returned images and download the selected result.

04

Asynchronous API

Submit a prompt to receive a task_id, then poll the task endpoint or receive a webhook when it finishes.

FAQ

These are the first questions to answer when evaluating this model.

Which versions can I select?

The version options are 8.2, 8.1, 7, niji7. The default is 8.2; niji7 selects Niji 7.

How should I write my prompt?

Start with the subject and action, then describe the setting, lighting, composition, color, and medium. Change one control at a time when comparing results.

Which aspect ratios can I use?

Choose 1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3, 21:9. The default is 1:1.

What do Weird and Tile do?

Weird accepts 0–3000 and encourages unusual visual ideas. A fixed seed may not reproduce results when using Weird. Tile requests a repeatable pattern unit in versions 8.2, 8.1, 7. Niji 7 does not support Tile. Both are off by default.

How do I access all generated images?

Use the image selector in the result preview or read the complete data.output_urls array from the task API. Generations typically return four images.