Hacker News new | ask | show | jobs
by acjohnson55 45 days ago
I've always been a bit mystified by the popularity of TUIs. To me, the power of the terminal is the streaming model. Composible utilities is something that is much less common in GUIs.

I get it that maybe the constraints of terminals force design of TUIs to be more focused on the purpose of the tool than polish, but it's not that compelling of a point to me.

11 comments

For some basic stuff like vim it works fine. But for almost everything else I'd rather a regular CLI tool or a web interface. I suspect a lot of the popularity comes from people who want to feel like a hacker using 10 terminal windows, but actually want a GUI like experience.
For me, TUIs compensate for the fact that I can't get good remote GUI rendering on Linux. Yes, X11 tunneling exists, but the experience has always been abysmal for me for anything not hosted on a machine that sits on the same LAN as the client. For Wayland I don't even know if such a thing is possible since I don't think the architecture supports it.

But the terminal is just fundamentally the wrong basic abstraction on which to build a structured GUI, it just happens to require few enough bits to be sent over the wire that it actually works reasonably well over SSH as opposed to pushing graphics.

> For Wayland I don't even know if such a thing is possible since I don't think the architecture supports it.

Not only forwarding is trivial with Wayland, it also tends to provide better experience than X11 does.

I have never tried it until now, and I hadn't looked into it. But I just tried `waypipe ssh` to a remote server I have for doing asynchronous Claude work in VMs, and it actually works pretty great! Maybe I'll switch to that for my emacs/magit setup, the lack of clipboard integration when running emacs in a terminal over ssh is enough of an argument for me.

Edit: yikes, pressing M-w caused emacs-pgtk to crash with a Wayland protocol error, so it isn't trivial and requires some configuring I guess.

Edit 2: Apparently I have to install wl-clipboard and write a bunch of emacs lisp to work around this. I don't think I have the patience for that, and I fear that such problems will be even harder to solve for applications which are not as flexible and programmable as emacs. So far I'll conclude that remote Wayland is not ready and stick to TUI.

Edit 3: No, the problem is probably mismatched waypipe versions on client and server. Still not fun.

> Yes, X11 tunneling exists, but the experience has always been abysmal for me for anything not hosted on a machine that sits on the same LAN as the client.

I have used X11 tunnelling to machines on the other side of Europe and it was OK. I did prefer ssh for responsiveness. What happened to NX? What about other remote desktops?

You can use Sunshine streaming on Wayland just fine. I have a headless sever with Sunshine and a Wayland desktop and can stream it remotely with great quality and minimal latency.

That said for most tasks I would still rather SSH in and use CLIs (not TUIs).

Obviously people want GUIs. That's why TUIs should be compared to GUIs, not to CLIs. TUIs are nice since you get a lot of the benefits of a GUI, without having to leave the context of the terminal.
I feel like the better solution here (than trying to shoehorn a GUI into an interface meant for text) is to make terminal windows graphically-aware, like how things work in Plan 9.
At that point what you want is just a tiling window manager rather than a terminal that supports GUIs.
I already do use tiling window managers and they don't really accomplish the “if you launch a graphical app in a terminal window it takes over that terminal window” flow. Closest I've found is Niri's support for tabbed windows, but even that's just sticking the graphical app window on top of the terminal window instead of the terminal window itself becoming the app window.
Depends, I'm building a markdown down editor that just previews in the web ui. However, I can use the web ui to do tasks like uploading files, view git commits etc. Different interfaces for different purposes. The CLI gives me focused mode, and then visual stuff that steal my time goes in the web
I dunno, pre-LLM TUI's at least tended to be okay, and keyboard navigation was a first class citizen. Besides, if you were using a TUI instead of a GUI then you basically always ended up saving memory/battery life, and TUI programs are generally more portable than trying to run some ancient GUI program.

I typically prefer CLI myself but having a TUI to manage torrents for instance was much more ergonomic.

A lot of the complaints in this thread seem like they're aimed more at recent vibecoded UIs than the concept of a TUI.

Like, okay, they are a big step back with accessibility, but they're flickering garbage because they were vibecoded in a weekend and the TS or Python library they're built on was similarly forced upon this world.

For almost every tui, a webui works better imo. Most torrent clients offer a web management ui and it's always going to be easier and more feature filled using a platform that was actually designed for it rather than hacking a gui in to the terminal.
Accessibility can also be much better in a web UI because the markup is more rigorously defined.

https://developer.mozilla.org/en-US/docs/Glossary/Accessibil...

Well, "better" is relative. Web UIs definitely have the advantage you are mentioning. However, they are also much slower to use, so it is a tradeoff.

I am blind and do rely on accessiblity. But I would choose a TUI over a Web UI every day simply because the web is slow as hell. Feels like running away from a "monster" in a dream. You have rich details, but you are being drowned in unnecessary verbosity and an inherently slow stack of tools working together.

The web might be accessible, but it is barely useable in practice.

That's interesting. Thanks for sharing.

I'm curious which screen reader you're using and what can be configured to fix that experience.

Vim is special because 99% of what we do is editing text, and it is the text editor—the importance of that task overcomes the poor discoverability of a TUI. Most other programs should be CLI, so they can fit in the conventional command line toolbox.
This. A lot of folks picked it up for that reason when they were young and now are terminal-all-the-things out of sheer inertia.
For the Claude Code / OpenCode / Crush / etc new wave TUIs, it's not about composability or text streaming. It's basically a combination of a few tailwinds:

1. There's already a large-ish community of engineers who live in the terminal e.g. Vim/Neovim/tmux/zellij/etc users. Lots of engineering tasks are accomplished by running scripts in a terminal, so it makes sense for some people to just move as much of their work there as possible. This means there's a set of users you can address with dev tools that run in a terminal.

2. Cross-platform distribution among the platforms most of those people care about — macOS and Linux — is largely a solved problem via package managers. Distributing cross-platform native apps is fragmented at best.

3. Building modern TUIs has become a lot easier thanks to the demand+distribution wins above: there's a lot of appetite for building blocks, and so lots of good options have flourished like Ink for React, Bubble Tea for Go, etc.

4. General developer distaste for the most straightforward analogue to all of this for desktop GUIs: Electron. Deservedly or not it's associated with slow, bloated applications. And if you don't use Electron, doing cross-platform anything is going to be a much harder problem than just pushing out a quick TUI app.

Eventually successful products seem to eventually jump the gap, like Claude Code eventually spawning Claude Cowork and OpenCode adding OpenCode Web. But it's easier and faster to test product market fit for dev tools with a TUI. And plenty of your users will stay there, even after you launch something else.

You can have more lightweight Web UIs if you just open a browser window instead of bundling the browser with your app as Electron does.
While I agree in principle (slack works just fine as a firefox tab, thank you very much), if the application needs filesystem access, it's not going to be viable.
Doesn't Tauri fix this?
These were using 66GB compared to what, few KB/MB In NCurses? I can run Nethack/Slashem under a 30 yeard of computer. React it's a joke, and there are ports of Ncurses to any OS.
Totally out of fashion today but think of TN3270. Rather than "streaming" they were forms based and heavily keyboard driven. This could easily be mimicked by a GUI but keyboard shortcuts has become an afterthought.

I still today meet users missing those old workflows. But they express it as "old text interface" aka TUI. If you listen to them you realize they mean blazing fast and shortcut driven. When you work with data entry you care about speed - not animations.

Any beginner likes eye candy. The veteran has stopped caring.

The command line shell has that benefit of piping text between programs. TUIs are runnable from the command line shell. -- So you can get many of the benefits of a GUI (e.g. discoverability) while sticking close to the terminal where you're doing things.

If you're going to "run command, edit command, run command", performing the edits from the terminal you're running the commands in seems reasonable/intuitive. (In contrast, for tools like VSCode, I think it's more common for terminals to take up a fraction of the screen space rather than switching it to full screen. And then developers will say they need a huge monitor).

It also seems to be that keyboard-driven programs are more commonly TUI than GUI. e.g. magit or lazygit. Or lazydocker. Or k9s.

1) TUIs work over ssh without any extra steps.

2) Constraints imposed by the terminal make all the apps look and work approximately the same - in the outside world the standards developed for UX are ignored as a matter of routine just because they can be. TUIs are in an optimum of least surprise, so to speak.

I like them because they’re easy to run in a container / sandbox.
They are very useful when working on remote servers, VMs and containers. Much much more convenient and robust than, say, X forwarding.
To me, the power of TUIs lies in a few places:

* Lower resource load * Less reliance on a mouse * Related: key bindings for more activities that fit my vi muscle memory * Deeper organization.

Thanks to TUI tools I've been able to roll my own IDE that's invisible when I need it to be (thanks guake & yakuake) and organized by project and tab (thanks zellij). For the mixed role I'm in that works perfectly.

I don't think anybody would look at what I have and call it polished though.

>I've always been a bit mystified by the popularity of TUIs. To me, the power of the terminal is the streaming model.

Ever used Emacs? Or Vim? Or Mutt? Or Borland's old IDEs?

The power of the terminal is also in ubiquitness, trivial connection to a remote system, and lack of mountains of GUI cruft, that a TUI app can as well have.

I've used Vim plenty for the past 30 years. I don't prefer it to GUI text editors.
Many of us however do.
My experience as a developer (with a preference for simplicity):

- CLI by default

- if I need a GUI, but no access to the local system: web

- if I need a (restricted) GUI with access to the local system: TUI

- else: either start a local web server, or, if nothing else works, go for a GUI toolkit

For me it’s mostly - the convenience of being in the terminal, where I live

- you can use em over ssh

- they’re typically made with keyboard usage in mind, which is often an afterthought in a typical browser based UI

- other GUI options are browser (sandboxes, obvi, not good for lil personal tools), native (not dead simple, compared to TUI/browser/electron), or something like electron (no way lmao)

I don’t seek out TUI’s instead of other solutions. But it’s so dang easy to pop open a new pane and run lazygit. And it makes you look really cool when people walk behind you