71

I am looking for a stable way to keep any window 'always on top' on OSX.

Afloat, an app that does that requires SIMBL/easySIMBL, which it seems is not very stable.

Are there any better solutions? It's actually surprising that there is no native way to implement this.

  • 1
    The HIG of OSX doesn't allow it and thus it was never programmed anywhere into the windowing system. Usually it means that you'r trying to solve a problem the wrong way, or an app you use is badly written and doesn't do what it needs to do. Actual solutions will either need a better explanation of the problem, or a programmer to fix the app. – John Keates Dec 12 '15 at 4:41
  • 2
    To let the user set their window-of-choice to always be on top of other windows might cause undesired and unexpected behavior. The screen saver is also just a window - do you want to float above that? What about important alerts? What if two apps demand to be always-on-top? You could theoretically DoS a user by putting your full-screen app on top and logging them out. This is why there is no 'always-on-top' property in Cocoa. One can only specify a relative Z index (and Apple urges against doing that). Your options are basically re-code the app, or use SIMBL. – J.J Jan 29 '16 at 17:52
  • Are you looking to do this for any application in the Mac OS? If so, do you want it to always have focus (meaning key presses and mouse click), or do you want the window of an app to "float above" all others, but NOT be the active window? – kenjikato Feb 3 '16 at 8:08
  • 6
    FWIW Fedora has always allowed this (since the mid 90s in RH form) and I have never had any problems of the "undesired" nature. It just isn't in OSX when it could be put in. – nerak99 Nov 25 '16 at 11:58
  • 1
    John Keates - Unfortunately you don't know what you're talking about. Xcode did this very behavior with their Simulator, keeping it in front of all other windows, and this behavior existed for many years until they finally removed it in Xcode 9. – Logicsaurus Rex Apr 30 '18 at 18:45
21

I'll note that the iOS Simulator has/had the option Stay in Front. Extremely useful functionality, and proves that there are Apple-supported and sanctioned ways to achieve this behavior.

Might be worth opening a radar, especially for adding to Terminal.

You can duplicate my radar:

Bug ID 27430873: Add "Stay in Front" option to Terminal windows.

Stay in Front option in iOS Simulator

Unfortunately, Xcode 9 removed this feature in the iOS Simulator. Please duplicate my Apple bug report to bring that back, as well!

Bug ID 32852924: Xcode 9 iOS Simulator is missing the "Stay in Front" option

  • 1
    What is this iOS simulator? Is it like an emulator? I have been looking for one. – tjt263 Mar 4 '17 at 12:54
  • @tjt263 the iOS simulator is bundled with Xcode and mainly used to develop iOS apps – pkamb Mar 5 '17 at 6:36
  • 1
    Oh ok. What's a radar? Like a bug report? – tjt263 Mar 5 '17 at 8:14
  • @tjt263 yes, bugreport.apple.com – pkamb Mar 5 '17 at 17:35
  • 3
    This functionality is also shown in the pre-installed 'Activity Monitor' - if you go to the 'Window' menu, you'll see an option to 'Keep CPU Windows on Top' - so it does indeed seem like there's an official Apple way to do this. (This is what I see on 10.13.2) – keybits Dec 15 '17 at 11:48
14

If you are looking to do this just for a say an internet browser window you could look at the open source Helium app. It's free, and you can also download the source and compile your own version if you want.

It's basically an internet browser that always floats above all other windows. Helium App

EDIT:

There's also a newer app from the Apple Mac App Store called Fluid Browser that will do this same thing. It does cost a couple of $s, but it works excellently and has a few more features than Helium (as of 7/6/2016). So you now have two different apps to choose from.

Fluid Browser

  • I did not like the Fluid Browser experience. Yes, it has a few more features but it's pretty buggy and cumbersome. Helium is very lightweight but does the job. – Winterflags Nov 1 '16 at 13:21
  • 1
    Can you block ads in Helium or Fluid? – powder366 Feb 5 '17 at 12:33
4

If you only really want/need "stay on top" functionality for your Terminal.app window (like myself), there is a Quake/Guake-style drop-down visor, SIMBL plug-in available that supports being pinned to the foreground; TotalTerminal.

So it's possible, despite the common misconception that it's not.

As of MacOS 10.11 (El Capitan), to install/run TotalTerminal, you might need to disable System Integrity Protection:

csrutil enable --without debug

It's no longer open source, but the last open source implementation is still available on GitHub. So if you're inclined to, you could investigate exactly how it's achieved. I emailed the developer to ask, but it's been so long since they worked on it, they couldn't (or wouldn't?) really tell me.

  • TotalTerminal is no longer maintained these days. I ended up switching to iTerm to get the same behavior: apple.stackexchange.com/questions/48796/… – André Morujão Jul 4 '17 at 9:25
  • That's right, I wouldn't suggest using it. But if someone is motivated to implement their own solution, it might be worth browsing the linked source code. – tjt263 Jul 6 '17 at 0:11
  • For floating terminal, I am using Helium with gotty. gotty allows you to open a terminal in web browser and Helium is a floating web browser. – wesley6j Jul 13 '17 at 14:25
  • You really, really, really, and I really really mean really do, need to note that you should re-enable SIP after doing what you document. – Pryftan Feb 23 at 16:25
  • @Pryftan nah, SIP is for pussies. – tjt263 Feb 24 at 8:42
3

There is a free app called Key Codes in the Mac App Store that as far as I can tell stays on top of all other windows. Other than menu items it stays atop all other apps including the Terminal and the Safari URL bar.

  • 10
    Brilliant tip Seamus if the op specifically needs that particular app to stay on top. Now, if, hypothetically speaking of course, he wants a different app to stay on top, or perhaps even few different ones, then perhaps not so sterling? – mysomic Dec 2 '16 at 22:01
  • 1
    Thanks! Works great for the use case "please occlude this ghastly thing". – ecmanaut Mar 3 '18 at 15:27
2

Not really an answer but more like a work-around: you can use Spectacle or a similar app to quickly setup a desktop layout that let you follow the original window.

Of course this won't help when you're waiting for someone else to join a support chat and in the meanwhile decide to use your time for something more useful than staring at a blank window -- like working on another virtual desktop :(

Grab Spectacle from here: https://www.spectacleapp.com

  • Welcome to Ask Different and taking the time to post an answer. As a suggested improvement, your should provide links to the application(s) that you reference in your post. It makes for a better user experience. For more information on crafting a good answer see: apple.stackexchange.com/help/how-to-answer – Allan May 3 '16 at 15:46
  • 1
    Hello Allan, thank you very much for helping make AskDifferent a neat and tidy place, I will follow your instructions. Cheers. – i90rr May 5 '16 at 18:49
1

just drag your terminal, over the safari window, after typing the F3.

this automatically arranges the terminal, vertically, on the right side of the safari window, for example... so you can do some work and have access to the terminal, while in another window...

  • Nothing happens when I try this. The terminal window just returns to original position. – jmh Aug 9 '18 at 20:12
1

I've just given up on mySIMBLE and afloat. Fenêtre is a paid for app with a free lite version that works really well.

I use it to play videos window in window while I work or to keep online instructions on top. Not sure what you want to use it for?

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .