How to Schedule a Batch File to Run in Windows 11/10 Using Task Scheduler

Plus the reason why you should do this

Batch files are a great way to run tasks on your PC automatically. If you’d like to schedule a batch file to run automatically,use your Windows 10 or Windows 11 PC’s Task Schedulerutility.

Task Scheduler lets you trigger your batch file to run at a specific time or when a specified event occurs. You also get loads of configurable options to define how the file runs. We assume you already have thebatch filecreated, so in this article, we’ll show you how to schedule that batch file to run.

Why Schedule Batch Files on Your Windows PC

There are countless reasons to schedule a batch file on your PC. One good example is creating a batch file that clears your Downloads folder. For example, you can run this batch script to remove your Downloads every week.

Similarly, you can make ascript that automatically launches your favorite programswhen you turn on your computer. When it comes to automating tasks with batch files, your creativity is the only limit.

Schedule Batch Files With Windows Task Scheduler

Place your bat file in an appropriate location on your PC. If you move the file after creating the task, the task will stop working, so place it somewhere you’d like it to stay. Start the process by opening your Microsoft Windows PC’sStartmenu, searching forTask Scheduler, and selecting that tool in the search results.

SelectAction>Create Basic Taskon the Task Scheduler’s window. You’ll use this task to run your batch file.

Select theNamefield and type a name for your task. The name could be anything that helps you recognize your task. Then, optionally, enter a description for the task and selectNextat the bottom.

You’ll choose when and how often your batch file runs in the following window. The options that you can choose from are:

In most cases, you’ll choose one of the first four options. Once you’ve made a selection, clickNextat the bottom.

We’ll choose theWeeklyoption for the demonstration.

You’ll choose when to run your batch file on the window that opens. Depending on what you selected in the previous step, you’ll see appropriate options.

Since we choseWeeklyin the previous step, we’ll select the start date and time on this window. Then, we’ll click theRecur everybox and pick when the task reoccurs, and then choose the day of the week.

Finally, we’ll selectNextat the bottom.

Task Scheduler will now ask what you’d like to run at the specified time. ChooseStart a programsince you want to run a batch file. Then, selectNextat the bottom.

Click theBrowsebutton on the following screen and choose the batch file to run. Optionally, add arguments and a start in time. Then, selectNextat the bottom.

You’ll see your newly created task’s summary on your screen. Click theFinishbutton if this summary looks good to you.

Task Scheduler has saved your task, and your task will run at the specified date and time.

Edit or Delete a Batch File Task in Task Scheduler on Windows

Task Scheduler allows you to edit your task even after creation. This way, you can change what, when, and how often the batch file runs. You can also delete the task if you no longer want to run your file.

Start theTask Schedulerutility on your Windows 10 or Windows 11 PC and select theTask Scheduler Libraryon the left. In the middle pane, right-click your task and choosePropertiesfrom the menu to edit the task.

Use the various tabs on thePropertieswindow to change your task’s options. For example, select theTriggerstab if you’d like to change the schedule for your batch file. You can then choose the current schedule, clickEdit, and then specify the new schedule for your file.

Similarly, open theActionstab to change what batch file runs when your task is launched. Again, select your current batch file, clickEdit, and then select the new file if you want.

Lastly, you can get rid of your task so that your batch file doesn’t automatically run. You can do this by right-clicking your task on Task Scheduler’s main window and choosingDeletefrom the menu.

ChooseYesin the prompt to delete your task. You can always create a new task to run the same or a different file at scheduled intervals.

Keep in mind that your PC must be on for Task Scheduler to run your task. Yourbatch file won’t runif your PC is off when the scheduled time comes.

Mahesh has been obsessed with technology since he got his first gadget a decade or so ago. Over the last few years, he’s written a number of tech articles on various online publications including but not limited to MakeTechEasier and Android AppStorm.Read Mahesh’s Full Bio

Leave a Reply

Your email address will not be published.Required fields are marked*

Comment*

Name*

Email*

Website

Welcome to Help Desk Geek- a blog full of tech tips from trusted tech experts. We have thousands of articles and guides to help you troubleshoot any issue. Our articles have been read over 150 million times since we launched in 2008.

HomeAbout UsEditorial StandardsContact UsTerms of Use

Copyright © 2008-2024 Help Desk Geek.com, LLC All Rights Reserved