gitmyhub

ghostty

Zig ★ 58k updated 7h ago

👻 Ghostty is a fast, feature-rich, and cross-platform terminal emulator that uses platform-native UI and GPU acceleration.

A fast, feature-rich terminal emulator for macOS and Linux that feels native to your platform, with GPU rendering and modern terminal features like image support.

ZigSwiftCGTKMetalOpenGLCoreTextsetup: hardcomplexity 4/5

Ghostty is a terminal emulator, which is the application you use to interact with a command-line shell on your computer. Most developers use a terminal every day, and Ghostty positions itself against the observation that existing terminals force a trade-off between performance, feature richness, and native platform integration. Ghostty aims to provide all three without compromise.

On macOS, the application is built as a proper native SwiftUI app with real menus, a settings interface, AppleScript support, and Metal-based GPU rendering using CoreText for fonts, making it feel indistinguishable from a Mac-native application. On Linux, it is built with GTK and integrates with systemd. Under the hood, the rendering engine uses OpenGL on Linux and Metal on macOS, with a multi-threaded architecture that dedicates separate threads to reading, writing, and rendering. The terminal parser is heavily optimized using CPU-specific SIMD instructions (specialized instructions that process multiple data items in parallel). Ghostty also supports a wide range of modern terminal features beyond what most terminals implement, including the Kitty graphics protocol for displaying images in the terminal.

In addition to the standalone application, Ghostty exposes its core as a C-compatible library called libghostty that any application can embed to add a terminal component. You would use Ghostty if you want a terminal that is fast, supports modern terminal features, and feels like a native application on your platform rather than a generic cross-platform wrapper. The project is written in Zig, a systems programming language, with platform-native layers in Swift (macOS) and C (Linux bindings).

Where it fits