Apple - How do I get the Caffeine app working on macOS Mojave?

Caffeine is still working! However, Apple has upped its security and privacy model a bit and caffeine fell prey to that. What you have to do to get it working properly again is the following:

  • Open System Preferences
  • Click Security & Privacy
  • Click the Privacy tab
  • In the left column, select Accessibility
  • If needed, click the lock icon in the lower left and enter your password to unlock your settings
  • Click the + button and select your Caffeine app to allow it to control your Mac
  • Restart Caffeine

System Preferences screenshot


TLDR: Access to the permissions in Mac OSX Mojave have changed. You have two options:

  1. Download updated version of Caffeine that I fixed. See story below.
  2. Update preferences to allow Caffeine access it needs. (via other answer to this question)

While this question wasn't entirely clear on whether the issue was with the caffeinate command built in to macOS or the Caffeine utility written by Tomas Franzén of Lighthead Software, the comments and other answers seem to imply the latter.

After encountering the issue myself, I reached out to Tomas and inquired about taking over the development of Caffeine. He graciously has provided the source code under an MIT license, and I've made a quick updated version available here that will prompt for the needed accessibility permissions when running on Mojave.

I will be bringing additional support for Mojave as well as some improvements in the near future, but wanted to put this here for others who come across this question like I did and would like to continue using Caffeine.


Here are 2 alternative you can try that do the same as caffeine.

Amphetamine, a full-on Caffeine replacement

and

KeepingYouAwake, an up-to-date Caffeine clone