Compare two folders without copying anything (robocopy /L)

Run robocopy in list-only mode to preview exactly which files would be copied, i.e. which files are new or different between two folders.

WindowsFilesrobocopycompareLow risk
Run: robocopy "C:\Folder1" "D:\Folder2" /L /E /NJH /NJS — it only lists files, nothing is copied.

01Command

Command
$ robocopy "C:\Folder1" "D:\Folder2" /L /E /NJH /NJS

02What it does

The /L switch makes robocopy simulate the operation: every file it lists is one that would be copied, meaning it's new or changed in Folder1 compared to Folder2. /E walks all subfolders, while /NJH and /NJS hide the header and summary lines for a clean list. This is a safe, built-in way to diff two folder trees.

03Risk

RiskLow risk
!Warning: Nothing is written with /L, but double-check the switches before dropping it — the same command without /L would really copy files.

04Undo

✓No undo needed — this command does not change persistent state.

05Sources

  • robocopy (Windows Commands)
    Microsoft Learn · vendor-doc · 2026-09-17
    Evidence: Official reference: /l lists files without copying, timestamping or deleting; /njh and /njs suppress the job header and job summary.
  • Robocopy - Robust file and folder copy
    SS64.com · technical · 2026-09-17
    Evidence: Documents /L (List only - don't copy, timestamp or delete any files) and /NJH /NJS (no job header/summary) switches.

Last verified: 2026-09-19 · Category: Files & Folders

06Related solutions