Add Shortcuts to Your Windows Startup Folder to Automatically Run Your Most Important Scripts
Every AutoHotkey user keeps a few favorite scripts at hand. Some people put them in one big master AHK file—auto-loading it when Windows boots. Others may use Windows Task Scheduler to initiate the apps. (See the “Windows Task Scheduler to Elevate Script Privileges” section of Chapter 16.1.4 of Jack’s Motley Assortment of AutoHotkey Tips.) Even more, add individual shortcuts to the Windows Startup folder for the preferred scripts. Each method has its advantages and disadvantages. In this blog, I visit AutoHotkey techniques for adding shortcuts to the Windows Startup folder.
Recently, a reader pointed out that the link for the AutoStartupToggle.ahk script at the Free AutoHotkey Scripts page pointed to the wrong script. I repaired the link then took a closer look at the script.
After selecting an AutoHotkey script (.ahk) or compiled app (.exe) in Windows File Explorer, the
Ctrl+Win+3 key combination creates a shortcut in the Startup folder—auto-loading the script on bootup. If the matching shortcut exists in the Startup folder, that same Hotkey combination removes it. While this barebones routine works fine, I began considering the implications of using the Startup folder for all my regular scripts. This prompted me to dig deeper into the possibilities.