asciify --color ansi > art.ans
ANSI art generator: colored text art for your terminal
Turn any image into ANSI art: text characters wrapped in 24-bit color escape codes that your terminal paints in full color. Make a login banner, a shell greeting or a colorful logo for your CLI.
░░░░ ░▒▓▓▓▓▓▓▒▒░░ ░▓█████▓▓▓▓▒▒▒░ ▓█████▓▓▓▓▒▒▒▒░░ ░▓▓▓▓▓▓▓▓▓▒▒▒▒░░░ ░▒▓▓▓▓▓▒▒▒▒▒▒░░░░ ▒▒▒▒▒▒▒▒▒▒░░░░░░ ░░▒▒░░░░░░░░░ ░░░░░░░░░
What ANSI art is
ANSI art is text art colored with escape sequences, the control codes defined by the ANSI X3.64 and ECMA-48 standards. A sequence such as ESC[38;2;255;176;0m tells the terminal to draw the following characters in amber, and ESC[0m resets it. The form grew up on 1990s bulletin board systems, where art groups drew logos with 16 colors and block characters. Today almost every terminal supports 24-bit truecolor, so an image can be reproduced with its real colors.
How asciify.art builds it
The converter samples the image, picks a character for each cell from the charset you choose (block shading and half blocks give the richest result) and records the average color of the pixels behind it. With the color mode set to ANSI, Copy puts the text on your clipboard with a truecolor code in front of each color change, and a reset at the end of every line so your prompt never inherits a color.
How to show it in your terminal
Pasting escape codes straight into a shell prompt does not work, because the terminal treats them as key presses. Save them to a file and print the file instead:
- Copy the art from the generator with the color mode set to ANSI.
- Save the clipboard:
pbpaste > art.anson macOS,wl-paste > art.ansorxclip -o -sel clip > art.anson Linux. - Run
cat art.ans. Add that line to~/.bashrcor~/.zshrcfor a greeting on every new shell, or copy the file to/etc/motdfor an SSH login banner.
Frequently asked questions
- Why do I see codes like [38;2;255;176;0m instead of colors?
- The program showing the text does not interpret ANSI escapes. Editors, chat apps and most web pages print them literally. Display the file with cat in a terminal, or export HTML or PNG for places that cannot render escape codes.
- Truecolor or 256 colors?
- Truecolor (24-bit) keeps the exact colors of the image and works in modern terminals such as Windows Terminal, iTerm2, kitty, WezTerm, Alacritty and GNOME Terminal. Some older terminals only understand the 256-color palette and approximate or ignore truecolor codes.
- Is this the same as 1990s BBS ANSI art?
- It uses the same idea, color escape codes around text characters, but with 16 million colors instead of the 16 colors of DOS-era ANSI and Unicode characters instead of code page 437.