Eraser Tool Not Working in GIMP

Eraser Tool Not Working in GIMP

This post may contain affiliate links. Any sales made through such links will reward me a small commission at no extra cost for you.

Why in the world would the eraser tool in GIMP paint a color instead of erasing? Sometimes quirks like this seem totally inexplicable, but if you know why it’s happening it actually makes sense… sort of.

If the eraser tool is painting instead of erasing, here’s what’s going on and how you can fix it.

Skip To

Why GIMP’s Eraser is Painting Instead of Erasing
Fix Eraser Painting Instead of Erasing
The Gray Checkerboard Pattern
Saving With Transparency

Why GIMP’s Eraser is Painting Instead of Erasing

Each pixel in your image has color information stored in a color channel. A channel is just a segment of color. In RGB mode, those channels are red (R) green (G), and blue (B). Pixels can use combinations of these channels, basically mixing colors to make other colors like you did in elementary school. Combining channels in different ways basically gives you every color of the rainbow. There are other color models like CMYK, but they work similarly. A set of basic colors can be mixed together to make other colors.

So you have a huge amount of colors to work with, but transparent pixels aren’t possible yet. Without transparency, the only way to “erase” using just R, G, and B channels is to replace the image pixels with a solid color. The color used to replace pixels is kind of arbitrary, so GIMP will use the “background color” to replace your image pixels as a default. That’s why GIMP’s eraser sometimes paints with black, white, or another color depending on the background color you set in the Toolbox.

The first layer in any JPG image you open in GIMP does not support transparency, because JPG’s themselves do not support transparency. That means any time you open a JPG in GIMP and try to erase, you’ll see this eraser not erasing problem. PNG files do support transparency, so if you open a PNG in GIMP the eraser tool will work as expected right away.

If you want that first JPG layer to support transparency you’ll need to add a “alpha channel”. In GIMP, alpha just means transparency. So in addition to R, G, and B, the alpha channel gives your pixels information about transparency to work with. The ability to make transparent pixels is what allows the eraser to really erase.

How to Fix GIMP Eraser Painting Instead of Erasing

add an alpha channel when the eraser tool isn't working in GIMP

Here’s how you add an alpha channel to a layer in GIMP:

  • Find the Layers Dialog. If you don’t see it, go to Window > Dockable Dialogs > Layers. If the Layers Dialog was already open it will blink. If it wasn’t open, it will open in a small window.
  • Now, in the Layers Dialog, look for the correct layer thumbnail. It will look like a mini version of the image you have open, or the layer you want to work on.
  • Right-click (or alternate click using your preferred method if you’re on a Mac) on that layer thumbnail. A menu of options will appear.
  • Choose “Add Alpha Channel” from the list of options.
  • The Alpha Channel will be added to your image, and the eraser should work as expected now.

Erasing with Transparency – The Gray Checkerboard Pattern

gray checkerboard pattern with eraser tool in GIMP

Now that your eraser is erasing and your pixels support transparency, you’ll be able to see through your erased parts of a layer to the layer below. It’s like you have a stack of papers, and erasing rubs holes in a sheet of paper so you can see what’s beneath it.

Makes sense… but when you only have one layer, you’ll see a weird gray checkerboard pattern everywhere you erase. It’s not exactly attractive, and it can be kind of alarming when you first see it. I mean, I know I really don’t want that pattern showing up in my image.

Thankfully that pattern isn’t actually part of your image. It’s there because you can’t see transparent pixels, so when there’s nothing underneath a layer GIMP has to show you something to indicate that there’s basically a hole in your layer. It could show you a solid color like white, but then you wouldn’t be able to tell the difference between holes and where you actually painted with white. So it uses this really obvious checkerboard pattern to make it clear where transparent pixels are.

This is a standard way of representing transparency, and you’ll see it in other image manipulation programs like Photoshop. You’ll even see this pattern used to represent transparency in menus and tools. You can see a little gray checkerboard icon next to the “add alpha channel” option in the layers dialog.

This pattern is not saved in your image. If you save using a file type that supports transparency (like PNG), your transparent pixels will actually be transparent and they’ll allow anything that’s beneath that image to show through.

Saving Images With Transparency

Final note about transparency in GIMP:

Adding an alpha channel won’t change the fact that JPG’s don’t support transparency. If you save your new GIMP image as a JPG, those transparent pixels will be replaced with your background color again. If you want to keep the transparency, you’ll need to save your image as a PNG.

I hope that clears up some of the unexpected transparency related quirks you’ll find in GIMP and other photo editing programs. The big takeaway is, if your GIMP eraser isn’t erasing and it looks like it’s painting a color instead, you probably just need to add an alpha channel to that layer.

2 Replies to “Eraser Tool Not Working in GIMP”

  1. While I am not new to GIMP (using it for 7 years), I do not come close to using all its capabilities. I just use it to peak-up my pics I take with my point-and-shoot. I plan to get more involved, but I cannot understand the manual. Anyhow, I started to work on some vacation pictures and found that will not do anything. I go through the process and hit OK and nothing happens except that when I try to clear the image, it asks if I want to save or discard changes. I have closed and opened the program, checked help and cannot understand it, and deleted and re-downloaded the program. Can anybody help with some plain language?

    1. Hi! What are you doing to your photos exactly? Can you walk me through the process? If you write out some steps to reproduce the problem I could take a look and try to figure out what’s going on.

Leave a Reply to Kat Landreth Cancel reply

Your email address will not be published. Required fields are marked *