r/PowerShell • • Feb 10 '26

PSMUX: Native tmux for PowerShell — split panes, sessions, detach/attach — no WSL needed

For anyone who's wanted tmux functionality in PowerShell without installing WSL:

psmux is a native Windows terminal multiplexer that works exactly like tmux. Same commands, same keybindings, zero learning curve if you already know tmux.

Why this exists:

  • Needed tmux-style session management on Windows servers
  • Didn't want WSL overhead just for terminal multiplexing
  • Wanted to SSH into Windows boxes and still have pane splitting

Quick install:

winget install psmux

or

cargo install psmux

Or: scoop install psmux | choco install psmux

What you get:

  • Ctrl+b % — split horizontal | Ctrl+b " — split vertical
  • Ctrl+b d — detach session | psmux attach — reattach
  • psmux ls — list sessions
  • psmux new-session -s work — named sessions
  • Mouse support for pane resizing
  • Copy mode with vim keybindings
  • Scriptable (send-keys, capture-pane, etc.)

The tmux command alias is included, so your muscle memory works.

Just⭐the repo if you like it and feel free to raise any issues

Repo: https://github.com/psmux/psmux

Developed and actively maintained with LOTs of ❤️ for Powershell

Anyone using terminal multiplexing on Windows? What's your current setup?

24 Upvotes

61 comments sorted by

View all comments

Show parent comment

2

u/dodexahedron Apr 04 '26 edited Apr 04 '26

Well, it does, in combination with pwsh.

It's just a different separation than you're used to, and partially inverted if you're comparing to the terminal + bash + tmux model, where bash is the shell and only a shell, tmux is a windowing and session multiplexer, and the terminal is just a host for it all, sometimes with extra features.

So, first, remember that wt and powershell are completely independent things. WT is a terminal emulator with windowing, tabs, panes, layouts, etc., much like konsole.

Powershell is, all at once, almost an entire text/object mode operating system/virtual environment, combining a full CLR implementation, a shell, and a session, job, task, and event manager.

The beauty of it is that you can still use it like the old way, and that's perfectly fine. Or you can use shims to make it feel like you're used to (like psmux), which is also perfectly cool. Or you can do it the native way, which is simply different.

If all you do is treat pwsh as a replacement for bash in the same hierarchy, then yeah - it doesn't do what you want, because you're using it as only a shell.

So instead of konsole (or just a raw vt) hosting bash, which is hosting tmux, which is hosting multiple bash instances, you instead can have wt hosting multiple ps instances. Done.

If things like psmux - whether they also embrace that paradigm or just treat pwsh as a drop-in for another shell - make your life even a teensy bit better, then awesome! I'm not gonna yuk your yum. But any assertion that the built-in tools with wt + pwsh can't replicate bash + tmux + bash + pwsh (or other arrangements) are simply a product of lack of exposure to what it can very intentionally do (as in not just because it's Turing complete or something like that - actual targeted features for real use cases, just from a fresh PoV).

What things like psmux could bring to the table that I'd love to see is easing the integration of other stuff, like ssh multiplexing, marrying that with everything else. That's something that tmux doesn't do and that otherwise requires the use of either configuration of ssh (which is simple but not default, nor documented terribly well) or command line parameters to ssh (or pwsh, since it passes it through) and consistent usage of them to achieve, no matter the shell.

I'd love it if tmux, psmux, and/or pwsh itself, in addition to what they already do on the remote end, also paid attention from the client side of things when ssh is involved and opportunistically used things which already exist. Again using ssh multiplexing as the example, pretty simple use of that can enable a lot more than just multiple consoles on that one socket (think x, rdp, nfs/cifs/etc mounts, remote UDS use, and more, and all without port forwarding), but it just goes unused by default. Exposing THAT kind of functionality with simple key binds rather than manual commands and configuration or using that multiplexing to keep the client up to date on all windows in the session, rather than only the visible ones in the active screen buffer, would be awesome and a marked advancement over the status quo.

1

u/uniquerunner Apr 04 '26

PSMUX supports SSH Multiplexing

Yes Ofcourse, It does exactly what you need. Psmux supports creating multiple sessions over ssh, detaching and attaching even if you disconnect, reconnect and come back.

Server Side possible?

I am able to use Windows 11 remotely via ssh, run multiple psmux sessions, disconnect ssh, reconnect ssh, come back and attach to it.

If you mean using multiple ssh sessions on the client side, that is also possible.

Whatever you're saying is part of Psmux. That's what I have been working hard to bring to Windows for the past 90+ days!

Client side possible?

Ofcourse! one command

bind-key C new-window "ssh user@yourserver.example.com"

Tell me a specific scenario if you're working with any specific tool and I will try to provide you a solution to your problem using PSMUX. I am confident because I have developed it from the ground up. It's based on over 20+ years of my experience in using Linux and Windows. I've used shells and Powershell definitely is unique and valuable which obviously led me in this path to support Windows Powershell exclusively.

Note that PSMUX is for Windows. It's not crossplatform , not for Linux. That part is already taken care of by Tmux, the inspiration to create this.

1

u/Eddyi0202 Apr 04 '26

Yeah, I don't argue about powershell well..power and I admit that I feel that using is just as a shell feels wasteful but the issue is that that basically there is no real alternative on windows. Cmd, git bash, cmder and other things are limited. 

There is nushell which embrace similar concept of treating command output as objects as opposed to just text but it's relatively new. 

I get that WT is not tied in any way to pwsh, I use it with WSL a lot and must say that it's currently the best terminal emulator for windows. 

As for sessions, I only use them on my local machine, no remote ones. Maybe I am missing something but AFAIU from your answer it's still not possible to replicate tmux workflow with just pwsh(any other shell) + WT since WT does not support such concept as workspace/session (meaning a group of tabs/windows tied together) and ability to switch between them. 

One way would be to utilize window manager/virtual desktops altough it's not very efficient. 

Kinda off-topic but I guess agentic AI workflows might motivate terminal emulator creators to implement such concept since it's very usefull for organizing parallel work. 

2

u/uniquerunner Apr 04 '26

Claude Code Agent Teams works fantastically on Windows because of PSMUX!

Quite a few projects on github use PSMUX for Agentic use.

1

u/Eddyi0202 Apr 04 '26

Btw what's your goal with this project long term?
Are you going to just keep in sync with upstream or it will diverge in terms of features?

2

u/uniquerunner Apr 04 '26

It's aimed to only bringing Tmux on Windows. I think Tmux was a missing piece. I myself needed Tmux so badly on Windows and that's how this came about.

This project is limited to scope to only that. Slight corners maybe a bit better here and there, for example mouse support by default, the popup view for switching panes,etc Tmux in Linux needs a plugin to enable mouse support.

But, overall, it's aimed at making the existing Tmux cross platform by implementing an exact clone with different technologies for Windows. This doesn't use any part of the original Tmux source. It rebuilds everything again in Rust from the foundation all the way up.

Non Tmux features is left to Plugin creators and others who make use of Tmux/Psmux or create plugins for it.