A 4k intro is a real-time audiovisual program — graphics, animation, and a full soundtrack — squeezed into an executable file no larger than 4096 bytes. A 64k intro allows a little more room, 65,536 bytes, but still far less than a single uncompressed second of CD-quality audio. There's no room to store an MP3 or a WAV file in either case. So how do these tiny programs have music at all? The answer is that they don't store sound — they store the recipe for generating sound, and a synthesizer that cooks it in real time. Two of the most widely used tools for that recipe, born in the same demoscene group, are 4klang and 64klang.
A conventional music file is a recording — a long list of sampled amplitude values. Even compressed formats like MP3 need tens of kilobytes per second. A 4k intro's entire budget for graphics, code, and music combined is smaller than that. The demoscene's solution, refined over decades of trackers and synth tools, is to treat music the way a MIDI file treats it: store only the notes, the instrument parameters, and the arrangement, then let a small piece of code generate the actual waveform from scratch while the intro is running. The "song" is really just a set of numbers describing oscillators, filters, and envelopes — and a synthesizer that knows how to turn those numbers into sound.
4klang was created by Dominik "gopher" Ries and Paul "pOWL" Kraus, both members of the Swiss demogroup Alcatraz. Development began around 2007, and the tool was first released publicly in 2009, as documented in the project's official repository. It's a modular software synthesizer distributed as a VSTi plugin, so musicians can compose directly in a normal DAW, alongside an example C project that shows how to link the same synth engine into an actual 4k intro executable.
The technical trick behind 4klang is its use of the FPU (floating-point unit) stack as the signal path for the synth's modules — an idea the authors credit, in their repository notes, to an earlier 4k soundtrack by the group Freestyle as their main inspiration. Routing signal through the processor's own floating-point stack, instead of building a generic modular architecture, let 4klang's compiled synth core stay extremely small, since the "wiring" between oscillators, filters, and envelopes could be expressed in just a few machine instructions rather than a full audio graph. The result is a synth engine and player small enough to leave the vast majority of a 4096-byte budget for graphics code.
4klang has since been forked and extended by other scene coders — notably as sointu, a version that targets 32-bit and 64-bit Windows as well as WebAssembly, letting 4klang-style music run in a browser.
With sixteen times the space of a 4k intro, a 64k intro can afford a noticeably more elaborate synthesizer, and that's exactly what 64klang is. Also developed by Dominik Ries of Alcatraz, the first version was built around 2010–2011, according to the 64klang repository, for a 64k intro made jointly with the group Fairlight. Rather than reusing 4klang's FPU-stack trick, 64klang generalizes the idea into a full node-graph system: musicians connect oscillators, filters, envelopes, and effects visually, much like a modular hardware synth, and the tool compiles that graph down into compact code and data.
64klang went through several major rewrites. The first version had its synth core written in assembly with a basic Win32 interface. 64klang2, developed between 2012 and 2014, rebuilt the core in C++ with heavy use of SSE instructions for speed and added a more usable WPF-based interface, shipping as a VST2 plugin used in a number of 64k intros and standalone "executable music" tracks. A cross-platform 64klang3 rewrite, using VST3 and an ImGui interface, has continued development more recently.
Tools like 4klang and 64klang are a good illustration of a broader demoscene principle: constraints don't just limit creativity, they redirect it. Instead of asking "how do we compress an audio file smaller," these coders asked "how do we avoid needing an audio file at all," and built synthesizers precise enough, and small enough, to answer that question. The same instruments and modules get reused across many different intros, in the same way a musician reuses the same guitar for different songs — except here the "guitar" itself has to fit inside the same handful of kilobytes as the music it plays.