DEV Community

Sayed Ali
Sayed Ali

Posted on

Supercharge your macOS workspace management with Aerospace - A guide for busy people

Aerospace completely revolutionized my workflow after 15 years of using macOS the way Apple intended. I no longer hunt for apps and windows in Mission Control or drag them around spaces to organize. I can open as many windows as I need and have them all under my fingertips. And instead of swiping around to find one, I instantly teleport to where they are.

This incredible software is technically aimed at advanced users. It’s installed from the command line and offers extensive configuration options. For basic use though, you don’t need to configure it at all, and if you have opened the Terminal application before and know what running a command means, you should be good to go. Rest assured, I will not show you how to configure Aerospace with Vim, or show you how to create an elaborate but useless dashboard! Just the essentials to get you started.

How to set up Aerospace

Aerospace is a menu bar application, but you can’t download it from an App Store or get it as a DMG file. You need a package manager. Go to the Homebrew website and follow the installation guide. Make sure to accurately follow the on-screen instructions. This may include any of the following:

  • A prompt to enter your password. When you type passwords in Terminal, you will not see stars or anything. Just make sure you’re typing the correct one and hit Enter.
  • A prompt to install XCode Command Line Tools.
  • Somewhere around the end of the installation process, you may get a prompt to run some extra commands, which depend on your system. Make sure you run them as instructed.

To test if you have correctly installed Homebrew, run which brew in Terminal. If you see a path printed out, like /opt/homebrew/bin/brew, you’re good to go. If not, something has gone wrong. Try searching for other, more focused guides on installing Homebrew.

With Homebrew, you can install applications from the Terminal app using the brew command. For Aerospace, you would run the following command:

brew install --cask nikitabobko/tap/aerospace
Enter fullscreen mode Exit fullscreen mode

I promise this is the last time you will need the Terminal for basic use! Now launch Aerospace like any other app (from the launchpad, application folder, spotlight search, etc). You will see a little indicator pop up in your menu bar showing the number 1. You are now in workspace 1.

3 shortcuts, 80% of Aerospace!

Upon launching Aerospace, all your open apps and windows move to workspace 1 in maximized format by default. Use the following shortcuts (also called keybinds) to manage them:

  • ALT-SHIFT-<space> to move a window into the workspace named <space>. For example, you can move your browser to workspace B with ALT-SHIFT-B. Note that when you move a window to a workspace, you will stay in the current workspace.
  • ALT-<space> to switch to workspace <space>. For example, with ALT-B you would switch to workspace B. The menu bar indicator will then show the newly activated workspace. It doesn’t matter if a workspace has been activated before or not. Moving to an empty workspace would simply show the desktop.
  • ALT-tab to toggle between the last two workspaces used. It’s similar toCMD-tab, but better. More on this later.

You don’t need to create a workspace before using it. You just press the move or switch keybind with a number or letter, and the workspace automagically activates. You can use the numbers 1 through 9, and all the letters except HJKL, as they are reserved for other functions.

The rest of this blog is mainly about my philosophy and example workflows.

Why Aerospace and not native Spaces?

macOS native spaces have a limit of 16. You can assign shortcuts to switch to each one, but you can’t create one with a shortcut, or move windows between them except manually and with painfully slow animations. You can reduce them to a "fading" effect, but the speed remains the same. When your daily workflow consists of alternating between apps hundreds of times, these animations stop being fun. I say this as someone who "swiped" between spaces for years!

Aerospace does not rely on the native spaces feature. Instead, it has the concept of virtual workspaces, all of which live in a single native macOS space. Switching between these virtual workspaces essentially means hiding all other windows and only keeping the window(s) assigned to the active workspace. This is genius, as it makes Aerospace incredibly flexible in managing windows between workspaces, without the need to poke into deep system integrity settings like how Yabai (another popular tiling window manager) does.

Why Aerospace and not an app launcher?

With Aerospace, a switch shortcut is not bound to an app; rather, it’s bound to a workspace that contains that app. This way I can:

  • Replace my browser or document reader with another app without the need to redefine a new shortcut for the new app (which is what you need to do with other app launchers).
  • Launch any app, instantly move it to an empty workspace (of which there are plenty), and have the workspace shortcut immediately available. Again, no need to create a new shortcut for that app.
  • Put multiple instances of the same app in different workspaces and have them automatically available through the shortcuts for those workspaces. You can’t do that when a shortcut is bound to an app (more on this later).

Why Aerospace and not external monitors?

For context, I use a 13-inch M1 MacBook Air. I experimented with workflows involving multiple external monitors, including a giant 50-inch curved monitor, but I could never stick with them. I’m rarely in one location, and need to resume my work anytime, anywhere. Constantly switching from Desktop to mobile modes is cumbersome and jarring, as it completely messes up my window arrangement and mental model of the virtual workspace.

Besides, I realized that having every app and window visible at all times is not that big of a productivity deal after all. For one, there is neck and eye strain from having to constantly move left and right to see the entire width and height of the monitors. Second, it reduces focus! Why would I want my chat app visible while I code?

With Aerospace, I have practically unlimited monitors (aka virtual workspaces) that are instantly available when I need them. Instead of hunting for windows on a giant monitor, I summon them using a shortcut; my eyes stay focused straight. And I can have one setup that I carry with myself anywhere I go; no context switching.

My typical workflows

Most of the time, I use a single window per workspace in maximized mode. I even hide the status bar and dock for a truly full-screen mode, so I don’t even need the macOS native full screen feature with that jarringly slow animation! The following are the typical workflows I use, in order of frequency.

Permanent workspaces

I learned the core concept from The Primeagen. Although each workspace can have any number of apps and windows, I have my essential apps permanently live in their dedicated workspaces: browser in workspace B, terminal in T, file explorer in E, document reader in R, and so on. The beauty of this workflow is that I’d be a single shortcut away from my destination; ALT-B always takes me to a browser, and ALT-T to the terminal, regardless of where I happen to be at any moment.

Alternating between two workspaces

ALT-tab is my most used shortcut. It is used to alternate between the last two workspaces used. It’s like CMD-tab, but much, much better. For one, ALT-tab is much snappier than CMD-tab, but more importantly, it alternates between workspaces, and not apps. This enables the following scenario:

You have a code editor in workspace C, a browser window showing a tutorial in workspace B, and another browser window to live preview your website in workspace W. If the last two apps were the code editor and the preview browser window, but you wanted to alternate between the tutorial and the preview (which are both in the same browser but separate windows), CMD-tab won’t work; it alternates between apps, not instances of the same app. But ALT-tab does not care about apps or windows. It alternates between the last two workspaces used.

Managing multiple instances of the same app

You have 5 PDF files you need to reference. You will open each one in a new window (not tabs), and move each one to workspaces 1 to 5. Now you have automatic shortcuts to your 5 PDFs! Compare that with having to use a mouse and click tabs in a PDF reader. This workflow essentially eliminates the need for tabs in many apps.

Another interesting scenario: You can open multiple browser windows, each for a specific purpose in a dedicated workspace; one for your online coursework, one for email, one for YouTube, etc. Now you have them all accessible through dedicated keybinds.

Floating windows

Every once in a while, you come across an app or window that does not work well in a tiled format. Aerospace is pretty good at automatically detecting these kinds of windows, such as the native Settings app and third-party settings windows, making them float by default.

If, for any reason, you want a window not tiled, you can switch that specific window (and not the whole workspace) to floating mode. In this mode, that window will be removed from the tiled stack, where you can freely resize and position it with the mouse.

To activate floating mode, you will need to enter the so-called service mode with ALT-SHIFT-semicolon and hit f once while the target window is active. To make that window tile again, repeat the same process. Note that in service mode, the menu bar indicator will show [S] <space>. When you hit f, you will automatically go back to the so-called main mode. You can also exit service mode with esc.

Tiling vs. Accordion

Aerospace has two layout options for working with multiple windows in one workspace: Tiling arranges the windows side by side, while accordion overlays them on top of each other in almost maximized format, leaving a 30px gap on the sides to help you cycle through them. Each layout can also be in vertical or horizontal modes. Also, each workspace can have its own layout, meaning activating a certain layout in one workspace does not affect other workspaces.

ALT-slash (slash is the one next to the right ALT) activates tiling mode (if you were in accordion mode). If you were already in tiling mode, this same keybind would toggle between horizontal (side by side) and vertical (top to bottom) modes. Interestingly, Aerospace is smart enough to detect a vertical monitor, for which the windows will tile top to bottom (vertical mode) by default.

ALT-comma activates the accordion mode (if you were in tiling mode). If you were already in accordion mode, this same keybind would toggle between vertical and horizontal accordions, which changes where the 30px gaps show up.

I don’t like accordion mode at all, as it forces me to use the mouse! My goal is to have all my windows available instantly using a single shortcut.

Complex tiling arrangements

You can join windows to create a complex grid structure, such as a 3-window workspace where one takes half the screen and the other two share the other half. You can also resize windows and move them to the left/right/top/bottom.

For reference, these are the default shortcuts:

  • ALT-minus/equal: With at least two windows side by side, it is used to decrease/increase the size of the active window.
  • ALT-SHIFT-hjkl: In service mode with at least three windows, it is used to join a window with the left/bottom/top/right window, thus making them act as one node to be tiled.
  • ALT-hjkl to change focus to the left/bottom/top/right window.
  • ALT-SHIFT-hjkl to move a window to the left/bottom/top/right window

I have never found myself needing these! I really only use Aerospace as a workspace switcher, so I rarely tile my windows. I may occasionally tile a second Finder window for a quick task and close it. If I need the second window for longer, I move it to a dedicated space.

Configuring Aerospace

Aerospace is pretty much an invisible app. You install it, launch it, and forget it’s there. No background app to hide, no menus to fiddle with. That being said, you can manually change the configuration using a text file. You can add extra functionalities, change default shortcuts, and add new ones.

You can view the default config to get a general idea and to also learn what other shortcuts are available to you. If you want to dig deeper, have a look at the official documentation, or this excellent YouTube Guide by Josean Martinez. You can also have a look at my config for a minimal example.

To pique your interest even further, these are the things you can do with a custom configuration:

  • Make aerospace launch automatically on macOS startup.
  • Set up rules to automatically move your essential apps to their dedicated workspaces upon launching Aerospace (life saver).
  • Have certain apps always launch in floating mode.
  • Add gaps between tiled windows (totally useless on a small laptop, if you ask me).
  • Add the Function keys (F1, F2, etc) to the list of available workspaces.

My general philosophy in using any app is to stay on the default configuration for as long as possible, and only customize when I start to really feel the need for something specific. This avoids premature optimization.

Aerospace quirks

Aerospace is still a Beta project, but it’s actively maintained. I had very few issues with it, at least with my simple setup without external displays and complex workflows. That being said, there are a few issues with very simple solutions:

Unhide erroneously hidden windows

Aerospace hides windows by moving the whole window to the bottom right corner, but leaves a small 1px strip in the visible area. Most of the time, this is hidden behind the foreground window. However, sometimes switching to a workspace does not "unhide" the window(s) in that workspace. When this happens, simply click on that 1px strip on the bottom right corner, and the window(s) will pop back up.

Windows too small in Mission Control

You can fix this by enabling Group windows by application in System Settings → Desktop & Dock. The developer also suggests disabling Displays have separate Spaces in the same settings page. I never used multiple monitors, so I have nothing to say about it.

You may need to visit Mission Control when you lose a window, probably because you forgot where you put it!

Trouble with native tabs

Aerospace does not work well with native macOS tabs in some apps, such as Finder. If you open 2 Finder tabs in one window, Aerospace would think they’re two windows, and shrink the only available window to half the screen, leaving the other half completely empty. The developer has acknowledged the issue, and there are no real workarounds. I can talk about how I dislike tabs in general, but that’s a topic for another blog :)

Weird gap on the bottom edge

I’m not sure if it’s only me, or if it depends on your monitor’s dimensions, but I had a 1px gap on the bottom of every maximized window. Me being the perfectionist freak that I am, I could not live with that! At first, I solved this by having a desktop wallpaper that had a 2px solid black line on the bottom edge, making the gap blend with the bezel! Later, I learned I could modify the gaps in the config file and manually push the bottom edge down by a negative value:

[gaps]
    inner.horizontal = 0 
    inner.vertical =   0
    outer.left =       0
    outer.bottom =     -1 # remove the 1px gap at the buttom!
    outer.top =        0
    outer.right =      0

Enter fullscreen mode Exit fullscreen mode

Now everything is truly full screen :)

Consider sponsoring

Aerospace and the Zen Browser are the only open source projects I’m happily sponsoring. These two apps fundamentally changed the way I use my Mac, so I need them to succeed! If that’s you, consider sponsoring the project.

Top comments (0)