How to pin a batch file to Windows 10 or 11 taskbar or start menu

This step-by-step tutorial will show you how to pin a batch (.bat) file to the taskbar or start menu in Windows 10 and 11.

How to pin a batch file to Windows 10 or 11 taskbar or start menu (method 1)

  1. Right-click on your desktop.
  2. Go to New.
  3. Click Shortcut.
    Create a new shortcut on desktop in Windows 11
  4. In the 'Create Shortcut' window, click Browse.
    Create Shortcut Browse button
  5. In the next window, select the batch file you want to pin to the taskbar or start menu.
  6. Click OK.
    Select the batch file you want to pin to the taskbar or start menu
  7. Make sure the batch file's path is between double quotation marks ("") in the location field (e.g., "C:\Users\MX\Documents\CMD.bat").
  8. In the location field, type cmd /c followed by a space before the batch file's path (e.g., cmd /c "C:\Users\MX\Documents\CMD.bat").
    Create a shortcut for batch file in Windows 10 or 11
  9. Click Next.
  10. Type a name for the shortcut.
    Type a name for the shortcut
  11. Click Finish.
  12. Right-click the shortcut.
  13. Click Pin to Start or Pin to taskbar. On Windows 11, you first need to click Show more options and then click Pin to taskbar.
    Pin a batch file to Windows 10 or 11 start menu or taskbar

The batch file is now pinned to the Windows 10 or 11 start menu or taskbar.

You can delete the new shortcut from your desktop because you don't need it anymore.


How to pin a batch file to Windows 10 or 11 taskbar or start menu (method 2)

  1. Open File Explorer.
  2. Locate the batch file you want to pin to the taskbar or start menu.
  3. Right-click the batch file.
  4. On Windows 11, click Show more options.
    Show more options for batch file
  5. Go to Send to.
  6. Click Desktop (create shortcut)
    Create batch file desktop shortcut
  7. Go to your desktop.
  8. Right-click the new shortcut.
  9. Click Properties.
    Batch file shortcut properties
  10. Make sure the batch file's path is between double quotation marks ("") in the 'Target' field (e.g., "C:\Users\MX\Documents\CMD.bat").
  11. In the 'Target' field, type cmd /c followed by a space before the batch file's path (e.g., cmd.exe /c "C:\Users\MX\Documents\CMD.bat").
    Batch file shortcut target
  12. Click Apply.
  13. Click OK.
  14. To pin the batch file shortcut to the taskbar or start menu, right-click the shortcut.
  15. Click Pin to Start or Pin to taskbar. On Windows 11, you first need to click Show more options and then click Pin to taskbar.
    Pin a batch file to Windows 10 or 11 start menu or taskbar

The batch file is now pinned to the Windows 10 or 11 start menu or taskbar.

You can delete the new shortcut from your desktop because you don't need it anymore.


Windows


Related:

How to pin a folder to the taskbar in Windows 10 and 11

How to customize the Windows 11 taskbar (step-by-step guides)

Windows 10 or 11 taskbar icons missing? Try these solutions!