guide · static export
Productivity

Set Up AutoHotkey v2 to Create Keyboard Shortcuts on Windows 11

Install AutoHotkey v2 and create a simple keyboard shortcut script.

by@guidox updated:10/29/26 time:15 min level:Intermediate works on:Windows 11 25H2 x64, AutoHotkey v2 tools:AutoHotkey v2
TL;DR

Install **AutoHotkey v2**, create a script, and verify a custom shortcut works.

Before you start

Requirements

  • Windows 11 25H2 x64
  • AutoHotkey v2 installer from https://www.autohotkey.com/
  • Permission to install desktop software
Step by step

Instructions

01

Install AutoHotkey

Download the **AutoHotkey v2** installer from the official website. Complete the installation using the normal setup options.

02

Create a script

Right-click the desktop and create a new **AutoHotkey Script** where the shell option is available. Otherwise create a text file with the proper script extension.

Shortcuts.ahk
03

Edit the script

Open the script in a text editor. Add a version directive and a shortcut that opens Notepad.

#Requires AutoHotkey v2.0
^!n::Run('notepad.exe')
04

Run the script

Save the file and double-click it. Confirm that the **AutoHotkey** script icon appears in the notification area.

05

Test the shortcut

Press the assigned shortcut. Verify that **Notepad** opens.

Ctrl + Alt + N
06

Manage script startup

Decide whether the shortcut should run manually or at sign-in. Use the Windows Startup folder only if automatic launching is desired.

tipUse unique shortcuts to avoid conflicts with existing application hotkeys.
Troubleshooting

Common issues

The script reports a syntax error.

Confirm the file uses AutoHotkey v2 syntax and that the installed interpreter is version 2.

The shortcut does nothing.

Check whether the script is running and whether another application has captured the shortcut.

FAQ

Frequently asked

Can AutoHotkey v1 scripts run in v2?

Many require changes because v2 uses different syntax.

Can scripts start with Windows?

Yes. Place a script shortcut in the user Startup folder.

How to undo this

Exit the running script, delete the script file and any startup shortcut, and uninstall **AutoHotkey** through Installed apps.

Interactive version: checklist, feedback, related guides →

Free · no account needed · tracks your progress