Image glossary

Alpha channel

Also known as alpha, transparency channel

An alpha channel is a per-pixel transparency map stored alongside the colour channels, recording how much of each pixel is opaque.

What it stores

A colour image stores three values per pixel — red, green, blue. An image with an alpha channel stores a fourth: opacity, usually as another 8-bit value giving 256 levels from fully transparent to fully opaque.

The interesting part is the middle. Binary transparency, where a pixel is either visible or not, is easy and looks terrible: every edge is jagged. Real alpha is graduated, and that is what lets a cut-out sit believably on a new background.

Why edges are the whole difficulty

A pixel at the boundary of a subject is not entirely subject or entirely background. A pixel on a strand of hair might be 40% hair and 60% wall. Its stored colour is a blend of the two, and its alpha value should say how much of it is hair.

Get that band wrong in one direction and you keep a halo of the old background; wrong in the other and the hair looks chewed. Every background-removal method is ultimately judged on how well it handles this band, which is why hair, glass and lace are the standard hard cases.

A useful check: composite a cut-out onto a strongly contrasting colour — bright magenta is traditional — and any surviving halo becomes obvious immediately.

Which formats carry one

PNG, WebP and AVIF all support full 8-bit alpha. GIF supports only a single fully transparent colour, which is why GIF edges look ragged. JPEG has no alpha channel at all.

That last one causes the most common data loss in image work: saving a cut-out as JPEG silently flattens it onto white, and the transparency is gone permanently. If the file must be JPEG, composite it deliberately onto the background you actually want first, rather than letting the encoder choose white for you.

Keeping alpha through a pipeline means every intermediate save must be a format that supports it. A single JPEG round trip anywhere in the chain destroys it, and it is easy to do by accident when a tool defaults to JPEG output.

Tools that work with this

Back to the full glossary.