github charlie0129/batt v0.10.0

one hour ago

What's Changed

Highlights

  • More reliable native charge limits on macOS 27. batt now accepts targets that macOS applies later instead of repeatedly reporting registration errors.
  • Correct battery capacity reporting on macOS 27.
  • MagSafe LED control in native mode. The LED follows the charging state reported by macOS and is returned to system control when batt exits.
  • Experimental opt-in no-drain mode for macOS 27 native charging.

Commits

Since v0.9.0:

Installation

GUI version

  1. Download .dmg and open it (right-click open if macOS says it's damaged)
  2. Drag batt.app to Applications
  3. macOS may say it's damaged when you try to run it (it's NOT) and wants you to move it to trash. To fix it, run this in Terminal: sudo xattr -r -d com.apple.quarantine /Applications/batt.app.
  4. Run batt.app.
  5. Follow the MenuBar UI to install or upgrade.
  6. Disable macOS's optimized charging: System Settings -> Battery -> Battery Health -> i -> Turn OFF Optimized Battery Charging. Built-in charge limit also need to be disabled if you are on macOS 26.4 or later.

CLI version

Note

Command-Line version is already included if you have installed the GUI version.

Option 1: Installation Script (Recommended)

bash <(curl -fsSL https://github.com/charlie0129/batt/raw/master/hack/install.sh)

Option 2: Homebrew

brew install batt
sudo brew services start batt # Do NOT forget sudo.

Disable macOS's optimized charging: System Settings -> Battery -> Battery Health -> i -> Turn OFF Optimized Battery Charging. Built-in charge limit also need to be disabled if you are on macOS 26.4 or later.

Upgrade

GUI version

Just follow the installation steps again. After you open the new version of batt.app, click Upgrade Daemon... upgrade to the new daemon.

CLI version

Please use the same method (Installation Script / Homebrew) as you installed to upgrade batt. Using both methods will cause conflicts. If you don't remember how you installed it, you can check the binary location by running which batt. If it is in /usr/local/bin, you probably used the installation script. If it is in /opt/homebrew/bin, you probably used Homebrew.

Option 1: Installation Script

bash <(curl -fsSL https://github.com/charlie0129/batt/raw/master/hack/install.sh)
# Yes, the command is the same as installing.

Option 2: Homebrew

Important

If you previously ran batt v0.7.3 or earlier, follow the one-time service-label migration before starting the service. When the Homebrew formula moved from v0.7.3 to v0.7.5, its service label changed from cc.chlc.batt to homebrew.mxcl.batt.

brew update
sudo brew services stop batt # Do NOT forget sudo.
brew upgrade batt
sudo brew services start batt # Do NOT forget sudo.

Homebrew service-label migration

if sudo launchctl print system/cc.chlc.batt >/dev/null 2>&1; then
  sudo launchctl bootout system/cc.chlc.batt
fi
sudo rm -f /Library/LaunchDaemons/cc.chlc.batt.plist

Compatibility Matrix

Check your firmware version by running system_profiler SPHardwareDataType | grep -i firmware in Terminal. Do NOT rely on macOS version.

Firmware Version First macOS release GUI CLI (Prebuilt) CLI (Build from Source) Note
6723.x.x macOS 11 Big Sur ❌ ❌ ⚠️
7429.x.x / 7459.x.x macOS 12 Monterey ❌ ⚠️ ✅
8419.x.x / 8422.x.x macOS 13 Ventura ⚠️ ⚠️ ✅
101xx.x.x macOS 14 Sonoma ⚠️ ⚠️ ✅
118xx.x.x macOS 15 Sequoia ✅ ✅ ✅
138xx.x.x / 18xxx.x.x macOS 26 Tahoe ✅ ✅ ✅
20356.0.0.0.15 ~ 20457.0.77.0.2 macOS 27 Golden Gate Developer Beta 1~3 ✅ ✅ ✅ Firmware-managed limits
20457.0.125.0.2+ macOS 27 Golden Gate Developer Beta 4+ ✅ ✅ ✅ Native limits (10–99%, upper only); optional adapter mode or experimental no-drain; see docs
Other Unknown ❓ ❓ ❓
  • ❌: Unsupported
  • ✅: Supported
  • ⚠️: Not verified, but expected to work.
  • ❓: Unknown, please raise an issue if you have tested it.

Note

Firmware version is different from macOS version. Old macOS versions may have newer firmware, e.g. macOS 15.8.2 has firmware 20457.41.3 (macOS 27 Golden Gate versions).

Note

macOS 15.8 updates ship 20xxx firmware but keep firmware-managed limits (upper and lower).

Don't miss a new batt release

NewReleases is sending notifications on new releases.