About Hammerspoon
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
Good fit for
- →Custom window tiling on macOS
- →Building personal keyboard shortcuts
- →Automating repetitive desktop tasks
- Built with
- Objective-C
- Tags
- macos
- lua
- automation
- hotkeys
- window-management
- desktop
Hammerspoon: questions and answers
- What is Hammerspoon used for?
- Hammerspoon is a macOS automation tool that exposes system functions to Lua scripts, letting you control windows, apps, hotkeys and more. It is a good fit for custom window tiling on macOS, building personal keyboard shortcuts and automating repetitive desktop tasks.
- Is Hammerspoon open source?
- Yes. Hammerspoon is open source under the MIT licence. Its source code is on GitHub at Hammerspoon/hammerspoon and is written mainly in Objective-C.
- Is Hammerspoon free?
- Yes. Hammerspoon is open source, so the software itself is free to use.
- What is Hammerspoon an alternative to?
- Hammerspoon is an open-source alternative to Keyboard Maestro, Hazel and Apple Shortcuts. Other open-source alternatives to Keyboard Maestro include AutoHotkey and AutoKey.
- Is Hammerspoon actively maintained?
- Yes. The most recent commit to Hammerspoon was on 8 July 2026, and the latest release is 1.1.1, published on 26 February 2026. The project has 16k stars on GitHub.
Open-source alternatives to Hammerspoon
See all
AutoHotkey
Workflow Automation
AutoHotkey - macro-creation and automation-oriented scripting utility for Windows.
GPL-2.0vs Keyboard Maestro★ 13k
AutoKey
Workflow Automation
AutoKey, a desktop automation utility for Linux and X11.
GPL-3.0vs TextExpander★ 3.9k
UFO
Workflow Automation
UFO³: Weaving the Digital Agent Galaxy
MIT★ 9.9k
Obsei
Workflow Automation
Obsei is a low code AI powered automation tool. It can be used in various business flows l
Apache-2.0★ 1.4k
Errbot
Workflow Automation
Errbot is a chatbot, a daemon that connects to your favorite chat service and bring your t
GPL-3.0★ 3.3k
n8n
Workflow Automation
n8n is a workflow automation platform that uniquely combines AI capabilities with business
OSSvs Zapier★ 206k
SaaS alternatives to Hammerspoon
See all
Keyboard Maestro
Workflow Automation
macOS app for building keyboard-triggered macros that automate Mac tasks
SaaS
Hazel
Workflow Automation
macOS utility that watches folders and organizes files with rules automatically
SaaS
Apple Shortcuts
Workflow Automation
Automation app built into iOS, iPadOS and macOS for chaining actions across apps
SaaS
Alfred
Productivity
macOS launcher with workflows, clipboard history and snippets
SaaS
Raycast
Productivity
Launcher for macOS and Windows with extensions, snippets and an AI assistant
SaaS
Albato
Workflow Automation
No-code automation platform connecting business apps with prebuilt integrations
SaaS

