PNG to XBM Converter

Convert a PNG to a black-and-white XBM bitmap in your browser.

or drop files here

PN

PNG Format

Portable Network Graphics

A losslessly compressed raster image supporting different color modes and optional alpha.

  • Pixel-based representation
  • Does not retain embroidery instructions
XB

XBM Format

X BitMap

A monochrome bitmap stored using C-style text.

  • Historical interface and cursor use
  • May require a companion mask

How to convert PNG to XBM

Follow these steps to convert PNG to XBM online.

    1

    Choose your PNG file, or several at once.

    2

    Wait while the converter turns each file into XBM.

    3

    Download each new XBM file. Your original file isn't changed.

Before converting PNG to XBM

  • XBM is black and white only, so color becomes monochrome.
  • XBM has no alpha channel; GIMP can write a separate mask file.
  • Metadata is dropped and extra bit depth is lost.
  • The page has no options for hot spot or X10 format.

PNG to XBM: background and alternatives

What is a PNG file?

Developers designed PNG to replace GIF without the patent worries. It reached W3C Recommendation status in October 1996, the first format to do so, and ISO/IEC 15948 came later. Pixels are always stored losslessly. Color can come from a palette, gray levels or full truecolor, and an alpha channel is available for see-through areas. Every major browser shows PNG, and macOS takes screenshots in this format by default.

Programs that open PNG files

  • Windows, Mac and Linux: GIMP imports PNG for editing.
  • Windows, Mac and Linux: ImageMagick reads PNG.
  • Web and Mobile: Google Chrome displays PNG.
  • Web: Mozilla Firefox displays PNG.
  • Mobile: Safari displays PNG.

PNG and XBM compared

An XBM keeps its picture as C source text, not as a binary image. It served the X graphical environment for icons and pointer artwork, and it may include coordinates for a pointer hot spot. Its image is monochrome, so the colors, grays and transparency of a PNG have nowhere to go and color artwork turns monochrome.

On this page your browser decodes the PNG, and ImageMagick then writes the XBM from those pixels. Metadata is dropped along the way.

Other ways to convert PNG to XBM

  • GIMP: open the PNG, choose File > Export As, type a name that ends in .xbm and click Export. GIMP offers XBM only for an image with 8 bits per channel. The export options are an X10 format bitmap, an identifier prefix, a comment, hot spot values, and a mask file that is enabled only when the image has an alpha channel.
  • ImageMagick: run magick picture.png picture.xbm. ImageMagick reads and writes XBM, for black and white only.
  • ImageMagick, flattened first: run magick picture.png -background white -alpha remove -alpha off -monochrome picture.xbm. Here -alpha remove composites the image over the background color, -alpha off disables the alpha channel and -monochrome transforms the image to black and white.

Problems with PNG files

  • Compression setting: pixels come through exactly as saved, because PNG never discards image data.
  • Layer offsets: the offset option in GIMP's PNG export places layers in a way other programs may not match, so leave it unchecked.
  • Camera tags and profiles: an export from GIMP carries them only if you enable its metadata controls.

Frequently Asked Questions

Everything you need to know about our converter

How do I turn a PNG into an XBM?

Will my colors survive?

What happens to transparency?

Can I set the hot spot or the X10 format?

What is inside an XBM file?

Can I convert several PNGs at once?

Does the PNG metadata come along?

What if my PNG is 16-bit?