Blog

Edit part of an image with a mask

Paint over the part you want changed, describe the change, and leave the rest of the image alone.

Sometimes the image is nearly right: one object is wrong, or a corner needs something more. A mask lets you point at exactly that area, so the edit stays where you want it.

1. Start from the image

Switch the workflow to Edit existing image and upload your image, or pick a result and press Use Selected As Base.

2. Paint the mask

Turn on Enable mask editor. Use Paint to cover the area you want changed and Erase to tidy the edges. Cover a little more than the object itself; a tight mask can leave a halo.

3. Describe only the change

Write what should be there now, not the whole scene. For example: replace the mug with a glass of iced coffee. The rest of the image is context for the model.

4. Generate, compare and keep going

Ask for a couple of variants and compare. Every attempt is saved in History, so you can try a different mask or wording and go back to whichever was best.

Tips

  • Masks you use often can be saved in your browser and reused.
  • For text inside the masked area, try Nano Banana Pro.
  • If the change bleeds outside the mask, make the prompt more specific about what stays the same.

Make your own — free with your Gemini key.

Try it free