Playground / Inside a File
Inside a File
Everyone double-clicks files. Almost nobody has seen what one is made of. Turn the dial and take one apart.
The lab's built-in tour, recorded frame by frame, with an original soundtrack. 85 seconds. Tap the speaker icon for sound.
Overview
What it is
A workbench with five stations. Each one peels away a layer of what a file really is.
- The icon. What you see in Finder. Neither the icon nor the name is stored inside the file.
- The folder. A register of names, each pointing to the number of an index card.
- The index card. Computers call it an inode. It holds the file's size, owner, permissions, and which disk boxes hold the contents.
- The disk. A rack of numbered boxes, 4,096 bytes each.
- The bytes. Numbers from 0 to 255, each made of 8 on/off switches.
At the end of the bench, a reader machine shows the big idea: the same bytes mean different things depending on what reads them. Read them as text, paint them as a picture, or hand them to the chip as a program.
How to use it
Turn, pick, read
- Move between stations: turn the dial at the bottom left, drag across the scene, scroll, or press the keys 0 to 5.
- Pick a file: a short note, a small photo, or
ls, a real program that ships with every Mac. - Switch the reader: read the same bytes as text, as a picture, or as a program (keys T, P and R).
- Watch the tour: press Play the tour (or Space) to watch it like a video. Touch anything to take over.
The numbers
What is real
Every byte, size and box count comes from real files, measured on my Mac on 26 Sep 2026.
- note.txt is 28 bytes. It still reserves one whole 4,096-byte box.
- photo.jpg is 5,013 bytes in 2 boxes. It starts
FF D8 FF, the mark of a JPEG, and read as text it gives away labels like JFIF and Photoshop. - ls is 154,624 bytes, yet it sits in just 9 boxes, because macOS stores its own programs compressed. It starts
CA FE BA BE, the mark of a Mac program carrying two editions: one for Intel chips, one for Apple chips. - The Terminal messages, "command not found" and "exec format error", are what Terminal really printed.
Only the positions of the boxes on the rack are drawn for illustration.
Behind it
How it was made
One HTML file of about 90 KB, built with Claude Code. The 3D scene uses three.js, and every object in it is made in code: no images, no 3D models.