ascii anima

year
2026
tags
web

tldr

images and clips baked into tiny interactive ascii, so a page can look good and still load fast

HD images and video weigh a tonne. Characters don’t.

Why

Every site I build ends the same way: me staring at Lighthouse, Google’s speed test for websites, stuck somewhere around 80 out of 100. I optimise, and optimise, and it always comes back to the same thing. As designers we want everything crispy and high def, and nothing drags a page down like high def images and video. The page gets slow, the score drops, and Google pushes slow pages further down its search results, so fewer people ever find them.

So I went looking for a way to put pictures, and things you can actually play with, on a page without the weight.

The trick

ASCII art. You’ve seen it before: pictures made only out of letters and symbols you can type. Take an image, pixelate it, and swap every cell for a character that’s about as bright.

What’s wild is how little it needs. A full HD photo has about two million pixels. Cut it down to a few thousand characters and it still reads fine, cus your eyes fill in the rest.

And there’s a bonus I didn’t plan for. Before a website sends a file to your browser, the server squashes it smaller, kind of like zipping it, with something called brotli. That works great on text and does basically nothing for a JPG, which was already squashed when it was saved. A map is just text, so it shrinks all over again.

Three squares drawn to scale, each one's area matching its file size. The beetle photo as a 900 by 900 jpg is 41 KB, and it is sent as is, since a jpg is already compressed. Baked into a map of 98 by 54 characters it is 9.1 KB. Squashed with brotli on the way out, the map that actually gets sent is 3.2 KB.The photo41 KB900 × 900 jpgsent as isThe map9.1 KB98 × 54 charactersWhat gets sent3.2 KBthe map, brotlibakesquash

All three squares are drawn to scale: the beetle as a JPG, as a map, and as the map that actually gets sent.

And cus it’s all characters, it can move and react to you. Hover over these. Click them.

The beetle, in its own colours. 3.2 KB.
Clips work too: 240 frames of TomSka's muffin song. 333 KB.

The mapper

The mapper is where a picture becomes a map. Drop in an image or a clip, and everything you change shows up live.

the mapper: the beetle baked into characters on the left, and on the right the settings for columns, gamma, colour and the character ramp
The mapper with the beetle loaded: the preview on the left, the settings on the right.

Columns are the big one: how many characters wide the picture is. Fewer columns means a smaller file and a chunkier picture, and the readout under the preview tells you what it’ll cost while you drag.

Columns from 98 down to 24, up to 160, and back. Watch the size at the bottom left.

Then it’s all yours to change. Pick your own characters, and drag the point where each one takes over, from the darkest parts to the brightest. Colour it with a gradient, or keep the photo’s own colours. Load a clip instead of a photo. Shape the hover lens, the magnifying glass that follows your mouse, and draw the curve the characters follow when you click.

Then you decide how it reacts. Hovering drags a lens across it, and a click throws the characters out and lets them settle back home.

The hover lens and two clicks, on the beetle's own settings.
Two parts. Top: a field of characters with a click in the middle; every character inside the dashed click radius, 35% of the width, is pushed outward, away from the click. Bottom: the motion curve the beetle on this page uses, how far the characters are thrown over a 1.84 second burst. They go all the way out in the first fifth of a second, hold, drop most of the way back, and drift home.##wwtt:tfw##wftfw##wfttttfwffft:...:tfffft:...:tffft:...:fft:...:t###wttttwfttttfw####wfff#wfffw####wfftfwfftfw#wwwf::::f::::tfffft....:....:twwwf::::ft::::tf###wfftfw##wfftfw#####wfffw#####wfffw####wttttfw###fw##wwttttfwtt:fft:...:ttffft:...:tffw##wwttttfw##w#####wfffw####w####wfftfw####tfwwwf::::tfwwf:tfftt....:tffttfwwff::::tfww####wfftfw######wfffw#wttttdashed: the click radius, 35% of the width0 s1 s2 s100%50%homeHow far out, over timeout, all the waydropand drift homeone burst: 1.84 s

There’s also a reveal mode, for when the real photo has to show up in the end. The map shows up straight away, cus it’s tiny, and the photo fades in over it once it has finished downloading.

Reveal mode: the map first, then the photo.

When it looks right, the mapper bakes all of it into one small file, the .asciimap.

The player

The map goes onto a website with the player, a small bit of JavaScript that reads the map and draws it. It’s about 11 KB to download, and it only downloads once, however many maps the page has. It’s one file that doesn’t need anything else installed: add one line to your page and it works.

Flowchart, top to bottom: your image or clip (jpg, png, mp4 or mov) is dropped into the mapper, where you set the characters, colours, hover, click radius and motion curve. The mapper bakes one .asciimap file, 1.5 KB for a still and 82 KB for a clip. Your website embeds it with the player, about 11 KB, loaded once for every map, and it plays.Your image or clipThe mapper.asciimapThe playerYour websitejpg, png, mp4, movdrop it incharacters, colours,hover, click radius,motion curvebakeone file:1.5 KB for a still,82 KB for a clipembed~11 KB, loads oncefor every mapit plays

On this site

creativetech.wtf runs on ascii anima. If you’ve noticed how zippy this site is, a lot of that is thanks to this, and to Svelte, the framework the site is built with. The photos on the home page are ascii maps, and every picture on the works, toys and faffs pages starts out as one, with the same reveal: the map first, then the photo once it lands.

When I tested the home page, the computer version scored 100 in all four of Lighthouse’s tests, and on a phone the speed score sits in the 90s. I’ll take it.

four Lighthouse gauges, performance, accessibility, best practices and SEO, all at 100
Lighthouse on the creativetech.wtf home page, desktop, 17 October 2026.

How long it took

About ten and a half weeks, from the first test file on 4 August to the player going public on 17 October. It started as one HTML file sitting in a folder of this site, and grew into a file format, a mapper, a player library, the pictures on this site, a gallery site of its own and a public repo, the code up on GitHub for anyone to use. With a very quiet September in the middle .-.

Timeline, day 1 to day 75. 4 August, ascii-lab: one HTML file, a test in a folder of this site. 5 August: the .asciimap format, stored colour and five hover effects. 7 August: split into a mapper and a player library. 8 August: the home page photos of this site go ascii. 11 August: renamed ascii anima, its own repo, MIT licence. 29 August: a speed pass finds the compression bug. Then five quiet weeks. 5 October: the works, toys and faffs pages, 48 pictures animating at once. 13 October: versions 0.9 and 0.10, with reveal mode, better colours and a new mapper. 16 October: its own gallery site and mapper page. 17 October: the player goes public on GitHub.4 Augday 1ascii-labone HTML file, a test in a folder of this site5 Augday 2the .asciimapthe file format, colour, five hover effects7 Augday 4mapper + playersplit into a tool and a library8 Augday 5on this sitethe home page photos go ascii11 Augday 8ascii animarenamed, its own repo, MIT29 Augday 26speed passfinds the compression bugfive quiet weeks5 Octday 63works, toys, faffs48 pictures animating at once13 Octday 71v0.9 and v0.10reveal mode, better colours, a new mapper16 Octday 74its own sitethe gallery, and the mapper page17 Octday 75publicthe player goes up on GitHub

Day 2 already had the bones: the file format, a way to store the photo’s colours, and five ready-made hover effects. Everything after that was making it faster, lighter and way more yours.

An honest note: the code was all written with Claude Code. I came up with the ideas and steered where it went, which honestly made the whole process really fun, like putting Lego together.

Why not WebGL

WebGL lets a website draw with your graphics card, the same chip that runs your games. It’s the usual answer when you want a lot of things moving on a page and still want it smooth, so it was the obvious thing to reach for.

I stayed with plain canvas, the simpler drawing tool every browser has built in, because the whole point of this is speed. WebGL is built into browsers too, but drawing text with it takes a lot more code, and most people pull in a library like three.js to do it, which on its own is more than ten times the size of the whole player. That’s more to download before anything shows up, the exact thing I was trying to get rid of. And drawing text is something browsers are already crazy good at. Chrome even remembers every character it has already drawn, so it doesn’t redo the work.

I did try the trick graphics card drawing leans on: draw every character once onto one big sheet, then copy and paste from it instead of drawing text every time. It got built twice and measured side by side with the normal way. It was no faster, ate up to 12 MB of memory for every picture on the page, and looked worse with the photo’s own colours. Binned.

What actually made it fast was doing less. Only redraw the characters that changed. Sleep when nothing moves. Stop when it’s off screen or the tab is hidden. Draw all the characters of one size and weight together instead of switching back and forth, which took a lens turned all the way up from about 610 switches every frame down to 19.

The chart counts frames a second: how many times a second the picture redraws. 60 is smooth, and under 30 starts to feel choppy.

Bar chart, frames a second with the CPU slowed down four times, version 0.9 against 0.10. A clip playing: 26 to 37, now about 58. The lens parked: 15 to 21, now about 60, because the player sleeps. Three click bursts: 17 to 21, now about 21. The lens moving at its maximum size: 15 to 21, now about 19. The last two are the wall: drawing text is as fast as the browser can go.frames a second, CPU slowed 4×03060a clip playing26-37~58the lens, parked15-21~60three click bursts17-21~21the lens moving, maxed15-21~19v0.9v0.10

The two that barely moved are the limit. A huge lens moving over a detailed map is just a lot of text to draw, and a browser can only draw text so fast. That’s the one place WebGL would still help. It hasn’t needed it yet.

What I learnt

The server wasn’t squashing it. An .asciimap is a made-up file type, and a server that doesn’t recognise a file type doesn’t squash it, it just sends it as is. When I tested the home page in August, its maps came through at 255 KB where 89 KB would do, and one clip alone was 40% of the whole page. The fix was one line telling the server it’s text, and that line still ships with the site today.

Let the compressor do its job. I tried packing clip frames smarter, by only storing what changed from one frame to the next. Every version came out bigger than plain text run through brotli: 15.6 to 20.3 KB, against 14.4 KB. Brotli is better at this than me.

Colour fits in one tiny JPEG. A map in the photo’s real colours needs a colour for every character. Stored as numbers, that’s around 103 KB for a photo. Stored as a JPEG exactly the size of the grid, one pixel per character, it’s around 11 KB.

Gradients without the mud. Blend red into blue on a canvas and you get a muddy purple in the middle. CSS, the code that styles websites, can blend colours a different way called OKLCH, which mixes them more like your eyes expect, so they stay vivid. Canvas can’t, so the player does the OKLCH maths itself. Red to blue now goes through a proper purple.

Big clicks are what lag. The hover lens is cheap. What makes a page stutter is a click with a big reach, the blast radius, cus every character it throws has to be redrawn every frame. The slider in the mapper turns red past 0.6 now, as a warning.

Where it fits

It’s not for everything and anything. A product shot that needs every pixel should stay a photo, and a screenshot full of small text turns to mush. But for moody hero shots, textures, portraits, loops and anything you want people to poke at, it fits pretty darn well.

Grab it

The mapper runs in the browser: drop in an image or a clip, shape it, and download the .asciimap. The player is free and open source, so anyone can use it and read the code, ready to put on your site. Give it a shot, it’s pretty fun.

Open the mapper →Get the player on GitHub →