Rendering images as text

Text Art

© Lead Image © anan punyod,

© Lead Image © anan punyod,

Article from Issue 245/2021
Author(s): , Author(s):

If you need to display an image in the terminal or as plain HTML, a variety of smart tools can help with the conversion.

Thanks to increasingly sophisticated technology, displaying high-resolution images on screen is no longer a difficult task. However, these more detailed images (with a combination of greater image size, resolution, and color depth) come at a cost, consuming more storage space and taking longer to download from remote sources, such as web browsers and webcams.

Sometimes you just need an image to display quickly. You can save time and bandwidth by displaying images at a lower resolution and color depth as text (ASCII or Unicode characters) directly in the terminal and converting them with American National Standards (ANSI) color codes [1]. You can also convert the images to plain HTML and CSS and embed the results in a web page. Some text browsers, such as ELinks, then display these images directly in the accessed web page. In a similar manner, the Browsh [2] browser does this internally and can also render images as text.

In this article, we will discuss the available tools for converting images to text and explore whether this approach is suitable for everyday use. This article follows up on a previously published article [3] that dealt with tools for creating ASCII art.


Use Express-Checkout link below to read the full article (PDF).

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • ASCII Art

    Creating images from letters and numbers is a complex matter, unless you have the right tools at hand.

  • Command Line

    This month, we’ll show you how to decorate your console and give it a fresh new look by adding color to the command line with ANSI escape sequences.

  • Harness the Web from the Command Line

    Not only is it possible to browse the web from the CLI, it's mightily useful, too, as we demonstrate in this article.

  • CLI Image Processing

    Powerful command-line tools offer fast and easy image editing.

  • ImageMagick

    GIMP isn’t the only option for photo manipulation. ImageMagick, a collection of command-line programs for image processing, can help you process multiple images in one go.

comments powered by Disqus

Direct Download

Read full article as PDF:

Price $2.95