textmode.js brings the art of ASCII and textmode graphics into the modern web. Built for developers from all corners and skill levels of the creative coding world - it's the tool I wished existed when I started exploring textmode art.
Ready for production, built for creativity
A library designed for building generative art installations, retro games, interactive visualizations, live coding performances, and experimental web experiences. Whether you're prototyping an idea or shipping a production app, textmode.js has you covered.
Shape the future of textmode graphics. Your feedback, ideas, and creations help drive development. Join our Discord to share what you're building, get support, and connect with fellow textmode enthusiasts.
From zero to textmode in minutes
javascript
const tm = textmode.create();
tm.draw(() => {
tm.background(0, 0, 0, 0);
const halfCols = tm.grid.cols / 2;
const halfRows = tm.grid.rows / 2;
for (let y = -halfRows; y < halfRows; y++) {
for (let x = -halfCols; x < halfCols; x++) {
const dist = Math.sqrt(x * x + y * y);
const wave = Math.sin(dist * 0.2 - tm.frameCount * 0.1);
tm.push();
tm.translate(x, y, 0);
tm.char(wave > 0.5 ? '▓' : wave > 0 ? '▒' : '░');
tm.charColor(0, 150 + wave * 100, 255);
tm.point();
tm.pop();
}
}
});Simple, powerful, and ready for your wildest ideas.