What your clipboard is and why you might want to clear it
Your clipboard is temporary storage on your computer that holds whatever you last copied or cut. When you press Ctrl+C (or Cmd+C on Mac), you send text, an image, or a file path to the clipboard. When you press Ctrl+V, you paste it somewhere else. The clipboard keeps only one thing at a time — the newest copy replaces what was there before.
You might want to clear your clipboard for privacy reasons. If you copied a password, a bank account number, or a sensitive document name, that information stays in your clipboard until you copy something else or shut down your computer. If someone else uses your computer, they could paste what you copied. Clearing the clipboard removes that risk.
On most computers, restarting also clears the clipboard automatically. But if you want to clear it without restarting, the steps depend on whether you use Windows, Mac, or Linux.
Key Takeaways
- Your clipboard holds the last thing you copied until you copy something new or restart your computer.
- On Windows, you can clear the clipboard by opening Command Prompt and typing a specific command, or by using the Clipboard History tool in Settings.
- On Mac, you can clear the clipboard by copying a blank space or using the Terminal app.
- Restarting your computer clears the clipboard on any operating system without any extra steps.
- Clearing your clipboard removes sensitive information like passwords or account numbers from temporary storage.
How to clear the clipboard on Windows
Windows offers two main routes: the Command Prompt method and the Clipboard History tool. The Command Prompt method is faster if you just want to clear it once.
To use Command Prompt, press the Windows key and type "cmd" into the search box. Open Command Prompt (the black window that appears). Type this exactly: echo off | clip and press Enter. This copies nothing to your clipboard, which clears whatever was there. You can close Command Prompt after that.
If you want to see what is in your clipboard history and delete specific items, use the Clipboard History tool instead. Press Windows key + V to open Clipboard History. You will see a list of everything you have copied recently. Click the X next to any item to delete it, or click "Clear all" at the bottom to remove everything at once. Note that Clipboard History is only available on Windows 10 version 1809 and later, and on Windows 11.
How to clear the clipboard on Mac
On Mac, the simplest method is to copy a blank space. Open any text editor (like Notes or TextEdit), press the spacebar once, select that space, and copy it with Cmd+C. This replaces whatever was in your clipboard with a single empty space.
If you prefer using the Terminal app, you can also clear the clipboard that way. Open Terminal (find it in Applications > Utilities), type pbcopy < /dev/null and press Enter. This sends nothing to your clipboard, clearing it completely. Close Terminal when you are done.
How to clear the clipboard on Linux
Linux systems use a clipboard manager called xclip or xsel, depending on which desktop environment you have. Open a terminal window and type one of these commands:
For xclip: xclip -selection clipboard < /dev/null
For xsel: xsel --clipboard --clear
If you are not sure which one your system uses, try the xclip command first. If it does not work, try xsel. Either way, press Enter and your clipboard will clear. You can close the terminal after that.
Why restarting your computer clears the clipboard
The clipboard exists in your computer's active memory (RAM), not on your hard drive. When you restart, your computer clears all active memory to start fresh. This is why shutting down and turning your computer back on always clears the clipboard, no matter what operating system you use.
If you have sensitive information copied and you want it gone when ready, restarting is the most reliable method across all devices. It takes longer than the command-line methods above, but it guarantees the clipboard is empty.
When clipboard clearing actually matters for privacy
Clearing your clipboard is most useful if you have copied a password, a PIN, a credit card number, a Social Security number, or a bank account number. These are things that would be dangerous if someone else pasted them into an email or a document.
For everyday text like a web address or a sentence you copied from an article, clearing the clipboard is less critical — but it does not hurt. If you share your computer with other people, clearing the clipboard after copying sensitive information is a straightforward habit that reduces risk.
Note that clearing your clipboard does not protect information you have already pasted somewhere. If you pasted a password into an email draft, clearing the clipboard does not remove it from that email. You would need to delete the email itself.
Frequently Asked Questions
Does clearing the clipboard delete files I cut and pasted?
No. When you cut a file and paste it somewhere, the file moves to the new location. Clearing the clipboard afterward does not bring it back or undo the move. The clipboard only holds a temporary copy of what you cut — once you paste it, the file itself is no longer tied to the clipboard.
Can someone see what is in my clipboard if my computer is locked?
Not through normal means. If your computer is locked with a password, someone cannot access your clipboard without unlocking it first. However, if you leave your computer unlocked or logged in, anyone sitting at it can press Ctrl+V to paste whatever is in your clipboard into a document or email.
Does closing a program clear the clipboard?
No. Closing a program does not affect the clipboard. Whatever you copied last stays in the clipboard until you copy something else, clear it manually, or restart your computer. The clipboard is separate from any single program.
Is there a way to prevent copying sensitive information to the clipboard?
Some password managers (like 1Password or Bitwarden) have an option to copy passwords to the clipboard for only a set number of seconds — usually 30 or 60 seconds — before automatically clearing it. Check your password manager's settings to see if this feature is available. For other sensitive information, the safest approach is to copy it, paste it when ready where you need it, and then clear the clipboard right away.