# How to Use Task Scheduler in Windows 11 URL: https://www.mytechnician.tech/tips/how-to-use-task-scheduler-windows-11/ Published: 2026-08-06 | Author: Ankit Kumar Tags: Windows 11, System, Maintenance, Setup Summary: Task Scheduler runs scripts, backups, and cleanups automatically. Here is how to build a task that actually fires, and how to fix one that silently doesn't. ## The Problem **Task Scheduler** is the piece of Windows that runs things on a schedule — a backup script every night, a cleanup on Fridays, an app at logon. It has been in Windows for decades and it is genuinely powerful. It also has a reputation for tasks that appear to be set up correctly and simply never run. That is almost always down to three settings people skip: the account the task runs as, whether it needs the user to be signed in, and the **Start in** field that scripts depend on. Get those right and it is reliable. Worth knowing too: malware hides here. Knowing your way around Task Scheduler means you can spot something that does not belong. ## Symptoms * A task shows **Ready** but the **Last Run Time** never updates. * **Last Run Result** shows `0x1`, `0x41301`, or `0x80070005`. * The task works when you click **Run** but never fires on schedule. * A script runs fine by hand but does nothing from Task Scheduler. * Unfamiliar tasks appear with random names. ## Step 1: Open Task Scheduler and Get Your Bearings 1. Press **Windows + R**, type `taskschd.msc`, and press Enter. Or search **Task Scheduler** in the Start menu. 2. The left pane is the task library, organised in folders. **Task Scheduler Library** → **Microsoft** → **Windows** holds Windows' own tasks — leave those alone. 3. The middle pane lists tasks and their status; the bottom half shows the selected task's triggers, actions, and history. 4. Create your own tasks in the top-level **Task Scheduler Library**, or make a folder of your own with **Action** → **New Folder**. Keeping yours separate makes them easy to find and audit later. ## Step 2: Understand the Four Tabs Every task is built from the same four parts, and knowing what each does saves most of the troubleshooting. 1. **General** — the name, and critically the security options: which account it runs as, whether it runs when that user is signed out, and whether it runs elevated. 2. **Triggers** — what starts it: a schedule, logon, startup, an idle period, or a specific event log entry. 3. **Actions** — what it does: start a program, with optional arguments and a working directory. 4. **Conditions** — extra gates: only on AC power, only when idle, wake the PC to run. These silently prevent tasks running on laptops more than anything else. 5. **Settings** — retry behaviour, what to do if the PC was off at the scheduled time, and how long to allow before killing it. ## Step 3: Create a Simple Task 1. In the right pane, click **Create Basic Task**. 2. Give it a clear name and description — you will thank yourself in six months. 3. Choose a trigger: **Daily**, **When I log on**, **When the computer starts**, and so on. 4. Choose **Start a program** as the action, then browse to the program or script. 5. Click **Finish**, then tick **Open the Properties dialog** so you can adjust the settings in Step 4. 6. Test it immediately: right-click the task → **Run**. If it fails here, it will never work on schedule. ## Step 4: Set the Options That Make It Actually Run This is where most tasks go wrong. Right-click your task → **Properties** → **General**. 1. **Run whether user is logged on or not** — required for anything that must run overnight or on a locked machine. Windows asks for the account password when you save. 2. **Run with highest privileges** — required for anything touching system folders, services, or the registry. Without it you get `0x80070005`: [fix error 0x80070005](https://www.mytechnician.tech/tips/fix-error-0x80070005-access-denied-windows-11/). 3. **Configure for: Windows 10** — this is correct on Windows 11 too; the list has not been renamed. 4. On the **Conditions** tab, untick **Start the task only if the computer is on AC power** for laptop tasks that should run on battery. 5. On the **Settings** tab, tick **Run task as soon as possible after a scheduled start is missed** so a task does not simply skip when the PC was asleep. 6. Tick **If the task fails, restart every** and set a sensible retry count. ## Step 5: Run a PowerShell or Batch Script Correctly Scripts fail from Task Scheduler far more often than programs do, and it is always the same three details. 1. Set **Program/script** to the interpreter, not the script: ``` powershell.exe ``` 2. Put the script in **Add arguments**, quoting the path: ``` -NoProfile -ExecutionPolicy Bypass -File "C:\Scripts\backup.ps1" ``` 3. Set **Start in** to the script's folder — with no quotes, which is a genuine quirk of this field: ``` C:\Scripts ``` A script that uses relative paths fails silently without this. 4. For a batch file, set **Program/script** to `cmd.exe` and arguments to `/c "C:\Scripts\job.bat"`. 5. Use full absolute paths inside the script itself. The task's environment is not your interactive session's. ## Step 6: Read the History When Something Fails 1. Select the task and open the **History** tab at the bottom. If it says history is disabled, click **Enable All Tasks History** in the right pane — it is off by default. 2. Check **Last Run Result** in the task list and match it: | Result | Meaning | |---|---| | `0x0` | Ran successfully | | `0x1` | The program returned an error — usually a bad path or arguments | | `0x41301` | Currently running | | `0x41303` | Has never run | | `0x80070002` | File not found — check the path and **Start in** | | `0x80070005` | Access denied — tick **Run with highest privileges** | 3. For deeper detail, cross-reference **Event Viewer** → **Applications and Services Logs** → **Microsoft** → **Windows** → **TaskScheduler**: [how to use Event Viewer](https://www.mytechnician.tech/tips/how-to-read-event-viewer-find-crash-cause/). 4. Have the script write its own log file — the fastest way to see what it did when nobody was watching. ## Step 7: Audit Tasks You Did Not Create Scheduled tasks are a favourite persistence mechanism for malware and adware, because they survive reboots and attract no attention. 1. Look through **Task Scheduler Library** for entries with random names, or ones pointing at `%TEMP%`, `%APPDATA%`, or a folder you do not recognise. 2. Check each task's **Actions** tab to see exactly what it launches. 3. Genuine Microsoft tasks live under **Microsoft** → **Windows**. Anything suspicious at the top level deserves scrutiny. 4. **Disable** rather than delete while investigating, so you can put it back. 5. Follow up with a full scan: [remove a virus or malware from Windows 11](https://www.mytechnician.tech/tips/remove-virus-malware-windows-11/) and [remove a browser hijacker](https://www.mytechnician.tech/tips/remove-browser-hijacker-search-redirect/). ## Step 8: Manage Tasks From the Command Line Faster than the GUI once you know what you want, and scriptable. 1. List everything in a readable table: ``` schtasks /query /fo TABLE ``` 2. Show one task in full detail: ``` schtasks /query /tn "My Backup" /v /fo LIST ``` 3. Run a task immediately: ``` schtasks /run /tn "My Backup" ``` 4. Create one in a single command: ``` schtasks /create /tn "My Backup" /tr "powershell.exe -File C:\Scripts\backup.ps1" /sc daily /st 02:00 /rl HIGHEST ``` 5. Export a task as XML so you can restore or copy it to another PC: ``` schtasks /query /tn "My Backup" /xml > C:\backup-task.xml ``` 6. Run these from **Terminal (Admin)** — creating elevated tasks needs elevation. ## What Not to Do * **Don't modify or delete tasks under Microsoft → Windows.** They handle defragmentation, updates, and maintenance; breaking them causes problems that are hard to trace back. * **Don't store passwords in scripts** that a scheduled task runs. Use **Run whether user is logged on or not**, which stores the credential in Windows' own vault: [use a password manager safely](https://www.mytechnician.tech/tips/use-a-password-manager-safely/). * **Don't use Task Scheduler to launch apps at logon** when the Startup folder will do. Simpler is easier to maintain: [disable startup programs](https://www.mytechnician.tech/tips/disable-startup-programs-speed-up-boot/). * **Don't leave a task set to retry every minute indefinitely** after a failure. A failing task on a tight retry loop will fill logs and waste CPU. ## Still Not Working? If a task runs manually but never on schedule, work through them in order: the trigger's next-run time, the **Conditions** tab, the account it runs as, and whether the PC is actually awake at that time. If the PC sleeps, tick **Wake the computer to run this task** on the Conditions tab and confirm the power plan allows wake timers: [fix sleep and hibernation not working](https://www.mytechnician.tech/tips/fix-sleep-hibernation-not-working-windows-11/). Related: [set up automatic backups](https://www.mytechnician.tech/tips/set-up-automatic-backups/), [clean junk files and optimise your PC](https://www.mytechnician.tech/tips/clean-junk-files-optimize-pc/), and [how to install WSL on Windows 11](https://www.mytechnician.tech/tips/how-to-install-wsl-windows-11/). --- Source: https://www.mytechnician.tech/tips/how-to-use-task-scheduler-windows-11/ — My Technician, free Windows 10/11 troubleshooting guides. More guides: https://www.mytechnician.tech/llms.txt