There are many situations where you might need a text list of files and folders—for documentation, inventory, sharing with teammates, or quick auditing. Instead of typing names manually, Windows 11 gives you several built-in ways to copy file and folder names directly to the clipboard, no third-party tools required.
In this guide, we’ll cover all practical methods, from quick right-click options to command-line and PowerShell approaches, including how to export names with or without paths.
1. Copy File and Folder Names Using File Explorer (Quickest)
This is the fastest method for basic lists.
- Open File Explorer and navigate to the target folder.
- Select the files and folders you want:
- Press Ctrl + A to select everything
- Or hold Ctrl and click specific items
- Hold Shift, then right-click on any selected item.
- Click Copy as path.
- Paste (Ctrl + V) into Notepad, Word, Excel, or any editor.
2. Copy Only File and Folder Names (Without Paths)
If you want names only, use a simple rename trick.
- Select all files and folders in File Explorer.
- Right-click the first selected item and choose Rename.
- Press Ctrl + C (do not rename anything).
- Paste into a text editor.
3. Copy File and Folder Names Using Command Prompt
This method is reliable and customizable.
- Open the target folder in File Explorer.
- Click the address bar, type
cmd, and press Enter. - In Command Prompt, run:
dir /b | clip
4. Copy File Names Only (Exclude Folders)
If you want files only, use:
dir /b /a-d | clip
This excludes directories and copies only file names.
5. Copy Folder Names Only
To copy folders only, run:
dir /b /ad | clip
This is useful for directory structure documentation.
6. Copy File and Folder Names with PowerShell (Advanced)
For more control, PowerShell is ideal.
- Open the folder.
- Hold Shift, right-click inside the folder, and select Open in Terminal.
- Run:
Get-ChildItem | Select-Object -ExpandProperty Name | Set-Clipboard
7. Copy File Names with Full Paths Using PowerShell
If you need full paths, use:
Get-ChildItem | Select-Object -ExpandProperty FullName | Set-Clipboard
This is especially useful for scripting or audits.
8. Export File and Folder Names to a Text File
If you want a saved list instead of clipboard data:
Command Prompt
dir /b > filelist.txt
PowerShell
Get-ChildItem | Select Name | Out-File filelist.txt
The file will be created in the current folder.
Wrapping Up
Copying a list of file and folder names in Windows 11 is simple once you know the right method. Whether you prefer File Explorer shortcuts, Command Prompt, or PowerShell, Windows gives you multiple built-in ways to copy exactly what you need—names only, folders only, or full paths—straight to the clipboard.
Once you get used to these methods, creating file lists becomes a quick, one-step task instead of a manual chore.