Skip to content

Images

Programs can put pictures in the terminal with any of three protocols. Core decodes the image, places it in the grid and scrolls it with the text. Rendering and placement support differ by client.

A Mandelbrot view drawn as a Kitty RGBA image inside a terminal, above explanatory grid text.
A Mandelbrot image alongside terminal text, using Kitty graphics.
Protocol Sequence What it carries
Kitty graphics protocol APC G … ST PNG, raw RGB or RGBA, zlib-compressed payloads, sent in chunks. Placement by cells or pixels, z-index, deletion, animation frames, and Unicode placeholders that let an image live inside text a multiplexer can pass through.
Sixel DCS q … ST Paletted bitmaps in six-row bands.
iTerm inline files OSC 1337 ; File=… A base64 file with width, height and aspect options.

PNG and zlib are decoded by Core’s own decoders, and TIFF as well; other formats go through the platform’s image decoder.

The macOS and iPhone and iPad apps draw images on the GPU. The Linux frontend uploads them as Vulkan textures. The web client composites images and Tek graphics on its CPU path. Agent screenshots can composite inline images with the grid.

Graphical Emacs supports source crops, whole-cell offsets and RGBA transparency when PNG support is available. Without PNG it can display opaque RGB through PPM. Subcell offsets, overlapping placements, behind-text images and Unicode placeholders are not rendered equivalently. Text-mode Emacs and the Neovim client do not draw inline images. These limits also apply to hosted sessions; local protocol support is not a promise of animation or placement parity on every remote client.

Image data is untrusted input, so each terminal holds at most 32 images, 128 placements and 256 MiB of decoded pixels, with 64 MiB and 16,384 pixels per side for any one image. At capacity, older images outside the live screen are evicted first, including images in scrollback; images on the live screen are kept when slots run out. A platform decoder allocates before the size check runs, so a single oversized file can briefly use more memory than the budget.

Sampling is a renderer choice; use native size for exact pixel placement. A program that wants an image to fill the window can enter mode 7402 and choose contain, stretch, native size or an integer scale with OSC 7402.

[security] dcs_deny = "sixel" refuses Sixel; osc_deny = "1337" refuses inline files. Rendering an image is not a permission the capability tiers gate: images draw for local, agent and remote sessions alike.