Hammerspoon
Hammerspoon is a macOS automation tool that exposes system functions to Lua scripts, letting you control windows, apps, hotkeys and more.
- GitHub stars
- 16k
- Last commit
- 2 mo ago
- Latest release
- 1.1.1
- Licence
- MIT
- Self-hosted
- Yes

Hammerspoon is a free automation tool for macOS that links the operating system to a Lua scripting engine. By itself it does nothing; you create an init.lua file in a .hammerspoon folder in your home directory and fill it with scripts that tell your Mac what to do.
Its flexibility comes from a large set of extensions that expose pieces of system functionality to Lua, such as window management, application control, keyboard shortcuts and reactions to system events. People use it to build custom hotkeys, tile windows, automate repetitive tasks and wire apps together in ways the stock system does not allow. A Discord server and shared configurations help newcomers get started.
Hammerspoon is MIT-licensed and installs either by dragging the app into Applications or with the Homebrew cask. It runs locally on macOS only, so there is no server to manage and no hosted version, and it suits power users and developers who like to script their desktop.
Key features
- Lua scripting bridge to macOS
- Window management and layout control
- Custom hotkeys and keyboard automation
- Application and system event hooks
- Modular extensions for system functions
- Installable via Homebrew cask
Pricing: Free and open source under the MIT license.