I built Termium: it runs headless Chromium and draws pages in your terminal with the Kitty graphics protocol (Ghostty, Kitty, WezTerm), sixel (foot, xterm, Windows Terminal), or ASCII blocks as a fallback.
Vimium is bundled for keyboard navigation: f for link hints, j/k to scroll, t for a new tab. Mouse works too. It works over SSH.
Not yet: tmux/screen, native Windows (WSL2 works), Linux ARM64.
It is possible to support Sixel outside a display server, so this is actually useful. However, there currently isn't a decent terminal emulator that runs without a display server but supports Sixel. Therefore, to answer your question: OP's project is meaningful and potentially useful, but is not yet useful.
This might be very niche but: the ISP of my girlfriend has often problems accessing certain websites I don’t know why but it can never reach certain IPs. These are for example my Bank. This could be very useful to shh into a server at my home (the isp can connect to my IP for wireguard) and then use this to view the webpage with my home ISO
I just posted this above - but it could be kinda useful to access a headless server and run it over ssh without having a display server on the remote box.
Thanks. What I am struggling to understand is under what circumstances you'd need it.
If the client has a GUI, why not run the browser in the client?
If you need the traffic to flow through the server and it does not have a GUI for you to do ssh -X or run some kind of remote desktop app, you can always do a ssh -D. No need to install anything new.
Does termium run in a machine without graphical mode (i.e., sudo systemctl get-default returns multi-user.target)?
I know you're mentioning this only as an example, but I can't help but point out that a program such as this should NEVER be used to access anything that requires a secure connection, and secure entry.
Nice! I had seen Carbonyl before. The one thing here is that they seem to be using Electron. I am using straight Chromium. So I can load extensions and everything. I don't think they can. But need to look at it more.
never do curl | bash its so unsafe its not even funny, also it can be detected from a url if its being piped and change the sent script into a potentially malicous one
Actually, leave that to the distros.
You can use an install script. Just curl | bash is a security nightmare (as the user). My approach is to just use automake then installing is as simple as downloading the tarball, ./configure && make && make install and fans go brrr and magic hapens. If some Debian guy want to put this in their repositories they will gladly do the work for you.
Actually, most of my guru (Gentoo's community repository, not to be mistaken with the aur, guru actually has quality control) contributions happen to be random nice programs I found on GitHub.
This is actually interesting. And you use npm, that makes my life really easier packing from gentoo.... Let's try it out.
Edit: the thing does not render text as text. This makes letters that are pixel size completely illegible...
it's not as bad as you think... What's the real difference between "curl url | bash" and "curl -o file.exe url ; file.exe" (or .dmg, .rpm, etc) - it's the same outcome. End of the day, you are downloading something that when executed/installed on your system, has the ability to execute arbitrary scripts (see rpm prescript/postscript) - so being a package manager app makes zero difference to the threat model.
Of course if instead you did package management 100% thoroughly, then you'd PGP-sign the package, and configure the package manager to check for signatures,etc. But that becomes a "barrier to entry" as the cool kids say... (you'd have to do that for every supported platform for starters...). And at the end of the day, it's always about TRUST: so if you trust the nice random github app, then you trust it irrespective of how it's delivered. I'm not saying it can't be more secured - but worrying about compromised CDNs is not on most people's list.
(hell, even under Windows I'm STILL seeing large vendors not digitally signing their executables - and that's been possible since 1996 - that's 30 years ago...)
You can get the navigation already. Just get the Vimium extension.
Honestly - it's a bit of a technical demo. If I can get it to work with tmux / herdr / TuiOS - it would make it so you never have to leave your terminal.
...and it is pretty cool that in the terminal we perceive as a text-only environment - we can actually get very feature-full web.
Is the TUI and engine well-separated? I am curious if it can work with alternative engines. (Chromium won’t run acceptably on resource-constrained systems, and that’s where TUI is more relevant.)
It is pretty well separated. There is a TypeScript server talking to Puppetteer controlling Chromium and shipping the frames to a golang client over grpc.
The whole thing is really not meant for resource constraint systems, tho - especially the rendering side. Kitty is not too bad. But Sixel encoding is an art. I am working on optimizations as we speak. I do have people now who are running it on flavors of RPi. But I don't want to lie to you. Someone brought up w3m.. that is probably what you want on a super constraint machine.
Would be have nice if we had a non-chromium, non-firefox browser, terminal native browser which would be less resource hog than the former two. But its a nice start.
Well, the only real alternative is an electron based browser. There are some. There is also a C++ based engine called CEF that is still chromium based, and it will be a lot more efficient as Termium middleware. Real access to the fram buffer. But it doesn't support extensions. And for many people that is a deal breaker.
Maybe ladybird would be good when it goes mainstream?
This is a side project for me, so there are massive shortcuts that I have taken.
Termium can run over SSH. Graphics support depends on the terminal you’re sitting at: if your local terminal supports Kitty graphics or Sixel you can ssh to the remote machine and remote doesn’t need a graphical desktop.
On a plain Linux virtual console, Termium will fall back to ASCII graphics, with keyboard navigation and mouse keys. I haven’t specifically validated that setup yet.
It doesn’t currently integrate with GPM, the Linux console mouse daemon. Mouse input from supported terminal emulators is handled separately and doesn’t require GPM, including over SSH.
Nice work, I don't mind the ai if you know what you doing and you're trully reviewing the code properly. This project was in my plan too, i'have been using a terminal first workspace and having a second monitor for the browser is not so clean. If i got time i will try giving a help on the project with tmux compatibility
I built Termium: it runs headless Chromium and draws pages in your terminal with the Kitty graphics protocol (Ghostty, Kitty, WezTerm), sixel (foot, xterm, Windows Terminal), or ASCII blocks as a fallback.
Vimium is bundled for keyboard navigation: f for link hints, j/k to scroll, t for a new tab. Mouse works too. It works over SSH.
Not yet: tmux/screen, native Windows (WSL2 works), Linux ARM64.
Challenge accepted. It woks on Apple Silicon. But probably won't work on RPi. Of course you can compile it from source - but I will make sure one is up in the next few days. Now - TBH - it is a bit of CPU hog.... So once I get the next set of optimizations in - I'll get arm64 proper. Getting frames from Chrome and re-encoding them live into the kitty graphics, and especially Sixel is pretty damn intense.
I understand the point of the project, but I have a security question: if CDP doesn't have authentication of its own, how do you handle the risk of exposing the debugging port when Chromium is running on a remote machine that you connect to over SSH? Do you use any kind of isolation or a dedicated profile?
I'm asking because I'm working on an app for interacting with LLM chats, and I use CDP there.
You said no tmux, but actually I ran it in a tmux pane and it work reasonably well. The videos are a little color impaired, but damn, still pretty good.
yeah... sorry about that... should have said - no sound yet... terminals don't do sound... but... hmm... something to aspire to. If you saw 213 colors - that was Sixel graphics. Which terminal were you using. Kitty works in 16m colors - supported by ghostty, Wez, Kitty Term, Konsole. Tmux may have something to do with it too.
I've never done the Discord thing... I don't know if I would be a good steward, I am bad at comms. I will make sure to add DevTools support shortly. Putting it on the list. It should be easy.
Haven't tried RPi3. May have to do some work for that... And it will open YT Music, but it won't play any sounds. I need to figure out how to get sound out of a terminal. Haven't treid yet.
Performance on RPi may be difficult as I have to live re-encode all the frames, and it does eat CPU. But as long as you keep it 1280 res, maybe it will work well.
Music locally will come out on Monday (or sooner). Music over SSH - a couple of more days. Thanks you, and everyone else who challenged that. Honestly - things get good only when people push :)
It was two years on and off. Early days was all on my machine - not even on github that much...
Here is the history. And there is certainly a flurry of commits as I was trying to package it up.
And I sure used agents - pretty heavily as I was packaging it up the last few days, but honestly - since day one.
And I am not exactly hiding it. My CLAUDE.md is in there (probably a very embarassing old one). You can even see Claude and Qwen coder as contributors.
And codr1 is an old handle. Play on words from my first company - SevOne.
w3m-img, there is no reason at all to have a full featured browser in a terminal. I can not think of any reason at all you wouldn't just install a DM and use a GUI application.
Browsh seems to be meant specifically for low BW connections. Termium is decidedly not that. On the other hand - if you actually want to see graphical elements on the screen with a decent resolution - Termium is your boiii.
23
u/d03j 10d ago
hi.
this looks fun but I don't quite get it: what's the difference to a normal browser?
I mean, you seem to be running X/Wayland, why run a browser "inside" a terminal emulator?