Guide

ICO File Format Guide

The ICO format is a container β€” not a single image. Understanding its directory structure explains why one .ico can hold sixteen different resolutions and why renaming a PNG to .ico never works.

An ICO begins with a 6-byte header (reserved, type, image count), followed by one 16-byte directory entry per embedded image (width, height, color count, reserved, planes, bit depth, size, offset).

Each entry points to either a BMP DIB (uncompressed, common for 16Γ—16 and 32Γ—32) or a PNG payload (compressed, standard for 64Γ—64 and above).

Width and height bytes of 0 mean 256 pixels β€” the format predates larger sizes but modern tools embed 256Γ—256 via PNG compression.

Windows Explorer reads the directory and picks the closest size for shortcuts, taskbar pins, and file associations.

Browsers parsing favicon.ico typically choose the entry nearest the requested display size β€” often 16 or 32 CSS pixels.

Valid ICO files can mix BMP and PNG entries in one container. Generators should PNG-compress large entries to keep total file size under 100 KB.

Transparency uses 8-bit alpha on PNG entries; BMP entries use 1-bit mask layers β€” legacy and rarely used for modern favicons.

How it works

  1. 1

    Start from a square master

    512Γ—512 PNG or SVG rasterized once.

  2. 2

    Encode multiple entries

    Bundle 16, 32, 48, 64, 128, 256 in one file.

  3. 3

    Deploy as favicon.ico

    Place at site root and link in HTML.

Try it now

Create a valid multi-size ICO

PNG to ICO Converter

FAQ

Is ICO proprietary?+

It is a Microsoft-originated format but universally supported for favicons and Windows icons.

Maximum sizes in one ICO?+

Practically up to 256Γ—256 per entry; some tools embed more entries than others.

Can SVG be inside ICO?+

No. ICO holds raster BMP or PNG only. Ship SVG as a separate favicon.svg file.

How do I inspect ICO contents?+

Use our PNG-to-ICO tool in reverse via preview, or open in a hex editor to read directory entries.

Related tools

Related tutorials

Tutorials β†’

Related guides

Guides β†’

Explore FetchFavicon

Categories

Converters

Utilities

Guides

Tutorials