You can run an app or script at logon with Task Scheduler in Windows 10. Task Scheduler is a powerful built-in tool that allows you to automate routine tasks on your device. Using it, you can make any app to run by a schedule. You can also use Task Scheduler to run programs when a specific event occurs.
The Task Scheduler has a graphical MMC version (taskschd.msc) which is the most popular tool managing tasks.
If you are not familiar with creation of tasks in Task Scheduler, we have a good tutorial here: Create elevated shortcut to skip UAC prompt in Windows 10.
Task Scheduler is able to monitor a variety of system events, and attach tasks to them. When an event occurs, it will run the associated app. A good example of how it works is the "Play logon sound" post here on Winaero. This post will show you in detail how to create a task in Windows 10 Task Scheduler to run an app or script at logon for specific or all users.
How to Run App or Script at Logon with Task Scheduler in Windows 10
- Press the Win + R keys on the keyboard and type
taskschd.mscinto the Run box, then hit Enter.
- Select Task Scheduler Library in the left pane.
- In the right pane, click on Create task under Actions.
- In the General tab, specify the desired name for you task, e.g. My logon task.
- By default, the task will use privileges and ownership of the current user. If you want to make it run for all users instead, click on the Change User or Group button, and specify the desired user or group in the next dialog. E.g. you can select the Users group, so it will be available for all users of your computer.
- Switch to the Triggers tab, and click on the New... button.
- Select At log on in the Begin the task drop menu of the New Trigger dialog.
- Select Any user to make the task run for all users. Alternatively, you can select Specific user and click on the Change User to set the user account the task will do its work for.
- Click on the OK button to close the New Trigger dialog and create the logon trigger for your task.
- Now, go to the Actions tab and click the New... button.
- Select Start a program for the action, specify the full path to the executable file or batch file you want to start at log on in Windows 10, and its command line arguments (if any), and click OK.
- Finally, switch to the Conditions tab, and uncheck the Start the task only if the computer is on AC power option. This is important for laptops as the task does not start by default when your device is running on battery power.
- Click OK in the Create Task window. You will now see a new task in the Task Scheduler library.
You are done! It is now safe to close the Task Scheduler app.
Note: At the step 5 you define access permissions for the task, i.e. task availability. At the step 8 you specify for which exactly user the task will start.
Winaero greatly relies on your support. You can help the site keep bringing you interesting and useful content and software by using these options:
If you like this article, please share it using the buttons below. It won't take a lot from you, but it will help us grow. Thanks for your support!