SwiftTerm is a terminal emulator library written in Swift by Miguel de Icaza. A terminal emulator is the part of a program that reads the text and escape sequences (control codes for color, cursor movement and screen layout) that command-line programs write, and draws the result on screen. SwiftTerm emulates the VT100 and xterm terminals.
The repository holds a terminal engine that does not depend on any user interface, plus ready-made views for macOS (AppKit) and iOS (UIKit). An app connects the engine to a local process, such as a shell, or to an SSH connection to a remote computer. It supports Unicode and emoji, right-to-left text, ANSI, 256-color and TrueColor output, mouse events, hyperlinks, search, and images in the Sixel, iTerm2 and Kitty graphics formats, with optional GPU rendering through Metal. There is also a headless core for Embedded Swift and a WebAssembly build for browsers and Node.js. Commercial SSH clients such as Secure Shellfish and La Terminal use it.
It is free and open source under the MIT license, published as source code on GitHub.