What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
To clear Linux’s documented filesystem caches for a test or debugging run, use sudo sh -c 'sync; echo 3 > /proc/sys/vm/drop_caches'. The value 3 requests dropping clean page-cache data and reclaimable filesystem metadata caches; it does not clear every application’s cache or free memory used by running processes. Linux normally reclaims these caches automatically when memory is needed, so routine cache clearing is usually unnecessary.
What the command clears—and what it does not
The kernel’s /proc/sys/vm/drop_caches interface applies to clean page-cache data and reclaimable slab objects such as dentries and inodes. It does not free dirty objects. The kernel describes this as a non-destructive operation: it discards eligible cached objects, which can later be rebuilt as needed. See the Linux Kernel Documentation for /proc/sys/vm/.
This is not a universal “clear all Linux cache” command. It does not empty application-managed caches or release memory held by processes. The interface is documented by the kernel; distributions may ship different kernel versions, so consult your distribution’s kernel documentation if you need version-specific confirmation.
Choose which cache category to drop
| Value | What it requests | When it may fit |
|---|---|---|
1 |
Page cache | Testing or debugging behavior involving cached file contents. |
2 |
Reclaimable slab objects, including dentries and inodes | Testing or debugging filesystem metadata caches. |
3 |
Both categories above | A test that needs both documented groups dropped. |
These values are the documented controls; they are not measures of how much memory will be freed. For details, see the kernel’s drop_caches documentation and the Linux man-pages project’s proc_sys_vm(5).
Do these 3 things before closing this tab:
1Repair Windows errors before they cause bigger problems2Scan for outdated or missing drivers - takes under a minute3Clear out junk files and repair common Windows errors#1 Best Overall
Run the command
- Save work and close anything that should not be interrupted. Dropping caches is not destructive to stored data, but subsequent access may be slower while the kernel rebuilds cached data.
- Run the appropriate command in a terminal. For both documented categories, including the recommended sync first:
sudo sh -c 'sync; echo 3 > /proc/sys/vm/drop_caches'
For page cache only, usesudo sh -c 'sync; echo 1 > /proc/sys/vm/drop_caches'. For reclaimable dentries and inodes only, usesudo sh -c 'sync; echo 2 > /proc/sys/vm/drop_caches'. - Enter your password if prompted. A successful write typically produces no terminal output. The command makes a request to drop eligible objects; it does not promise a particular amount of memory reclaimed.
Why use sync and sudo sh -c?
sync writes pending dirty data before the drop request, increasing the set of clean objects eligible to be dropped. The shell redirection also matters: sudo echo 3 > /proc/sys/vm/drop_caches can fail because your unprivileged shell, not echo, opens the procfs file. Running the shell through sudo sh -c elevates the shell that performs the redirection.
Should you clear caches?
Usually, no. A large cache figure by itself is not a reason to clear it: Linux uses memory for caches and automatically reclaims these objects when memory is needed elsewhere. Forcing a drop removes the performance benefit of caching, and rebuilding the caches can consume I/O and CPU. The kernel discourages using drop_caches outside testing or debugging; the man page likewise warns that losing caching benefits can degrade overall performance.
Use it when a test specifically needs a cold filesystem-cache condition, such as investigating filesystem behavior or memory-management behavior. For ordinary memory pressure, investigate the process or memory category involved rather than repeatedly dropping caches. The kernel says these objects are automatically reclaimed when memory is needed elsewhere (kernel documentation).
Troubleshooting
- “Permission denied” or “Read-only file system”: Make sure the command uses
sudo sh -cso the privileged shell performs the redirection. If the write is still rejected, the environment may restrict writes to this kernel interface; do not try to bypass that restriction. - The command prints nothing: That is normal for a successful shell write. No output is not a report of how much cache was dropped.
- Memory usage does not fall as expected: The command only targets clean page cache and reclaimable slab objects. It does not free dirty objects or process memory, and the kernel may reclaim or rebuild caches as workload changes.
- The system feels slower afterward: Cached data and metadata must be fetched or recreated again. This is an expected trade-off, not necessarily a failure; avoid cache drops during ordinary use.
Or skip the browser setup
For a different task—capturing a webpage as an image or PDF—ScreenshotNeo offers a one-request screenshot API. It is not a way to clear Linux filesystem caches. For a screenshot, for example:
Quick wins for a faster PC:
Scan for outdated or missing drivers - takes under a minuteDriver Scan →Clear out junk files and repair common Windows errorsFree Scan →Rank #3
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
See the ScreenshotNeo documentation for API options. Its captures can accept cookie banners and remove known consent platforms, newsletter popups and chat widgets before the shot; bot checks, blank pages and failed loads are not billed. It also has an MCP server for AI agents. The free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000. Sign up for free.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Frequently Asked Questions
Does dropping Linux caches delete files?
No. It requests that eligible clean cached objects be dropped; it does not delete the underlying files.
Will this command clear browser or application caches?
No. Those caches are managed separately by the relevant applications.
Quick Recap
Best Value
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




