← All guides

Anysphere · Editor

How to Generate Images in Cursor with MCP

Connect PixelMCP to Cursor and your agent can generate images while it builds: hero images, icons, illustrations, blog headers and OG cards. It can save the files straight into your project using Nano Banana, GPT Image, FLUX, Seedream or Recraft.

Give Cursor's agent the ability to generate images for your app.

Before you start: Cursor desktop app. You'll also need a PixelMCP account. Get 100 free credits
  1. 1

    Add to mcp.json

    Open the Customize page (MCP section), or edit ~/.cursor/mcp.json (global) or .cursor/mcp.json (per project):

    {
      "mcpServers": {
        "pixelmcp": {
          "url": "https://pixelmcp.com/mcp"
        }
      }
    }
  2. 2

    Sign in

    Cursor opens your browser to sign in to PixelMCP the first time it connects. If prompted, click Connect next to pixelmcp.

  3. 3

    Use it

    In Agent mode, ask for an image. Cursor will call PixelMCP's tools.

Things to try

  • “Generate product photos for the three items in data/products.json and save them to public/products/.”

Image models you can use in Cursor

Not sure which to pick? Compare the models.

FAQ

What do I need to use PixelMCP in Cursor?+

Cursor desktop app. You also need a PixelMCP account, which starts with 100 free credits.

Which image models can I use in Cursor?+

Nano Banana 2 and Pro, GPT Image 2 and GPT Image 2 HD, FLUX.2 Pro and Klein, Seedream 5.0 Pro and Recraft V4.1. Name a model in your prompt or let the assistant choose.

How much does it cost?+

You pay per image with credits, from 6 credits (6¢) an image. There's no subscription and credits never expire. New accounts get 100 free credits.

How long does setup take?+

About a minute. Add the PixelMCP server URL to Cursor, sign in once, and you're ready to generate.

Menus change often. If a label here doesn't match what you see, look for “Connectors”, “MCP” or “Integrations” in Cursor's settings, or check Anysphere's docs.