Formats guide

PNG bit depth explained: 8-bit vs 24-bit vs 32-bit

Updated 6 min read OptimizePNG team

"PNG-8", "PNG-24" and "PNG-32" are everywhere in export dialogs, yet rarely explained.

The short version: the number tells you how many bits each pixel uses to store its color.

More bits means more possible colors and transparency - and bigger files.

What bit depth means

A computer stores each pixel's color as a number. Bit depth is how many binary digits that number gets.

1 bit gives 2 values, 8 bits give 256, and 24 bits give 16,777,216. That is why a 24-bit image is called "true color".

Technically the PNG specification counts bits per channel (8 or 16), not per pixel. "PNG-24" and "PNG-32" are the popular per-pixel names: 3 or 4 channels x 8 bits.

The 5 PNG color types

Every PNG declares one of five color types in its header. Together with the bit depth, that decides how pixels are stored.

Color typeChannelsBits per channelBits per pixelCommon name
Indexed (palette)1 index1, 2, 4, 8up to 8PNG-8
Grayscale11, 2, 4, 8, 16up to 16Grayscale PNG
Grayscale + alpha28, 1616 or 32-
Truecolor (RGB)38, 1624 or 48PNG-24
Truecolor + alpha (RGBA)48, 1632 or 64PNG-32

For a 1000 x 1000 image, the raw pixel data is about 1 MB at 8-bit, 3 MB at 24-bit and 4 MB at 32-bit. Compression shrinks all three, but the starting point matters.

PNG-8: 8-bit indexed color

An 8-bit PNG stores a palette of up to 256 colors, and each pixel just points to one of them. That makes it the most compact PNG type by far.

It is ideal for logos, icons, flat illustrations, charts, diagrams and pixel art. With a smart palette, most of these images look identical to the original.

Transparency works too. The format can attach an alpha value to every palette entry, so anti-aliased edges and soft shadows survive the conversion.

Turn any PNG into an optimized 8-bit indexed PNG.

Open PNG to 8-Bit

PNG-24 vs PNG-32

PNG-24 stores red, green and blue at 8 bits each, enough for 16.7 million colors. It is the right pick for detailed graphics with no transparency.

PNG-32 adds an 8-bit alpha channel with 256 levels of opacity per pixel. Use it for cut-out product shots, overlays and anything placed on varying backgrounds.

If a 32-bit PNG has no transparent pixels, the alpha channel is dead weight. Flattening it with a background color - for example with Add Background to PNG - saves space.

16 bits per channel (48-bit and 64-bit PNG)

PNG can also store 16 bits per channel, giving 48-bit RGB or 64-bit RGBA files. That is 65,536 levels per channel instead of 256.

It matters for photo editing, scientific imaging and print masters where heavy adjustments would otherwise cause banding. For the web it is overkill - screens show 8 bits per channel, and the files are twice as big.

How to check the bit depth of a PNG

The quickest way is to drop the file into our PNG Metadata Viewer. It reads the header chunk and shows the color type and bit depth, along with every other chunk in the file.

On Windows you can also right-click the file, choose Properties, then Details, and look for "Bit depth". It reports 8, 24 or 32.

Which bit depth should you use?

ImageBest choiceWhy
Logo, icon, UI elementPNG-8Few colors, smallest file, transparency kept
Pixel art, spritesPNG-8Exact colors, tiny files
Chart, diagram, screenshot of textPNG-8 or optimized PNG-24Sharp edges, limited palette
Detailed illustration, no transparencyPNG-24Smooth gradients without banding
Cut-out photo or overlayPNG-32 (or WebP)Needs smooth alpha
Photo editing master48 / 64-bitHeadroom for heavy edits
Photo for the webNot PNG - use WebP or JPG5-10x smaller

Not sure? Try the 8-bit conversion first and compare. If you cannot tell the difference, keep the smaller file - and if you still need it smaller, see how to reduce PNG file size.

Frequently Asked Questions

Both store 8 bits each for red, green and blue - about 16.7 million colors. A 32-bit PNG adds an 8-bit alpha channel, so every pixel can be anywhere from fully transparent to fully opaque. If an image has no transparency, 24-bit is all it needs.

Yes. An 8-bit indexed PNG can store a transparency value for each palette color, including partial transparency. The old idea that PNG-8 only supports on/off transparency comes from early export tools, not from the format.

Only if the image needs more than 256 colors. Logos, icons, charts and pixel art usually look identical as 8-bit and are much smaller. Photos and smooth gradients can show banding, so keep those at 24 or 32-bit or use WebP or JPG.

Upload it to the PNG to 8-Bit converter. It builds the best 256-color (or smaller) palette for your image, keeps transparency and lets you download the indexed PNG.