Automate Dotwatt

Dotwatt can be run without opening its panel: from the Shortcuts app, on a schedule, from a script or with a key.

Actions for the Shortcuts app

Open Shortcuts, start a new shortcut and search for Dotwatt. Three actions return what Dotwatt measures, five switch something.

Get Time Left on BatteryMinutes until the battery is empty, measured from the real draw. No value on wall power.
Get Power DrawWhat the Mac is using right now, in watts.
Get Battery LevelThe charge, in percent.
Keep Mac AwakeUntil stopped, for a number of minutes, or while coding agents work.
Let Mac Sleep AgainEnds the stay-awake session.
Set Charge Limit80 to 100% in steps of five; 100 switches the limit off. Needs macOS 26.4 or later.
Charge to Full OnceCharges to 100% this one time; the limit is back afterwards.
Set Low Power ModeOn or off. Needs Dotwatt's helper.

The actions need a copy of Dotwatt that is in its free trial or has a key.

On a schedule

A full battery by the time you leave

This one is built in. In Dotwatt's settings, under Full by a set time, choose Once or Every day and a time. With a charge limit set, Dotwatt lifts the limit early enough for the battery to reach 100% by then, and the limit is back afterwards. If the Mac goes to sleep on the charger within twelve hours of that time, the charge starts at that moment.

Anything else at a time of day

The Shortcuts app on the Mac can run a shortcut by itself. Apple's guide names events such as a time of day or the opening of an app, and says that macOS asks before it runs the automation. Put Dotwatt's actions in such a shortcut:

  • Low Power every evening. A shortcut with Set Low Power Mode, On, run at 22:00. A second one switches it off in the morning.
  • The limit back on Monday. Set Charge Limit to 80, run at the start of the working week.
  • Awake for a long job. Keep Mac Awake for 120 minutes, run when your render or build app opens. For a single app Dotwatt's own App mode does the same without a shortcut.

Shortcuts decides which events it offers, and they can differ between macOS versions: see Apple's guide to automations in Shortcuts on Mac.

Shortcuts that use what Dotwatt measures

  • How long do I have? Get Time Left on Battery, then show or speak the result. Add it to the menu bar or call it by voice.
  • Only when it matters. Get Battery Level, then an If: under 30%, Set Low Power Mode, On.
  • Watch the draw. Get Power Draw, then an If: above the watts you choose, show a notification.

Links for Raycast and scripts

Every link works from a browser, Raycast, a shell script (open "dotwatt://awake?minutes=60") or the Open URLs action.

dotwatt://awakeKeep the Mac awake until stopped
dotwatt://awake?minutes=60Awake for an hour (1 to 1440 minutes)
dotwatt://awake?mode=agentsAwake while coding agents work
dotwatt://awake/offLet the Mac sleep again
dotwatt://low-power/onLow Power Mode on; /off switches it off
dotwatt://limit/80Charge limit, 80 to 100 in steps of five
dotwatt://charge-fullCharge to 100% once
dotwatt://openOpen the panel; /stats opens the Stats tab

Keyboard shortcuts

Two keys work from any app: one switches Stay awake on or off, one opens Dotwatt. Record them in the settings, under Keyboard shortcuts, with a key together with ⌃, ⌥ or ⌘.

Coding agents

Staying awake for agents needs no automation at all: Dotwatt notices the agents by itself. How it works. Everything else Dotwatt does.