Control the Num Lock Key from the Command Line
Tired of your Num Lock key being off when you start your computer? NumLock is a lightweight, no-frills command-line tool that allows you to easily toggle the Num Lock key on or off with a simple command. There is no user interface -- just run the program and it will instantly perform the task.
Add NumLock to your Windows Startup folder, login scripts, or batch files to ensure the Num Lock key is always in the state you want. It is the simplest way to automate Num Lock control across workstations, servers, and remote desktop environments.
Who Is This For?
- Users who prefer Num Lock always ON -- Add NumLock to your Startup folder and never worry about toggling the key again.
- IT administrators -- Deploy NumLock across workstations via login scripts or Group Policy to enforce consistent keyboard behavior.
- Script developers -- Integrate Num Lock control into batch files, scheduled tasks, or automated workflows.
- Remote desktop users -- Ensure the Num Lock key is in the correct state when connecting to remote machines.
Key Features
On/Off/Toggle
Pass "on" or "off" on the command line to set the Num Lock state explicitly. Run without arguments to toggle the current state.
Instant Execution
Launches, sets the Num Lock state, and exits in under a second. No delay, no prompts, no process left running.
Script-Friendly
Add NumLock to any login script, batch file, Windows Startup folder, or Group Policy startup sequence for hands-off automation.
Fully Portable
Single executable with no installer, no registry modifications, and no dependencies. Copy to a USB drive or network share and run anywhere.
Self-Closing
NumLock automatically exits after setting the key state. No process left running, no memory consumed, no cleanup needed.
Lightweight
Tiny executable that takes up virtually no disk space. No frameworks, no runtimes, no additional files required.
Command Line Options
NumLock.exe on|off
- on -- Turns Num Lock ON.
- off -- Turns Num Lock OFF.
- (no argument) -- Toggles the current Num Lock state.
Startup automation: Press Win+R, type shell:startup and press Enter. Create a shortcut to NumLock.exe in this folder with your desired parameter (e.g., target: C:\Path\To\NumLock.exe on).
See DEMO.BAT included in the download for a complete demo of all features.
Windows Compatibility
Win 11
Win 10
Win 8
Win 7
Download NumLock
Support NumLock Development
NumLock is completely free. If this tool has saved you time, consider making a donation to help fund continued development and new features.