TL;DR
This guide shows you how to automatically backup your computer to a Network Attached Storage (NAS) device even if the drive mapping isn’t permanent. We’ll use a scheduled task and a network path instead of relying on a drive letter.
Step-by-step Guide
- Understand the Problem: Drive letters assigned to mapped NAS drives can change, especially after restarts or if other devices connect. This breaks automated backups that rely on a specific drive letter. We’ll avoid this by using the UNC path (network address) directly.
- Example UNC Path:
\NAS_SERVERSharedFolder
- Example UNC Path:
- Test Network Access: Before setting up any automation, make sure you can access the NAS share from your computer using its UNC path. Open File Explorer and type the UNC path into the address bar. You should see the contents of the shared folder.
- If prompted for credentials, enter your NAS username and password.
- Create a Backup Script (Optional): If you’re using backup software that doesn’t directly support UNC paths, you might need to create a simple script.
- For example, with Robocopy (built into Windows):
robocopy C:SourceFolder \NAS_SERVERSharedFolder /MIRThis command mirrors the contents of
C:SourceFolderto your NAS share.
- For example, with Robocopy (built into Windows):
- Create a Scheduled Task: We’ll use Windows Task Scheduler to run the backup automatically.
- Open Task Scheduler (search for it in the Start Menu).
- Click ‘Create Basic Task…’ on the right-hand side.
- Give your task a name and description (e.g., “NAS Backup”).
- Choose a trigger: How often do you want to backup? (Daily, Weekly, etc.).
- Select ‘Start a program’.
- In the ‘Program/script’ field:
- If using Robocopy directly:
robocopy - If using a script file (.bat or .ps1): Browse to and select your script.
- If using Robocopy directly:
- In the ‘Add arguments (optional)’ field:
- If using Robocopy directly:
C:SourceFolder \NAS_SERVERSharedFolder /MIR(replace with your actual paths) - Leave blank if you’re running a script file that already contains the arguments.
- If using Robocopy directly:
- Click ‘Finish’.
- Configure Task Settings: After creating the task, double-click it to open its properties.
- Go to the ‘General’ tab.
- Check ‘Run whether user is logged on or not’ and ‘Run with highest privileges’. You will be prompted for your Windows password.
- In the ‘Configure for:’ dropdown, select your version of Windows.
- Test the Task: Right-click the task in Task Scheduler and click ‘Run’. Check that the backup completes successfully.
- Verify files are copied to the NAS share.
- Check the ‘History’ tab for any errors.
- Troubleshooting: If the task fails:
- Double-check your UNC path is correct and accessible.
- Ensure the user account running the task has permissions to access the NAS share.
- Review the Task Scheduler History for specific error messages.
- If using a script, test it manually from the command prompt to identify any issues.

