Medium Operating Systems ✓ Solution Verified by Community (0+ upvotes)

How to fix error error-not-same-device in Windows 11

ERROR_NOT_SAME_DEVICE = 17

65% success rate
👥 0+ users verified
📅 Updated: 2026-08-12
⏱️ 10 min read
Fix based on community reports and expert analysis. Last verified: 2026-08-12 · How we verify fixes
Error Codeerror-not-same-device
Affected SystemWindows 11 (Microsoft)
DifficultyMedium
Estimated Time10 min

Solution Steps

  1. 1 Press Windows key + R, type 'cmd', and press Enter to open Command Prompt. This gives you a command-line interface to test and fix the issue.
  2. 2 Identify the command that caused the error. If you used 'rename' or 'ren' to move a file across drives, understand that this command only works within the same directory. For cross-drive moves, you must use 'move' or 'copy' followed by 'del'.
  3. 3 To move a file from C: to D:, use the 'move' command. For example, type 'move C:\source\file.txt D:\destination\' and press Enter. This moves the file to the new drive, preserving the file. If you need to keep the original, use 'copy' instead.
  4. 4 If you are writing a script, replace any 'ren' commands that cross drives with 'move' or 'copy'. For instance, change 'ren C:\file.txt D:\file.txt' to 'move C:\file.txt D:\file.txt'. This ensures the operation works as intended.
  5. 5 If the error occurs in a programming language like Python or C#, use the appropriate file move function, such as 'shutil.move' in Python, which handles cross-device moves correctly. This avoids the limitation of rename operations.
  6. 6 If you are using a GUI and see this error, try dragging the file to the new location while holding the Shift key to force a move. Alternatively, cut and paste the file. This bypasses the command-line limitation.

🔍 Didn't work? Enter your GPU and CPU for hardware-specific advice:

🔧 Still having issues?

Describe your exact problem to Error Buddy and get a personalized fix in seconds.

🛠️ Try Error Buddy — It's Free