How to Install Keysharp

Pick your system. Each button downloads the standard installer; other formats are listed beneath it.

Windows

Portable ZIP

macOS

PKG installer

Linux

Portable tarball

Keysharp 0.0.0.16. Other architectures, every package and SHA256SUMS are on the release page.

Keysharp needs the .NET 10 runtime. The Windows and Linux installers offer to install it for you; on macOS, install it yourself if it is missing.

Table of Contents

Windows

Run the downloaded .msi and follow the prompts. The installer can add Keysharp to PATH, associates .ks and .cks files with Keysharp, and adds a right-click Compile action for .ahk and .ks files which writes a .cks beside the script.

Nothing else is required. Skip to Verify the installation.

Portable use

To run Keysharp without installing it, download the ZIP instead, extract it, and run .\Keysharp.exe yourscript.ahk from that directory. No file associations or PATH entry are created.

macOS

macOS 15 or later is required. Download the Apple silicon build on an M-series Mac and the Intel build otherwise; the picker above selects one for you.

Open the .dmg and double-click Install.command. It copies Keysharp and Keyview to Applications, then asks whether to add the keysharp and keyview terminal commands (this needs an administrator password) and the VS Code shim.

Alternatively, drag both applications onto the Applications shortcut in the disk image.

First launch

Note: The packages are signed but not notarized, so the first launch needs an extra step: Control-click each application, choose Open, then confirm Open.

Permissions

Input Monitoring, Accessibility and Screen Recording are requested when a script first needs them. macOS Permissions explains which features need which permission, and how to ask for them at startup.

PKG installation

The .pkg is an alternative to the disk image: it installs both applications to Applications, then asks the same questions about terminal commands and the editor shim. Double-click it in Finder, or run sudo installer -pkg <package>.pkg -target /.

Linux

On Debian, Ubuntu and derivatives, install the downloaded package:

sudo apt install ./keysharp-<version>-linux-x64.deb

On Arch-based systems, use the community-maintained keysharp-git AUR package. On other distributions, extract the tarball and run sudo bash ./install.sh.

A system installation creates the keysharp command, associates .ks and .cks files, and installs two privileged helpers which most features depend on:

GNOME and Cinnamon extensions are installed for the current desktop user where applicable. The GNOME extension is needed for screen capture, mouse-location queries and window automation, and takes effect after logging out or rebooting.

Installing without root

Running bash ./install.sh without sudo installs under $HOME/.local. The privileged helpers are skipped, so input hooks, input synthesis and Wayland screen capture are unavailable. See Platform Support for what each backend can do.

Verify the Installation

Save this as hello.ks:

MsgBox "Hello from Keysharp!"

Double-click the file. A message box appears if the installation is working — the installers associate .ks and .cks files with Keysharp, so scripts run like any other program.

It can also be run from a terminal, which is how you see any output a script writes:

keysharp hello.ks

On Windows the command is Keysharp.exe hello.ks, and for a portable copy it is .\Keysharp.exe hello.ks from the extracted directory.

Using an Editor

Keyview ships with Keysharp and needs no setup. See Editors for Keysharp Scripts for the alternatives.

To use thqby's AutoHotkey v2 Language Support extension for VS Code, point it at a shim named after the executable it expects. The macOS installer offers to create this; on Linux, create it manually:

mkdir -p ~/.local/bin
ln -sf "$(command -v keysharp)" ~/.local/bin/AutoHotkey.exe

Set the extension's interpreter path to that file. Syntax support and running scripts work; Windows-specific debugging, help and compiler integration do not.

Uninstalling

On macOS the uninstaller cannot revoke privacy permissions; remove Keysharp and Keyview under System Settings → Privacy & Security. If permissions misbehave after switching between differently signed builds, reset them:

tccutil reset All org.keysharp.keysharp
tccutil reset All org.keysharp.keyview

macOS can keep opening applications from the Trash, so empty it if removed applications stay associated with .ks or .ahk files.

Building from Source

Building requires the .NET 10 SDK. On Linux and macOS it also requires the Keysharp branch of the Keysharp Eto fork, cloned beside the Keysharp repository:

git clone -b Keysharp https://github.com/keysharp-org/Eto.git
PlatformBuild and packageOutput in dist/
Windows Keysharp.Install\package-windows.ps1 MSI and portable ZIP. The MSI needs the Microsoft Visual Studio Installer Projects extension; the ZIP does not.
Linux Keysharp.Install/package-linux.sh Portable directory and tarball, plus a .deb when dpkg-deb is present.
macOS bash ./Keysharp.Install/package-macos.sh DMG and PKG for the host architecture. Set RID=osx-x64 to cross-publish; signing and notarization are skipped unless ADHOC_SIGN=true.

To run without packaging, build the solution and launch the executable from the build directory — on Windows, open Keysharp.sln in Visual Studio 2022, build, then run .\Keysharp.exe yourscript.ahk from bin\Release\net10.0-windows.

Next Steps

Problems?

Search or report installation problems in the Keysharp issue tracker. Include the Keysharp version, operating system, architecture, install method, and the complete error message.