emptygif
Language: English

The smallest transparent GIF is 43 bytes.

This is all of it. Pick any byte to see what it does, then copy the file, download it, hotlink it, or serve it from your own code.

The 43-byte GIF, enlarged: one transparent pixel
0000
0010
0020
Download 1×1.gif

R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==

Inspect your own GIF

What every byte does

A GIF is a sequence of blocks. This one has seven, and every colour on this page belongs to one of them. Select a byte or a block to read it. Numbers are stored little-endian: the low byte comes first, so 01 00 means 1.

BytesFieldMeaning
Header Tells the decoder this is a GIF and which version of the format to expect.
47 49 46SignatureThe ASCII letters “GIF”. Every GIF file starts with them.
38 39 61Version“89a”. 89a is needed for transparency; 87a has no graphic control extension.
Logical screen descriptor The size of the canvas and how its colour table is set up.
01 00Canvas width1 px.
01 00Canvas height1 px.
80Packed flagsFour settings squeezed into one byte. The top bit says a global colour table follows; the last three bits give its size.
00Background colour indexPalette entry 0. Browsers ignore it and show what is behind the image.
00Pixel aspect ratio0 means square pixels, with no correction.
Global colour table The palette. Pixels store an index into this list instead of a colour.
FF FF FFPalette entryRed, green and blue, one byte each: #ffffff. Two entries is the smallest table a GIF can have.
00 00 00Palette entryRed, green and blue, one byte each: #000000. Two entries is the smallest table a GIF can have.
Graphic control extension Optional block added in GIF89a. Here it makes palette entry 0 transparent.
21Extension introducer0x21 (“!”) announces an extension block.
F9Graphic control label0xF9 says this extension is a graphic control extension.
04Block size4 bytes of settings follow.
01Packed flagsThe lowest bit is the transparency flag. It is on, so the transparent index below is used.
00 00Delay0 hundredths of a second. It only matters for animations.
00Transparent colour indexPalette entry 0 is drawn as fully transparent.
00Block terminatorA zero-length sub-block that closes the block.
Image descriptor Where the image sits on the canvas and how big it is.
2CImage separator0x2C (“,”) starts an image.
00 00LeftThe image starts 0 px from the left edge of the canvas.
00 00TopThe image starts 0 px from the top edge of the canvas.
01 00Image width1 px.
01 00Image height1 px.
00Packed flagsNo local colour table, not interlaced. The image uses the global palette.
Image data The pixels, compressed with LZW and split into sub-blocks of up to 255 bytes.
02LZW minimum code size2, so compressed codes start 3 bits wide.
02Sub-block size2 bytes of compressed data follow.
44 01Compressed pixelsLZW codes packed from the lowest bit up. See how they decode below.
00Block terminatorA zero-length sub-block that closes the block.
Trailer One byte that marks the end of the file.
3BTrailer0x3B (“;”) ends the file.

Inside the packed bytes

Three bytes each store several small settings. Bit 7 is the leftmost.

Logical screen descriptor 0x80
1Global colour table present
000Colour resolution
0Palette sorted by importance
000Table size: 2^(n+1) entries
Graphic control extension 0x01
000Reserved
000Disposal method
0Wait for user input
1Transparency on
Image descriptor 0x00
0Local colour table present
0Interlaced
0Palette sorted by importance
00Reserved
000Local table size

How two bytes hold one pixel

With a minimum code size of 2, the decoder reads 3-bit codes. Code 4 clears the table, code 5 ends the image, and codes 0 to 3 are palette entries. The bytes 44 01 are read from the lowest bit up:

0x44 010001000x01 00000001

  1. 001100 = 4Clear: start with a fresh table
  2. 000000 = 0Pixel: palette entry 0
  3. 101101 = 5End of image
  4. 0000000 Unused padding bits

Bigger images use the same trick: every new code stands for a run one pixel longer than the last, so a 1000×1000 transparent GIF takes only 1,743 bytes.

Can it be smaller?

Yes, if you drop parts that decoders tolerate losing. We fed each variant to three browser engines and to Pillow and recorded what they drew.

SizeVariantChromiumFirefoxWebKitPillow
43The standard file on this page.TransparentTransparentTransparentTransparent
42No trailer byte. Decoders stop at the end of the data anyway.TransparentTransparentTransparentTransparent
37No palette at all. Still valid: the spec lets decoders use their own palette, and index 0 is transparent anyway.TransparentTransparentTransparentTransparent
36No palette and no trailer.TransparentTransparentTransparentTransparent
35No transparency block: the pixel is drawn in palette colour 0, white.WhiteWhiteWhiteWhite
35The 1987 format. It has no way to mark a colour transparent.WhiteWhiteWhiteWhite
34Transparency block but no compressed pixels.TransparentTransparentTransparentError
33The same without the trailer.TransparentTransparentTransparentError
29No palette and no transparency. Each engine picks its own colour.BlackWhiteTransparentBlack
26An image with no compressed data at all.TransparentTransparentTransparentError
14Header, canvas size and trailer only. There is no image in it.TransparentErrorTransparentError

Use 43 bytes when it must work everywhere. 37 bytes is still valid GIF and was transparent in every engine we tested. Below that you depend on decoder leniency, and the 29-byte file shows how engines disagree.

Checked on September 23, 2026 with Chromium 153.0.8010.12, Firefox 155.0, WebKit 26.6, Pillow 12.2.0.

The same pixel in other formats

The smallest transparent 1×1 file we could build in each format, fed to the same four engines. Open a row to see its bytes, coloured like the GIF blocks that do the same job.

SizeFileData URIChromiumFirefoxWebKitPillow
28
WebP The same without two padding bytes. WebKit rejects WebP files shorter than 30 bytes.
52 49 46 46 14 00 00 00 57 45 42 50 56 50 38 4c 08 00 00 00 2f 00 00 00 10 88 88 08
  • RIFF … WEBP Container 12
  • VP8L chunk Container 8
  • 0x2F Signature 1
  • width, height, alpha Size 4
  • prefix codes Pixels 3
63TransparentTransparentErrorTransparent
30
WebP Lossless VP8L. Every prefix code holds a single symbol, so pixels take no bits and the file stays this size up to 16384×16384.
52 49 46 46 16 00 00 00 57 45 42 50 56 50 38 4c 0a 00 00 00 2f 00 00 00 10 88 88 08 00 00
  • RIFF … WEBP Container 12
  • VP8L chunk Container 8
  • 0x2F Signature 1
  • width, height, alpha Size 4
  • prefix codes Pixels 3
  • padding Padding 2
63TransparentTransparentTransparentTransparent
43
GIF The 43-byte GIF from the top of this page.
47 49 46 38 39 61 01 00 01 00 80 00 00 ff ff ff 00 00 00 21 f9 04 01 00 00 00 00 2c 00 00 00 00 01 00 01 00 00 02 02 44 01 00 3b
  • Header 6
  • Logical screen descriptor 7
  • Global colour table 6
  • Graphic control extension 8
  • Image descriptor 10
  • Image data 5
  • Trailer 1
82TransparentTransparentTransparentTransparent
58
BMP The classic 40-byte header has no alpha mask, so the fourth byte is ignored and the pixel is black everywhere.
42 4d 3a 00 00 00 00 00 00 00 36 00 00 00 28 00 00 00 01 00 00 00 01 00 00 00 01 00 20 00 00 00 00 00 04 00 00 00 13 0b 00 00 13 0b 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  • BITMAPFILEHEADER Signature 14
  • BITMAPINFOHEADER Size 40
  • BGRA Pixels 4
102BlackBlackBlackBlack
62
SVG An empty svg element with a width and height. Pillow does not read SVG.
<svg xmlns="http://www.w3.org/2000/svg" width="1" height="1"/>
  • <svg xmlns> Signature 39
  • width, height Size 21
  • /> End 2
85TransparentTransparentTransparentError
67
PNG Truecolour with alpha. The single scanline of zeros is compressed by hand, one byte shorter than zlib at its best setting.
89 50 4e 47 0d 0a 1a 0a 00 00 00 0d 49 48 44 52 00 00 00 01 00 00 00 01 08 06 00 00 00 1f 15 c4 89 00 00 00 0a 49 44 41 54 78 01 63 00 01 00 00 05 00 01 36 d0 88 dd 00 00 00 00 49 45 4e 44 ae 42 60 82
  • PNG signature Signature 8
  • IHDR Size 25
  • IDAT Pixels 22
  • IEND End 12
114TransparentTransparentTransparentTransparent
70
ICO A favicon holding a 32-bit bitmap and its 1-bit AND mask.
00 00 01 00 01 00 01 01 00 00 01 00 20 00 30 00 00 00 16 00 00 00 28 00 00 00 01 00 00 00 02 00 00 00 01 00 20 00 00 00 00 00 08 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 80 00 00 00
  • ICONDIR Signature 6
  • ICONDIRENTRY Size 16
  • BITMAPINFOHEADER Size 40
  • BGRA Pixels 4
  • AND mask Transparency 4
121TransparentTransparentTransparentTransparent
74
BMP A 56-byte header with an alpha mask. WebKit does not load it.
42 4d 4a 00 00 00 00 00 00 00 46 00 00 00 38 00 00 00 01 00 00 00 01 00 00 00 01 00 20 00 03 00 00 00 04 00 00 00 13 0b 00 00 13 0b 00 00 00 00 00 00 00 00 00 00 00 00 ff 00 00 ff 00 00 ff 00 00 00 00 00 00 ff 00 00 00 00
  • BITMAPFILEHEADER Signature 14
  • BITMAPV3INFOHEADER Size 56
  • BGRA Pixels 4
122TransparentTransparentErrorTransparent
89
ICO A favicon holding the 67-byte PNG.
00 00 01 00 01 00 01 01 00 00 01 00 20 00 43 00 00 00 16 00 00 00 89 50 4e 47 0d 0a 1a 0a 00 00 00 0d 49 48 44 52 00 00 00 01 00 00 00 01 08 06 00 00 00 1f 15 c4 89 00 00 00 0a 49 44 41 54 78 01 63 00 01 00 00 05 00 01 36 d0 88 dd 00 00 00 00 49 45 4e 44 ae 42 60 82
  • ICONDIR Signature 6
  • ICONDIRENTRY Size 16
  • PNG signature Signature 8
  • IHDR Size 25
  • IDAT Pixels 22
  • IEND End 12
145TransparentTransparentTransparentTransparent
126
BMP The V4 header. WebKit ignores its alpha mask and draws black.
42 4d 7e 00 00 00 00 00 00 00 7a 00 00 00 6c 00 00 00 01 00 00 00 01 00 00 00 01 00 20 00 03 00 00 00 04 00 00 00 13 0b 00 00 13 0b 00 00 00 00 00 00 00 00 00 00 00 00 ff 00 00 ff 00 00 ff 00 00 00 00 00 00 ff 42 47 52 73 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  • BITMAPFILEHEADER Signature 14
  • BITMAPV4INFOHEADER Size 108
  • BGRA Pixels 4
190TransparentTransparentBlackTransparent
142
BMP The V5 header, with the same result in WebKit.
42 4d 8e 00 00 00 00 00 00 00 8a 00 00 00 7c 00 00 00 01 00 00 00 01 00 00 00 01 00 20 00 03 00 00 00 04 00 00 00 13 0b 00 00 13 0b 00 00 00 00 00 00 00 00 00 00 00 00 ff 00 00 ff 00 00 ff 00 00 00 00 00 00 ff 42 47 52 73 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  • BITMAPFILEHEADER Signature 14
  • BITMAPV5INFOHEADER Size 124
  • BGRA Pixels 4
214TransparentTransparentBlackTransparent
437
AVIF The same with 4:0:0 subsampling, which drops the colour planes.
00 00 00 1c 66 74 79 70 61 76 69 66 00 00 00 00 61 76 69 66 6d 69 66 31 6d 69 61 66 00 00 01 6a 6d 65 74 61 00 00 00 00 00 00 00 21 68 64 6c 72 00 00 00 00 00 00 00 00 70 69 63 74 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0e 70 69 74 6d 00 00 00 00 00 01 00 00 00 2c 69 6c 6f 63 00 00 00 00 44 00 00 02 00 01 00 00 00 01 00 00 01 a0 00 00 00 15 00 02 00 00 00 01 00 00 01 8e 00 00 00 12 00 00 00 42 69 69 6e 66 00 00 00 00 00 02 00 00 00 1a 69 6e 66 65 02 00 00 00 00 01 00 00 61 76 30 31 43 6f 6c 6f 72 00 00 00 00 1a 69 6e 66 65 02 00 00 00 00 02 00 00 61 76 30 31 41 6c 70 68 61 00 00 00 00 1a 69 72 65 66 00 00 00 00 00 00 00 0e 61 75 78 6c 00 02 00 01 00 01 00 00 00 a7 69 70 72 70 00 00 00 81 69 70 63 6f 00 00 00 14 69 73 70 65 00 00 00 00 00 00 00 01 00 00 00 01 00 00 00 0e 70 69 78 69 00 00 00 00 01 08 00 00 00 0c 61 76 31 43 81 00 1c 00 00 00 00 13 63 6f 6c 72 6e 63 6c 78 00 01 00 0d 00 06 80 00 00 00 38 61 75 78 43 00 00 00 00 75 72 6e 3a 6d 70 65 67 3a 6d 70 65 67 42 3a 63 69 63 70 3a 73 79 73 74 65 6d 73 3a 61 75 78 69 6c 69 61 72 79 3a 61 6c 70 68 61 00 00 00 00 1e 69 70 6d 61 00 00 00 00 00 00 00 02 00 01 04 01 02 83 04 00 02 04 01 02 83 05 00 00 00 2f 6d 64 61 74 12 00 0a 04 18 00 06 15 32 08 10 00 00 18 e1 42 72 10 12 00 0a 07 18 00 06 18 08 68 35 32 08 10 00 00 18 e1 42 72 10
  • ftyp Signature 28
  • meta Metadata 362
  • mdat Pixels 47
607TransparentTransparentTransparentTransparent
471
AVIF What libavif writes at quality 100: one AV1 image for colour and one for alpha, in ISO BMFF boxes.
00 00 00 20 66 74 79 70 61 76 69 66 00 00 00 00 61 76 69 66 6d 69 66 31 6d 69 61 66 4d 41 31 42 00 00 01 86 6d 65 74 61 00 00 00 00 00 00 00 21 68 64 6c 72 00 00 00 00 00 00 00 00 70 69 63 74 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0e 70 69 74 6d 00 00 00 00 00 01 00 00 00 2c 69 6c 6f 63 00 00 00 00 44 00 00 02 00 01 00 00 00 01 00 00 01 c0 00 00 00 17 00 02 00 00 00 01 00 00 01 ae 00 00 00 12 00 00 00 42 69 69 6e 66 00 00 00 00 00 02 00 00 00 1a 69 6e 66 65 02 00 00 00 00 01 00 00 61 76 30 31 43 6f 6c 6f 72 00 00 00 00 1a 69 6e 66 65 02 00 00 00 00 02 00 00 61 76 30 31 41 6c 70 68 61 00 00 00 00 1a 69 72 65 66 00 00 00 00 00 00 00 0e 61 75 78 6c 00 02 00 01 00 01 00 00 00 c3 69 70 72 70 00 00 00 9d 69 70 63 6f 00 00 00 14 69 73 70 65 00 00 00 00 00 00 00 01 00 00 00 01 00 00 00 10 70 69 78 69 00 00 00 00 03 08 08 08 00 00 00 0c 61 76 31 43 81 00 0c 00 00 00 00 13 63 6f 6c 72 6e 63 6c 78 00 01 00 0d 00 06 80 00 00 00 0e 70 69 78 69 00 00 00 00 01 08 00 00 00 0c 61 76 31 43 81 00 1c 00 00 00 00 38 61 75 78 43 00 00 00 00 75 72 6e 3a 6d 70 65 67 3a 6d 70 65 67 42 3a 63 69 63 70 3a 73 79 73 74 65 6d 73 3a 61 75 78 69 6c 69 61 72 79 3a 61 6c 70 68 61 00 00 00 00 1e 69 70 6d 61 00 00 00 00 00 00 00 02 00 01 04 01 02 83 04 00 02 04 01 05 86 07 00 00 00 31 6d 64 61 74 12 00 0a 04 18 00 06 15 32 08 10 00 00 18 e1 42 72 10 12 00 0a 08 18 00 06 08 08 68 34 20 32 09 10 00 00 00 07 c8 24 c6 62
  • ftyp Signature 32
  • meta Metadata 390
  • mdat Pixels 49
651TransparentTransparentTransparentTransparent

WebP, at 30 bytes, is the smallest file that came out transparent in all four engines: 13 bytes less than the GIF.

Data URI length in characters: SVG as URL-encoded text, the rest in base64. Checked on September 24, 2026 with Chromium 153.0.8010.12, Firefox 155.0, WebKit 26.6, Pillow 12.2.0. AVIF written by libavif 1.4.1.

Make one any size

Transparent or a solid colour, from 1×1 up to 65535×65535. It is generated in your browser; nothing is uploaded.

Fill
Format
Common sizes

1×1 · 43 bytes

Download GIF

Serve it from your stack

191 ready-to-run snippets. Pick yours: each one answers at the path you choose with an image/gif response. If you changed the size or colour above, the snippets use that GIF.

Express JavaScript

Install
npm i express
File
server.mjs
Run
node server.mjs
import express from 'express';

const GIF = Buffer.from('R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==', 'base64');

const app = express();

app.get('/pixel.gif', (req, res) => {
  res.set('Cache-Control', 'no-store');
  res.type('gif').send(GIF);
});

app.listen(8080);

We ran this snippet and compared the bytes it returned. Open page

What it is used for

  • Tracking pixels and beacons: the server logs the request and answers with the smallest valid image.
  • Placeholders for lazy-loaded images, so the img tag is valid before the real source arrives.
  • Fixed-size spacers in HTML email, where CSS support is patchy.
  • Tests and mocks that need a real image without shipping one.

Tracking pixels are less reliable than they look

Apple Mail preloads remote images through a proxy when Mail Privacy Protection is on, so an “open” may never have been a person. Gmail also fetches images through its own proxy and caches them. Many clients block remote images by default. For page analytics, navigator.sendBeacon() or a 204 No Content response is often a better fit than an image.

Questions

Why is it called empty when it has a pixel?
A GIF must have at least one pixel. This one is 1×1 and its only colour is marked transparent, so nothing shows.
Is the 43-byte file valid?
Yes. It follows the GIF89a specification exactly, and every engine in the table above draws it as transparent.
Why a GIF and not a PNG or WebP?
It is smaller than a minimal transparent PNG, and every browser, email client and image library from the last 35 years can read it.
Should I use a data URI or a file?
A data URI saves a request and suits placeholders and CSS. A file or endpoint is needed when the request itself is the point, as with tracking pixels.
Which Content-Type should I send?
image/gif. Add Cache-Control: no-store if every request must reach your server.