The Copy Command
Data backup is crucial. The copy command is the most basic way to back up or duplicate files in the Windows terminal. It allows you to duplicate a file from one location to another.
Usage:copy
[source]
[destination]
[/y]
source
The file you want to copy.
destination
Where you want the copy to go (directory or new filename).
/y
Suppresses the prompt to overwrite an existing destination file.
Real-World Examples
Copy a single file:
Command Prompt
C:\Users\User>copy report.docx report_backup.docx
Copy all text files to a backup folder:
Command Prompt
C:\Users\User>copy *.txt backup\
Knowledge Check
1 / 2What happens if you copy a file to a location where a file with the same name exists?