explaingit

source-foundry/hack

17,237ShellAudience · developerComplexity · 1/5Setup · easy

TLDR

Hack is a free, open-source monospaced font designed for code editors and terminals, tuned for legibility at small sizes with four weights, broad character set support, and Powerline glyphs built in.

Mindmap

mindmap
  root((hack))
    What it does
      Monospaced font
      Code editor typeface
      Web font files
    Features
      Four styles
      Powerline glyphs
      Multi-charset support
    Use Cases
      Editor font
      Terminal font
      Website code blocks
    Audience
      Developers
      Designers
      Web builders
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Install a clean, readable monospaced font in VS Code, Vim, or any code editor for all-day coding sessions

USE CASE 2

Use the woff2 web font files to display code blocks in a consistent developer-friendly typeface on a website

USE CASE 3

Get Powerline glyph support in a terminal prompt without needing to patch the font separately

USE CASE 4

Replace the system monospace font on Linux, macOS, or Windows with a purpose-built coding typeface via the package manager

Tech stack

Shell

Getting it running

Difficulty · easy Time to first run · 5min

In plain English

Hack is a free typeface designed specifically for reading and writing source code. A typeface is the family of letter shapes you see on screen, this one is monospaced, meaning every character takes up the same horizontal space, which keeps columns of code lined up neatly. Hack builds on the older free typefaces Bitstream Vera and DejaVu, and tunes the letter shapes for the small text sizes commonly used in code editors, roughly 8 to 14 points. The aim is letters that stay legible and easy to tell apart when you are staring at code all day. The download includes Regular, Bold, Italic and Bold Italic styles, supports the ASCII, Latin-1, Latin Extended A, Greek and Cyrillic character sets, and includes Powerline glyphs by default for command-line prompts that draw arrow shapes. Installation is platform-specific: on Linux you copy the font files into a system or user font folder and refresh the font cache, on macOS you double-click the extracted files, on Windows the maintainers provide a dedicated installer that handles font-update quirks. The font is also available through many package managers across Arch, Debian, Ubuntu, Fedora, Homebrew, Chocolatey and others. For websites, Hack ships as woff and woff2 web-font files served through the jsDelivr and cdnjs CDNs, so you can drop it into a page with one stylesheet link and a CSS font-family rule. Someone would actually use this if they want a clean, free, open-source font for their code editor, terminal, or a website that displays code blocks. There is also a companion repository called alt-hack with alternate glyph styles for users who want to tweak specific characters. The full README is longer than what was provided.

Copy-paste prompts

Prompt 1
Help me install the Hack font on Ubuntu via the package manager and set it as the default monospace font in VS Code.
Prompt 2
Add the Hack web font to my documentation site using the jsDelivr CDN link and set it as the code block typeface in CSS.
Prompt 3
Set up the Hack font in my Alacritty terminal config on macOS with size 13 and the Bold Italic variant enabled.
Prompt 4
Show me how to use the Hack woff2 files locally in a Docusaurus site so code blocks render in Hack without a CDN dependency.
Open on GitHub → Explain another repo

← source-foundry on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.