A file says "8-bit" and another says "24-bit", and both can describe the same ordinary picture. Color depth is the number of bits stored for each pixel, and the confusion starts with what is being counted: bits per pixel, or bits per color channel. A "24-bit" image is one with 8 bits for each of three channels, red, green and blue, which allows 16,777,216 different color combinations.

This guide sorts out the two ways of counting, shows how many shades each depth allows, and measures what extra bits cost in uncompressed file size. It also explains what extra bits do not buy.

Two ways to count: per pixel and per channel

The federal digitization guide defines bit depth as the number of bits used to represent each pixel, and admits the term is confusing. It is sometimes used for bits per channel and sometimes for the total across all channels. Its example: a typical color image with 8 bits per channel is often called a 24-bit color image, because 8 bits times 3 channels is 24.

The PNG specification is strict about this. It says bit depth is the number of bits per sample or per palette index, not per pixel. A sample is one value for one channel at one pixel, and the sample depth is the number of bits that value uses. For an RGB pixel there are three samples; add transparency and there are four.

Two formulas keep the counting straight:

bits per pixel = bits per channel × number of channels

possible values per channel = 2^bits per channel

How many shades or colors each depth allows

Description Bits per pixel What is stored Possible values
Black and white 1 One bit per pixel 2
8-bit grayscale 8 One channel of 8 bits 256 shades
8-bit indexed color 8 An index into a palette of up to 256 entries Up to 256 colors
24-bit RGB 24 Three channels of 8 bits 256 × 256 × 256 = 16,777,216
32-bit RGB plus alpha 32 Three color channels and one 8-bit transparency channel 16,777,216 colors, 256 transparency levels
48-bit RGB 48 Three channels of 16 bits 65,536³ = 281,474,976,710,656

The guide gives the grayscale figures: 8 bits per channel offers 256 shades, and 16 bits offers 65,536. The PNG specification limits a palette to 1 through 256 entries, each made of three 8-bit samples. In a PNG with an alpha channel, the alpha samples are the same size as the other samples.

Some formats go beyond 8 bits per channel but not all go equally far. The JPEG standard specifies 8-bit or 12-bit precision for its DCT-based processes. PNG allows 16 bits per sample for truecolor. The AVIF specification says AV1 supports 8, 10 and 12 bits. A 10-bit-per-channel image has 30 bits per pixel, and 2^30 is 1,073,741,824 combinations. See WebP and AVIF for how the newer formats use that range.

What extra bits cost: uncompressed file size

Every added bit per pixel adds to the uncompressed size, because the formula is bytes = width × height × bits per pixel ÷ 8. The image file size calculator accepts the common depths of 1, 8, 16, 24 and 32 bits.

Worked example. Example: a 1920 × 1080 image, which has 2,073,600 pixels, at several depths.

Bits per pixel Calculation Uncompressed size
1 2,073,600 × 1 ÷ 8 259,200 bytes
8 2,073,600 × 8 ÷ 8 2,073,600 bytes
24 2,073,600 × 24 ÷ 8 6,220,800 bytes
32 2,073,600 × 32 ÷ 8 8,294,400 bytes
48 2,073,600 × 48 ÷ 8 12,441,600 bytes

Two comparisons follow. Storing a grayscale picture as 24-bit RGB takes 6,220,800 ÷ 2,073,600 = 3 times the bytes of 8-bit grayscale. Adding an 8-bit alpha channel to 24-bit RGB raises the size from 6,220,800 to 8,294,400 bytes, which is 33.3% more.

Indexed color trades range for size. An 8-bit indexed image stores one 8-bit index per pixel plus the palette, which has at most 256 entries of 3 bytes each, or 768 bytes. For 1920 × 1080 that is 2,073,600 + 768 = 2,074,368 bytes, about one third of the 24-bit figure, but with no more than 256 distinct colors.

These are sizes before compression. A saved file is usually smaller, by an amount that depends on the picture and the format, as explained in JPEG vs. PNG. The full step-by-step method is in how big is an uncompressed image.

What more bits buy, and what they do not

More bits per channel give finer steps between shades. That matters when a picture is adjusted heavily. The federal guide warns that large corrections to 8-bit-per-channel images may make shades drop out and create a posterization effect, visible as bands where a smooth gradient should be. Images with 16 bits per channel have more room for such adjustment.

The same guide is just as clear about the limit: bit depth defines the maximum number of shades or colors in a file, but it does not define or guarantee the quality of the information. A blurry picture does not become sharp at 48 bits, and a noisy capture stays noisy. The guide also states that well-done 8-bit-per-channel imaging meets most needs.

So choose a depth for a reason. Higher depth helps when you will edit tones heavily or need to store a wide range of brightness. For a finished picture shown on a page, extra bits mostly add bytes.

Common mistakes

  • Mixing up "8-bit" and "24-bit". An "8-bit" color image may mean 8 bits per channel, which is 24 bits per pixel, or 8 bits per pixel using a palette. Ask which count is meant.
  • Reading "16-bit" as 16 bits per pixel. It can instead mean 16 bits per channel, which is 48 bits per pixel for RGB and three times the size the bare number suggests.
  • Storing grayscale as RGB. Three identical channels triple the uncompressed size and add no information.
  • Adding an alpha channel that nothing uses. It costs 8 more bits per pixel, a third more raw data than plain 24-bit RGB.
  • Expecting more bits to repair a poor capture. The depth sets the number of possible values, not their quality.
  • Saving in a format that cannot hold your depth. A DCT-based JPEG stores 8 or 12 bits per sample, so a 16-bit-per-channel original must be reduced to fit.

FAQ

Is 24-bit the same as 8-bit color?

No. A 24-bit image has 8 bits for each of three channels. An 8-bit color image has a single 8-bit value per pixel, usually an index into a palette of at most 256 colors.

How many colors can a 24-bit image show?

It can represent 256 × 256 × 256 = 16,777,216 combinations of red, green and blue.

What does a 32-bit image contain?

In PNG, truecolor with alpha at 8 bits per sample has four samples per pixel: red, green, blue and alpha. Four samples of 8 bits make 32 bits per pixel.

Does higher color depth mean better quality?

Not by itself. It allows finer gradations and more editing headroom, but the federal digitization guide notes that bit depth does not define or guarantee the quality of the information in a file.

Sources

  1. W3C, Portable Network Graphics (PNG) Specification (Third Edition). Accessed November 6, 2026.
  2. Federal Agencies Digital Guidelines Initiative (FADGI), Technical Guidelines for Digitizing Cultural Heritage Materials: Third Edition. Accessed November 6, 2026.
  3. Alliance for Open Media, AV1 Image File Format (AVIF). Accessed November 6, 2026.
  4. ITU-T, Information technology - Digital compression and coding of continuous-tone still images - Requirements and guidelines (Recommendation T.81). Accessed November 6, 2026.
  5. ITU-T, Recommendation T.81 (09/92), full text as hosted by the W3C. Accessed November 6, 2026.