
OpenTUI
A TypeScript library for building terminal user interfaces, with a Zig core.
- Stars
- 13.7k
- Forks
- 799
- Licence
- MIT
- Language
- TypeScript
- Last update
- 4 days ago
- Type
- Library
What it is
OpenTUI is a library for building text-based interfaces that run in a terminal. You write the interface in TypeScript, directly or through React or Solid, and lay out boxes and text with flexbox. It includes selects, inputs, and scroll boxes with keyboard and mouse controls, and the README also mentions sound, images, and 3D graphics. The README states that OpenCode uses it in production.
- Build a terminal dashboard with boxes, text, and scroll areas laid out with flexbox
- Create a keyboard- and mouse-driven menu using select and input components
- Write a terminal app using React or Solid components instead of raw rendering code
- Add an SSH-served terminal interface using the @opentui/ssh package
Great for
- Developers building terminal applications in TypeScript
- React developers who want to build terminal interfaces with a familiar component model
- Solid developers who want a terminal renderer for Solid
- Teams building interactive command-line tools that need mouse and keyboard controls
Not ideal for
- People who only need a simple one-off command-line script, since the library adds a rendering layer to learn
- Anyone who needs a graphical desktop or web interface rather than a terminal one
- Developers who cannot use Bun and Zig for the development workflow the README describes
How to get it
- 1
Install with a package manager
You'll need: Bun 1.4.1 or later · Zig 0.16.0
Install dependencies from the repository root
bun install - 2
Run it
- Clone the repository from https://github.com/anomalyco/opentui
- Install dependencies with bun install
- Open the documentation at https://opentui.com/docs
- Run an example from the packages/examples workspace
- 3
Get the most out of it
- Use the React or Solid renderer if you already know those frameworks
- Install the OpenTUI documentation as an AI agent skill with npx skills add https://opentui.com --skill opentui
- Use the @opentui/keymap package for key binding and command routing
- Use the @opentui/ssh package to serve an OpenTUI app over SSH
Downloads
Strengths
- Lets you write terminal interfaces in TypeScript, with optional React or Solid renderers
- Offers a flexbox layout model and built-in interactive components with keyboard and mouse support
- Is MIT licensed and has a large star count and an active repository
Trade-offs
- The README does not give a detailed beginner tutorial, so setup may take some exploration
- Development requires Bun 1.4.1 or later and Zig 0.16.0, which adds toolchain requirements
- The README is truncated and does not fully document the feature set or platform support
How it compares
| Project | Stars | Type | Level | Updated | Best for |
|---|---|---|---|---|---|
| opentui (this) | 13.7k | Library | intermediate | 4 days ago | Developers building terminal applications in TypeScript |
| ink | 40.2k | Library | intermediate | 5 days ago | JavaScript or TypeScript developers who already know React |
| bubbletea | 45.6k | Library | intermediate | 4 days ago | Go developers who want to build interactive command-line tools with a visual interface |
| textual | 37.6k | Framework | beginner | 27 days ago | Python developers who want a terminal app with buttons, tables and forms |
| ratatui | 23.1k | Library | intermediate | 5 days ago | Rust developers building interactive command-line tools or dashboards |
| lipgloss | 12k | Library | intermediate | 4 days ago | Go developers building terminal user interfaces |
Stats synced from GitHub. The assessment above was drafted with AI from the project's README on 2026-10-29 and may miss recent changes — check the README before relying on a command. MIT licence: free to use, modify and distribute, including commercially, as long as you keep the copyright notice.