ansimotd: The Go CLI That Refuses to Let Your Terminal Ruin ANSI Art

It reads SAUCE metadata, decodes CP437, and remaps vintage ANSI colors into true-color VGA values so 1990s BBS art looks the way it was meant to.

8 min read • View on GitHub • More from retlehs

A wide terminal on a desk shows the same ANSI artwork in two versions, split down the middle. The left side looks distorted by a modern theme, while the right side is restored with crisp vintage colors. The scene explains the project's main idea: preserving original visual intent instead of accepting whatever palette the terminal happens to use.
The core trick is not nostalgia. It is palette fidelity.
Key Takeaways

Modern terminals are hostile to old art. They re-theme colors, reinterpret glyphs, and quietly change the look of a file that was drawn for a very different machine culture. ansimotd exists to stop that drift.

Built by retlehs, the project is a Go CLI and library for rendering ANSI art from the 16colo.rs archive. Ben Word says he built it to "adds some personality to your terminal" and to display random ANSI art when you open a shell.

It’s a fun little project that adds some personality to your terminal.

The terminal is the problem

The surface idea is simple: show retro ANSI art at login. The actual problem is uglier. A file made for a 1990s BBS can look wrong in a modern terminal because the terminal substitutes its own color logic, font behavior, and spacing assumptions.

That is why ansimotd is interesting. It does not trust the terminal to preserve intent. It rebuilds the output so the original palette and character set survive the trip.

ansimotd restores the original look

The project’s signature move is color remapping. Instead of letting "ANSI red" mean whatever your theme says it means, ansimotd converts the ANSI color codes into 24-bit true-color escape sequences using the original VGA RGB values.

A single ANSI file passes through several compatibility repairs before it reaches the screen.

CapabilityGeneric MOTD scriptansimotd
Shell agnosticOften tied to one shellYes, works as a Go tool and library
Color fidelityUses terminal theme defaultsRemaps to exact VGA true-color values
SAUCE awarenessUsually ignoredYes, used for dimensions and structure
CP437 decodingFrequently missedYes, preserves legacy glyphs
Archive integrationManual file handlingBuilt around 16colo.rs packs
Fit to terminal widthUsually ad hocUses width-aware selection

This is the right trade-off for archive art. Fidelity matters more than convenience when the whole point is to preserve an object, not just display bytes.

Under the hood, it speaks legacy

The rendering path is a translation stack. First, the tool reads the file and strips SAUCE metadata from the tail. Then it decodes Code Page 437, which is where the original box-drawing characters and symbols live. After that, it remaps ANSI SGR color codes to exact VGA values so the palette stops depending on terminal theme preferences.

decoder := charmap.CodePage437.NewDecoder()
utf8Text, err := decoder.String(string(rawArt))
if err != nil {
    return err
}

// ANSI SGR codes are converted to fixed VGA RGB values
// before writing to the terminal as true-color escapes.

That sequence matters because each step repairs a different kind of legacy mismatch. SAUCE tells you where the art ends. CP437 restores the characters. VGA remapping restores the color intent.

A close-up workbench shows a legacy ANSI file moving through three restoration stations: SAUCE inspection, CP437 translation, and VGA palette remapping. The final output is a clean terminal panel on the far right. The image explains that the tool is doing sequential compatibility repairs, not a simple file printout.
ansimotd is a translation chain, not a renderer in the loose sense.

The picker is smarter than random

ansimotd does not just grab any file and hope for the best. It checks terminal width, filters out non-art files, and looks for art that can actually fit the screen. That prevents ugly wrapping and keeps the login experience from breaking on a narrow terminal.

Selection behaviorWhy it mattersEffect
Width-aware filteringAvoids broken layoutsArt fits the terminal before it is shown
Non-art file exclusionScene packs contain extrasKeeps binaries and media out of the rotation
Shuffled choiceKeeps the output variedThe MOTD feels alive instead of repetitive

That is a small detail with a big product effect. The experience feels deliberate because the tool is making one more good decision on your behalf.

It is more polished than a script

The repository is organized like a real utility, not a weekend experiment. The code is split into clear packages for API access, rendering, SAUCE parsing, and selection logic. Packaging and release automation are in place too, which makes the project feel intended for distribution.

The result is a tiny tool with unusually disciplined engineering. Atomic writes, modular structure, and modern Go dependencies all support the same goal: make a fragile legacy experience feel reliable in contemporary environments.

It sits between nostalgia tools and archival tools

The nearest comparison is yuhonas/zsh-ansimotd, the precursor that helped define the category. ansimotd keeps the login nostalgia, but it adds stronger fidelity guarantees, shell agnosticism, and archive-aware rendering behavior.

ProjectStrengthTrade-off
ansimotdTrue-color VGA fidelity and SAUCE awarenessLess about theatrics, more about preservation
yuhonas/zsh-ansimotdClassic shell-native login feelMore shell-specific, less preservation-focused
ANSI screensaver toolsVisual playback and display appealNot built for login-time terminal output

That puts it in a narrow but meaningful lane. It is not the biggest or flashiest ANSI tool. It is the one most committed to making old art survive contact with new terminals.

The script converts standard ANSI color codes to 24-bit true-color escape sequences using the exact VGA RGB values, so art displays with accurate colors regardless of your terminal's color scheme.

Ben Word, Creator/Maintainer · retlehs/ansimotd Repository README

Why this tiny repo matters

The best frame for ansimotd is not novelty. It is respect. The project treats legacy digital art as something worth rendering faithfully, even when that requires extra work across encodings, metadata, and palette rules.

That attitude is rare and useful. A small CLI can still be a preservation tool, and ansimotd makes that case with a very specific kind of care.