Native Instant Space Switching on macOS

616 points296 commentsa day ago
aylmao

I grew up with this animation so I didn't consider it annoying until I bought a new Macbook a couple years ago.

I noticed sometimes I would press keyboard shortcuts before my system's focus had switched. Just little stumbles here and there, some inoffensive, some annoying, but who knows maybe I didn't catch enough sleep.

Over time it happened often enough that I decided to google it, and it turns out my muscle memory wasn't failing me; the animation speed did change ever so slightly and was slower in new Macs with 120Hz displays [1][2] (newer MacBooks, 2021+). If you switch your screen to 60Hz it goes back to the faster animation.

Why is this animation slower now, and why does it depend on screen refresh rate? I have some technical theories but can't think of an organizational reason it happened and hasn't been fixed 5 years later at a 3.82 trillion market cap company. If you Google it there's plenty of discussions online about this. It's noticeable and annoying to people who have used the feature often enough.

[1]: https://discussions.apple.com/thread/256124324?sortBy=rank

[2]: https://www.youtube.com/watch?v=gNBWt4NvqHg

show comments
godelski

I think Apple is making a really fatal flaw. Tbh Microsoft is doing it too.

Design good interfaces, with sane defaults but do not handcuff power users!!!

I often hear people say no one should care because there aren't many power users. They're a small portion, but that's absurd framing. They matter a lot because they're the ones that push your design language, develop new ideas, influence the general community, build new programs, find your bugs, and all of that. Apple and Microsoft are closing the ecosystems to get more control not only to exploit the users more (scrape their data) but to reduce bugs and things. But more and more people are trying these random programs because they can't figure out how to do things the right way. It's exactly why people are getting more frustrated with computers. The general public still doesn't care about data harvesting but they do care that the restrictions are handcuffing them now.

Funny enough this is also why Linux is becoming more popular. You've always had complete control but in the last 5 years the barrier to entry has plummeted. It's still not right for the average joe but it's on its way and a few more specialty distros are already there (e.g. steamos). The irony is Apple had the right idea before, even if not as modifiable as Linux, it used to be easier. But now it's more like a power trip. Consolidating control because they don't know what else to do

show comments
xz18r

I see yabai mentioned, definitely check out Aerospace. Ive tried multiple WMs after years of i3 on Linux and this is the best one I found (for me) with quite a margin. It just works (tm)

https://github.com/nikitabobko/AeroSpace

show comments
Eric_WVGG

> Pay for a license for BetterTouchTool. Enable “Move Right Space (Without Animation)” and “Move Left Space (Without Animation)”. > I managed to find [another solution] with none of the aforementioned drawbacks.

I don’t consider paying for quality software a drawback!

I’ve been using BetterTouchTool ever since the 2016 Macbook Pro with Touch Bar, so I guess that’s a decade now. It turned the Touch Bar into the best productivity enhancement I’ve ever experienced from a laptop, and evolved to suit even more use cases beyond the Touch Bar.

I consider it completely indispensable, and I doubt it would still be in (very) active development today if fans like me weren’t paying for it.

tptacek

God damnit I didn't know until 15 seconds ago that the Space-switching animation in macOS was annoying. Thanks a lot!

show comments
Cider9986

I switched to Fedora Asahi Remix[1] after being affected by this bug[2] after 5 releases of MacOS Tahoe. I am enjoying Asahi Remix with Gnome and it has sensicle window management.

[1] https://asahilinux.org/fedora/ [2] https://youtube.com/watch?v=JjptYWKGVc4

show comments
Nevermark

Tangentially related.

After a restart, and after Finder has opened multi-tab windows I have open before, clicking on a tab can suddenly move my view and the window to another space.

Apparently different tabs in the same window can think they belong to different spaces.

Something (I perceive as) common to a lot of the (perceived) increase in Apple software glitches recently, is I cannot fathom the logic for which the bug makes any sense. It does not feel like I am seeing corner case bugs, but instead major "bad-model" code, revealing its poor design.

cosmic_cheese

Clever hack. Now if there were some way to bring back the OS X 10.5/10.6 2D spaces grid… the linear design in place since 10.7 has always felt overly simplistic.

show comments
phren0logy

Having been ruined by Linux options like Hyperland and Niri, I’m digging my early foray into OmniWM - https://github.com/BarutSRB/OmniWM

show comments
buster

I recently had to switch to macos for work and Jesus Christ is this not the pinnacle of engineering. Sure, I'm accustomed to my self configured Linux desktop but boy is Mac OS slow to use and hard to configure. And so keyboard unfriendly.

tern

I did an exhaustive comparison of window managers and settled on using Raycast for simple resizing (full screen, center, mid-size centered, 1/2, 1/3, 2/3 left/right) + FlashSpace[1], which implements simple virtual spaces with instant switching.

You can also use Rectangle or Spectacle or others in place of Raycast.

Foolproof with zero magic.

[1] https://github.com/wojciech-kulik/FlashSpace

show comments
aequitas

Wonderful, that leaves 2 things on the top of my list for spaces: having to hover your mouse over the top left corner of a space and waiting until it shows the closing icon. And Safari deciding its better to switch to a space and open a window that was minimised there instead of just opening a new window in the space i'm currently in (even with the "switch to a space" setting turned off!) when 1 want to open a new tab.

show comments
flawn

Hey! I built InstantSpaces (which you had linked in the footnotes) and am well aware of issues with the injection & patching. It works 90% of the time for me and was good enough for me to share. But there are cases where it bugs. And yes, Tahoe is a to-do.

I will hopefully soon have the time to try to make it more robust. Feel free to take a shot at it if you want!

show comments
bfirsh

Here's a script to install and configure, in case it's helpful for anyone's dotfiles: https://github.com/bfirsh/dotfiles/blob/48eff70daa754216eff9...

modeless

This is nice. Sounds like it wouldn't solve the slow animation when entering or leaving full screen mode though. I'm fed up enough with macOS's poor window management (among many other things) that I'm looking for MacBook alternatives.

The M5 chip is way ahead of Intel's latest, even Panther Lake. But the Snapdragon X2 Elite looks like a viable alternative. It's the only competitor with comparable single core performance, and it comes with 48 GB of extremely fast RAM for a reasonable price with great battery life. Unfortunately Linux support isn't really there yet, but hey M5 MacBooks don't support Linux well either.

show comments
nicoburns

I'm still incredibly frustrated by Apple's Mission Control and Full Screen features. The old Expose and Spaces and windows-style maximise would be so much better.

show comments
jjcosgrove

[video]

just sharing for sh*ts n' giggles... inspired by this post and a previous annoyance i had around spaces in general... i just 'vibe coded' (don't start) this using codex this morning (built upon InstantSpaceSwitcher's UI)

https://www.jjcosgrove.com/assets/videos/spaced.mp4

basically:

- you can set custom names per space

- you can hotkey-navigate to each space/any space

- it has a visual indicator in menubar (active/vs inactive in case you use mission control)

- you can show a nice grid overlay (to click or arrow-nav to a space)

- it has unified shortcut/name management via UI (rather than needing a seperate util)

names are retained on restarts, spaces are synced if mission control creates any (as best as you can with mac's private apis).

for personal utilities like this, it works quite well and sometimes its good to just have 'fun'

oh and the 'jank' relates to how spaces works (i think), but can be removed/avoided by enabling 'reduce motion' which i think the original post mentions.

tnightengale

Stop using MacOS spaces. Never full screen anything. Throw everything around with hotkeys using OSS rectangle. Use shortcat to automatically bring your cursor to anything on your screen and use enter to click and type.

show comments
modernerd

> Pay for a license for BetterTouchTool. Enable “Move Right Space (Without Animation)” and “Move Left Space (Without Animation)”.

I did not know BTT supported this until today!

You can just set up the trackpad 4-finger swipe actions globally: https://cleanshot.com/share/P0K1PGC1

Then in System Settings set "swipe between full-screen applications" to "off" in Trackpad settings under "more gestures" so that BTT's shortcut applies instead of the system-level one.

Works well. No extra software needed if you already have BTT, which is worth the money for me purely for "alt+drag a window from anywhere" style window movement. That setting is buried deep under BetterTouchTool Settings → Window Snapping & Moving → Moving & Resizing Modifier Keys: https://cleanshot.com/share/mnF9xBkW

show comments
benji-york

By way of experience report: I've been using this app for a week or so on my daily driver and it's been great.

mabedan

Is there a tool which eliminates the animation, also when switching between apps with cmd+tab? I almost never use ctrl+→, I just know what application I want to switch to.

All these apps that I tried only fix the ctrl+→, but not application switching

albertjs

I've been using option 1 (reduced motion) since I got my first MacBook years ago. Trying to fix the browser issue you mentioned is how I discovered Chrome flags. I now `open` chrome with the `--force-prefers-no-reduced-motion` flag.

This looks great though, will give it a go!

primaprashant

I love using (tiling) window managers, and one of the most important requirements for me is having a key binding for switching to the last active workspace. The proposed solution in the blog doesn't achieve this. I use Aerospace on macOS right now and think it's the best solution available.

I generally have fixed workspaces for different things: first for a browser, second for a code editor, third for a terminal, and so on. If I want to switch between the browser and code editor, I can do that with a single key binding, usually Alt+Tab. The same binding lets me switch between the code editor and terminal just as easily.

When you have something like 10 different workspaces, not having this key binding becomes annoying. If you need to alternate between windows on workspace one and workspace eight, you're stuck using both hands to press Control+1 and then Control+8. But with a last-active-workspace key binding, you can just Alt+Tab between them. This is the killer feature I always need.

show comments
jzer0cool

Slightly off topic, how does one learn to start customizing their mac like this - 1 simple example for any customizing. Thanks!

skupig

You can use yabai without any of the tiling functionality (set the default mode to "float"), I have actually been using it with BTT to fix this exact problem. Thanks for letting me know that a fix has been added directly to BTT though!

ivanjermakov

Amazing how much effort is needed from a billion dollar company to make a feature present in my 1kLOC window manager.

mintplant

Awesome! Is there a working way to do the same for Windows virtual desktops? I remember I used to do it with ViVeTool [0], but Microsoft removed the feature flag at some point.

[0] https://github.com/thebookisclosed/ViVe

show comments
gejose

⬆ Huge upvote for this find as I've been looking for a way to do this recently.

I tried the yabai + skhd recently, but I didn't like that I had to disable System Integrity Protection.

Fraterkes

I'm new to MacOS, is the thing they're refering to when you swipe left/right with three fingers to switch between different fullscreen apps / desktops? I kinda like the animation, after decades of windows I'm still impressed when switching between programs isn't stuttery.

show comments
aesopturtle

This is one of those classic examples of software feeling ‘heavy’ for reasons that have nothing to do with hardware limits. People often talk about performance in terms of benchmarks, but interface latency on routine actions probably matters more to happiness than a lot of headline metrics. Nice work.

littlecranky67

The animation has bugged me for years! Thanks to the blog post, I found out that BetterTouchTool - which I am already using - has this feature since a couple of versions and now I could enable it. Wasn't aware of that, sometimes the solution is so easy.

ray__

This looks interesting and I will give it a try. I agree that the space-switching animation is painful.

I don't however think that this will solve spaces on MacOS, for the simple reason that opening new instances of apps is inconsistent and often doesn't behave how you'd expect it to once one more than one space is involved (in my experience, anecdotal).

I've come to peace with the fact that I will never be able to simultaneously experience the productivity of i3 and the necessary evil of MS Office/Illustrator on the same OS. The most important factor in my work is who I work with (rather than what I work with) so I'll remain on the latter train for now.

show comments
joeevans1000

I struggled with the same annoyances for years. Then I installed TotalSpaces... but I think that stopped working. Liquid Ass destroyed my iphone and apple watch and I was able, thank god, to stop it from infecting my MacBook. At the cost of the newest updates.

Apple. You suck.

DDayMace

I much prefer gnome for multiple desktop switching and app switching in general. Seeing this article I know there are many on macos who agree!

keerthiko

I'm not a big space-switcher on OSX, mostly because each of my applications come with spaces (browser, IDE, etc), but unskippable UI animations are an instant roadblock.

Looks like HN hug of death killed your comments section though:

> An error occurred: API rate limit already exceeded for installation ID 65180581.

msephton

Synthesizing a really fast swipe to remove the transition is absolutely genius.

gechr

Nice. I wrote a little menubar app and Space switching has been a thorn in my side, including going down the "Yabai integration" route. Will have to take a look at this and see if I can borrow some ideas!

Shameless plug: https://github.com/gechr/WhichSpace

rendx

I didn't check if it makes any difference, but I see hardly any animation with “Reduce motion” enabled.

The article mentions this has the unfortunate side effect of also setting prefers-reduced-motion in browsers, but that can be mitigated by changing the browser settings (Firefox: about:config: ui.prefersReducedMotion. 0 (enable) or 1 (disable)).

__mharrison__

Kudos for the crazy hack (fast swipe). I'm in the aerospace crowd...

isodev

> Apple has continuously ignored requests

Apple being completely oblivious to what normal people actually need or want is like bad weather- can’t do anything about it (Apple is so big and unregulated), just try not to forget to take an umbrella.

show comments
nu11ptr

Interesting. It doesn't bother me at all, but the animation on Windows 11 to switch spaces feels very unsmooth to me and drives me crazy. Here I was wishing it was like the one on macOS.

show comments
itubaj

The thing that most bothers me is that there seems to not exist a good solution for spaces that allows a grid set of spaces, like the one you can configure on Linux Gnome DE. That thing was so useful...

show comments
zlies

Honestly, this animation in one of the best things about spaces in macOS. I use the four finger gesture to switch spaces all the time and it make the spaces feature so much more natural than all other window managers I’ve used before

show comments
hmokiguess

Can you use this with the trackpad gesture though? That's the only thing that has me locked in, the muscle memory of trackpad is hard to beat for me and unfortunately I rather suffer through the animation then move to the keyboard

show comments
juggy69

I can't figure out how to install this. After doing ./build.sh what do I do next??

show comments
tnightengale

The giga brain move is to stop using MacOS spaces. Never full screen anything. Use an OSS window management tool like `rectangle` (similar to deprecated `spectacles`).

Use shortcat to bring your cursor to any element with just typing.

4jck

does Aerospace still require disabling SIP? kind of needed as my mac is a work laptop.

I would appreciate if anyone has i3/sway keybindings that work alongside this, otherwise I might just vibecode something in Swift. I know that there is some window management keybinds within System Settings, maybe I need to look into that also, but I don't think they'll behave the way I want them to

show comments
al_borland

I don't use Spaces at all, probably in part because of the speed. I can't bring myself to run an application all the time to solve this, when it should just be a variable somewhere that needs to change.

ardline

This is the kind of thing that looks simple until you're three layers deep in edge cases.

Aaronstotle

I think it was iOS 9 that had some glitch where the animations were completely disabled and it was a really awesome experience to click an app and have it instantly open with zero animations.

KaiserPro

There used to be a commanline switch that if you used command left/right to switch it was almost instant. I'm not sure if thats still a thing

nkzd

Genuine question - why do people even use spaces? Why is it better than just CMD+Tab or CMD+Tilde until you arrive at the window you want?

show comments
MaxMonteil

Thank you so much for sharing!!

This has bothered me ever since I switched to a mac from i3wm.

I wish you and your loved ones all the best <3

rwc

Just installed and I have to say, works exactly as promised. This is a huge quality of life upgrade, thank you for sharing it Paul.

traderj0e

Apparently the "natural scrolling" option also reverses the swipe gestures for space switching, haha

revv00

It doesn't work macbook pro(Intel Sonoma 14.4.1), any thoughts? app icon is a forbidden icon.

nba456_

Awesome. Thank you!

ralphc

Works on my Intel mac running Sonoma 14.8.2. I use Omakub on my Linux machine and missed this when on my mac.

airstrike

I wonder how this compares to Aerospace, which I use daily but ultimately has felt a bit janky and slow

toddmorey

> it works by simulating a trackpad swipe with a large amount of velocity

Damn, that's rather clever.

show comments
revv00

Not a space user, command+tab solve most of my problem. But will give it a try.

anonymous344

always the same, no features, no freedom and stealing the best ideas from small developers -apple

walthamstow

I never run more than one space and instead switch between windows with the app Alt Tab

show comments
thenthenthen

Nice hack! Tldr: ‘instant’ space switching is achieved by simulating a trackpad swipe with insane velocity. Lol!

adamnemecek

What do people use for Windows-like window management on macos? I tried a bunch of them and I'm not a fan of any of them.

I actively dislike the notion of spaces.

show comments
obvi8

I was never bothered by the animations, but was livid when they redid the desktop thumbnails, and offered no way to always show the preview by default. You have to mouse up to them to get the previews.

It didn’t seem to bother the rest of the Mac world, but I used to organize my desktops in a chaotic way that worked great for me, and the ability to see the preview thumbnails as soon as I popped into mission control or whatever they call it enabled me to quickly go where I wanted to after a quick glance. I used to rename entire desktops, too.

The whole thing instantly became worse for me when they took away my ability to name your own virtual desktops, and added the extra speed bump of making me mouse up to trigger the previews. I’m still bitter about it.

isege

Christmas has come early! Thank you for sharing this

masijo

I thought I was the only one that noticed this and it was driving me insane. Can’t believe the experience is so sluggish, makes me miss KDE so much which is ridiculous.

houseofmvps

Great one. Thank you for sharing this.

theobr

This changed my life

mikeweiss

I have a vestibular disorder that makes this animation extremely disorienting and it's been so discouraging that apple won't do anything about it. I just stopped using the feature all together! Honestly it's an accessibility issue and apple should be ashamed... Maybe even liable for not doing anything.

IOT_Apprentice

BetterTouchTool is $25 for a lifetime license with upgrades.

show comments
mixtureoftakes

this was SO annoying. thank you.

Truly baffling how apple haven't done this before

joeevans1000

THANK YOU!!!!

throwatdem12311

Can’t say that the sliding animation has ever been the bottleneck to my productivity.

show comments
kewlzeeroe

why would you ever suggest disabling sip to "power users" seems bananas in this day and age.

kewlzeeroe

why would you post anything that has to disable sip... seems silly in this day and age.

righthand

Wobbly Windows in KDE is the only acceptable animation.

virtualritz

You know Apple lost it and have become what Jobs most hated when the instructions to suppress an obvious UX flaw in macOS read like a registry tweaking hack for some atrocious UX in Windows, ca 2005.

hirvi74

I eventually became so frustrated with spaces in OSX, that I essentially try to avoid using them in macOS these days. Seriously, all I want is a way to move windows from one space to another via keybindings. I am not asking for much. In fact, IIRC, I think Snow Leopard had this feature. I know there were various solutions that cropped up, and even currently there are a few hacks. It just... such bullshit that it's not built in.

If one has a disability that hinders his or her ability to use a mouse/trackpad, then I strongly suspect there is no way for such a person to use spaces on macOS well. Though, it seems Apple could not care less.

jiehong

Outstanding!

gib444

I installed Debian stable + i3 + x11 on a desktop today - what a breath of fresh air (not that I'm new to Linux) compared to MacOS. No bloat. No animations. No lag. A perfect tiling WM.

No Secure Boot, no TPM, no SIP, no phoning home to the mothership to check if I'm allowed to launch an app, no spyware, no telemetry, no update nags, no trying to trick me into upgrading to the next major version.

I tried Sway & Wayland but IntelliJ freaked out so I went to x11

Also Nouveau seems pretty damn good these days.

KeepassXC works much better on Linux which is nice.

I'm keeping my M4 Macbook Air around for a while to play with local LLMs but it's not exactly the best for that, so I'll think it'll be on eBay not before long, because MacOS is getting more and more annoying...

theultdev

This is beyond stupid for macbook using trackpad gestures.

I can understand for mouse/kbd input though.

veber-alex

Wow, works great.

I used to use yabai for this but I can't disable SIP anymore on a work laptop.

Also, stuff like this is why I really hate macOS sometimes.

hk1337

meh, i like the animation. I normally use it with the trackpad so the swiping back and forth makes it feel more natural if there's animation.

IOT_Apprentice

A lifetime license for BetterTouchTool with ALL its features is $25. The time the author spent on this is well over that amount.

user3939382

I’ve used TotalSpaces for this in the past, though Apple has essentially ruined the ability to make these tools successful with their SIP bullshit

tomi_dev

Curious — what was the hardest part to get right here? Was it performance or handling edge cases?

mrkpdl

I use spaces constantly, and I’ve never thought about the animation - I don’t think I’d ever noticed it to be honest. So it’s really interesting to read all the comments here about how frustrated people are with it. This is not a defence of it just genuine interest - I bet there are totally different parts of the OS that bother me that don’t bother others also.

show comments
zahma

Imagine being so intelligent to do so many things with a skill set, yet choosing to spend so much time on an animation that can be measured in microseconds. The proportions are staggering. Truly bizarre to me how something I’ve never even noticed while using the feature could drive a person to this level of obsession.

show comments