How to remove a background in GIMP and export a transparent PNG

Runbo Li
Runbo Li
·
· 3 min read
A cup cutout and a checkerboard patch beside a GIMP background-removal headline in a blue, violet and warm red print collage.

To remove a background in GIMP 3, add an alpha channel so the layer can contain transparency. Use Fuzzy Select for a solid background, or Foreground Select when the subject blends into a busy scene. Keep a layered copy while you refine the edge. Export a PNG when your final image needs a transparent background.

Start with a copy and enable transparency

Open the photo and duplicate the image layer. Hide the lower layer and work on the copy. In the Layers panel, select the copy and choose Layer > Transparency > Add Alpha Channel. If the command is disabled because the layer already has an alpha channel, continue to the selection step.

Keep the layered working file as an XCF. You can restore an edge or a shadow later without starting from the original photo. See the GIMP alpha channel instructions.

For a solid background, use Fuzzy Select

Choose Fuzzy Select and click a clear part of the background. Raise the threshold in small steps if the tool leaves patches. Lower it if the selection starts to include the subject. Inspect the selected edge around hair, fingertips and transparent detail before removing pixels.

For an even background, clear the selected area on your copied layer. Check for the checkerboard and look for isolated pockets of the old background. If the subject shares the same color, undo and switch to the next method. Read the Fuzzy Select controls.

For an uneven background, use Foreground Select

Choose Foreground Select and trace a rough outline around the subject with a small margin. Confirm the outline, then paint across areas that clearly belong to the subject. Include different colors or materials on the subject so GIMP can distinguish them from the background. Preview the result and confirm the selection.

With the subject selected, add a layer mask initialized from the selection. On the mask, paint black to hide leftover background and white to restore part of the subject. Repair one edge at a time at a magnification where you can see the pixels. Read the Foreground Select workflow.

Check the edge on light and dark backgrounds

Place a temporary dark layer under the subject, then switch to a light one. Look for a bright fringe, clipped hair, soft parts that should remain translucent and gaps where the old background is still visible. If the subject needs a natural shadow, decide whether to keep it or add it in the destination layout.

Hide your temporary layers and choose File > Export As. Give the file a .png extension and export. Reopen the export in GIMP and check that the area around the subject is transparent. Keep the XCF for changes.

If you need a quick cutout in the browser

Upload the original to Magic Hour’s background remover and inspect the cutout before using it. Use the same light-and-dark-background check. For a product shot, inspect small gaps, the label, and any powder, fur or texture that reaches the edge.

Original product photograph from Magic Hour’s published background-removal example.

Magic Hour published background-removal example: product pouch, fruit and powder on a pink background

Browser cutout from the same Magic Hour example.

Magic Hour published background-removal cutout preview: product pouch, fruit and powder

See the full source and cutout in the Magic Hour product-photo workflow.

Runbo Li
Runbo Li
CEO of Magic Hour
Runbo Li is the Co-founder and CEO of Magic Hour, where he builds AI video and image tools for content creation. He is a Y Combinator W24 founder and former Data Scientist at Meta, where he worked on 0-1 consumer social products in New Product Experimentation. He writes about AI video generation, AI image creation, creative workflows, and creator tools.
View author →

Continue Reading

Edit Product Photos with AI

How to edit product photos with AI: workflow and prompts

How to edit product photos with AI: workflow and prompts
Remove Background From Product Photos

Remove backgrounds from product photos: a practical guide

Remove backgrounds from product photos: a practical guide
AI Photo Editors  for Product Photography

8 AI photo editors for product photography: a practical guide (2027)

8 AI photo editors for product photography: a practical guide (2027)
How to Remove Background From Images iPhone

How to remove an image background on iPhone

How to remove an image background on iPhone
AI Image Upscale

How to upscale an image with AI: 2x, 4x & quality checks

How to upscale an image with AI: 2x, 4x & quality checks
The Best AI Image Editors

6 best AI image editors in 2027: choose the right one

6 best AI image editors in 2027: choose the right one