Quick answer

It's the color palette, not the pixel count. Resizing a GIF forces every single frame to be redrawn and re-quantized to a brand-new color palette, and that process breaks whatever palette-sharing and frame-to-frame redundancy the original file had. GIF compression depends far more on how much data repeats between consecutive frames than on how many pixels each frame has — so a resize can easily produce fewer, smaller-dimension pixels packed into a less compressible file, and the result comes out larger even though it looks smaller on screen. This is a genuinely different mechanism from "quality loss," and it catches people off guard because it runs against the intuition that smaller dimensions should always mean a smaller file.

How GIF compression actually works

GIF size comes mainly from two things: a limited color palette (256 colors max per frame) run through LZW compression, and how much of each frame is identical to the frame before it. A well-optimized source GIF — the kind exported by a screen recorder or hand-tuned in an editor — often uses one shared palette across all frames and stores each frame as a small "diff" patch covering only the pixels that actually changed, with disposal instructions telling the decoder what to do with the rest of the canvas. That's why a simple looping animation with a static background can be tiny: most of most frames is redundant, and LZW compresses redundancy extremely well. Resizing disrupts both of those levers at once, which is the actual reason file size can go up.

What resizing actually does to each frame

PixelTools' own resize tool confirms this directly in code. Its shared GIF pipeline decodes every frame with disposal-aware compositing, hands each fully-composited frame to the resize transform, then re-encodes the result by calling gifenc's quantize() and applyPalette() inside the per-frame loop — so every output frame gets its own freshly computed palette based only on that frame's resized pixels, rather than one palette shared across the whole animation. The encoder also writes each output frame at the full composited canvas size, even when the original frame was a small partial-canvas diff patch. Two structural changes, both working against compression: a fresh palette per frame instead of one shared palette, and full frames instead of small diffs.

Why fresh palettes and full frames bloat the file

When every frame picks its own "best" colors for that frame alone, two adjacent frames that used to share identical color-index values for identical pixels often no longer do — the same visual color gets a different palette index from one frame to the next purely because quantization ran independently each time. LZW compression works by finding repeated byte sequences, so this palette drift alone can wreck cross-frame redundancy even when the actual image content barely changed. Layer on top of that every frame being written at full canvas size instead of a small changed-region patch, and the encoder is compressing far more raw data per frame than the source file was. Fewer, cleaner colors per individual frame; far less redundancy across frames — that trade routinely loses on total file size.

When this problem shows up worst

This is most dramatic on GIFs that were already well-optimized before you touched them — screen recordings, UI demos, simple looping animations with mostly-static backgrounds, anything exported by a tool that used a shared palette and partial-frame diffs on purpose. Those files have the most redundancy to lose. It's far less noticeable on GIFs that were poorly optimized to begin with, or on short, simple, low-color animations where there wasn't much cross-frame redundancy to break in the first place. Larger resizes, higher frame counts, and busier per-frame content (photographic gradients, noise, complex backgrounds) all make the effect more visible, because re-quantization has more colors to reassign differently on every single frame.

How to fix it

Resize first, then run the result through a dedicated GIF-aware compressor rather than expecting the resize step alone to produce a small file — resizing and compressing are solving different problems (dimensions vs. palette/redundancy), so a single tool call doing only the resize was never going to optimize the second one. A GIF-specific compressor re-applies palette reduction and frame optimization deliberately, the same way the original file likely got small in the first place, instead of it happening as an unintended side effect of quantizing frames independently. If the resized file is still larger than expected afterward, try lowering the palette size explicitly, or check whether the animation would work just as well as a much smaller video format (MP4/WebM) instead of GIF.