Skip to content
Convert Images to ASCII Pictures
Branch: master
Clone or download
Latest commit 75fc331 Apr 17, 2019
Type Name Latest commit message Commit time
Failed to load latest commit information.
Asciify.psd1 Update version Apr 16, 2019
LICENSE Initial commit Apr 14, 2019


PowerShell Gallery Codacy Badge

Convert Images to ASCII Pictures



Convert any image to ASCII picture by representing each pixels grayscale value as an ASCII character. The higher the grayscale value resp. the lighter the pixel the more space the corresponding ASCII character fills on the screen therefore reassembling the image well on dark console backgrounds with light font colors. On light console backgrounds with dark font colors use the -Invert switch to adjust. Before being processed the image will be resized in memory to make the resulting ASCII picture fit the console's width later on. To fit the console's height instead use the -FitConsoleHeight switch. Otherwise, if you don't want the resulting ASCII picture's dimensions determined by the script automatically at all you can specify a custom width and height using the -Width and -Height parameters. This can be useful when exporting ASCII pictures of custom sizes into textfiles, e.g (Note: i2a is an alias for Convert-ImageToAscii):

gci .\bobby-fischer.jpg | i2a -Width 160 -Height 80 -Resolution Mid -Invert > .\bobby-fischer.txt

Note: -Width and -Height must be specified manually when running the Cmdlet from PowerShell hosts not reporting its console dimensions like PowerShell ISE.

Furthermore, the Cmdlet supports three different resolutions regarding the resulting ASCII picture. These are Low, Mid and High and can be specified by the -Resolution parameter. On higher resolutions the resulting ASCII picture will be made up with more ASCII characters yielding a more fine-grained picture. Depending on the image a higher resolution sometimes may tend to look better especially when using smaller font sizes or bigger dimensions.


Install from PowerShell Gallery

Install-Module -Name Asciify


Import-Module Asciify

Convert-ImageToAscii .\bobby-fischer.jpg


Get-Help Convert-ImageToAscii -Examples
You can’t perform that action at this time.