- Virtual Ram file: Pagefile.sys works as virtual memory and is extremely important for a stable, fast Windows 11/10/7.
- Optimal setting: Find out how you can delete, enlarge, reduce and move the Pagefile.sys via the "Advanced system settings" (and why we do not recommend deactivating it).
- Size and data security: Get tips on the right size depending on usage and how to use the Windows registry to automatically delete them every time you shut down to increase data security.
Quick overview:
What is the large Pagefile.sys in Windows?

Pagefile.sys is something like the hidden hero of Windows 11 / 10 / 7.
This system file, which is often tens of gigabytes in size, is also called a swap file and acts as a virtual working memory: It steps in when the physical working memory (RAM) of your PC reaches its limits.
If you do not have a page file or if it is too small, Windows can become unstable and crash more frequently. Especially if you use many programs at the same time or have memory-intensive applications running.
Windows usually manages the Pagefile.sys automatically and dynamically adjusts its size based on the needs of your system.
Delete, reduce, enlarge, adjust:
Read here how and when you should sometimes change the Pagefile.sys manually to improve your PC performance.
Hidden: Show the Pagefile.sys file in Explorer (instructions)
Where can I find the Pagefile.sys under Windows 11/10/8/7/XP?
Windows stores them in the root directory of your system partition on which the Windows operating system has been installed. Normally this is drive "C:".
But you won't necessarily see it there immediately. This is because this file is hidden by default to prevent accidental changes.
How to display the file in Explorer:
- Open Windows Explorer: Press the
Windows + Ekeys to open Explorer. - Go to 'This PC': Here you will find your hard disks and drives.
- Select 'View' or 'View options': Depending on your version of Windows, you will find this in the menu bar or under the "View" tab.
- Activate 'Show hidden elements': This makes the Pagefile.sys visible, which is normally located in the root directory of drive C:.
- Find & Check: You can now view the file and check its size and other properties.
P.S.: There you'll find two other very large, hidden system files—check out our guides on swapfile.sys and hiberfil.sys to learn what they do and how to optimize them.
Deleting and deactivating Pagefile.sys - a risk?
Many users wonder whether they should delete or deactivate Pagefile.sys in order to save memory or improve performance.
We'll explain why deleting the pagefile isn't a good idea.
And what alternative solutions are available for common problems.
Help, can I delete a huge Pagefile.sys file?
Well, first of all: You cannot simply delete Pagefile.sys.
At least not in Explorer.
It is an important and therefore specially protected system file.
If you try to delete or remove the page file directly in Explorer, Windows prevents this to ensure system stability.
You can only delete or deactivate Pagefile.sys in a roundabout way (see instructions below) - but this involves risks.
Deactivating it can lead to system instability and crashes, not only if your system is under high memory utilization.
According to Microsoft, the Windows system and many applications continuously use your virtual memory, which means this file.
Deactivate Pagefile.sys (not recommended)
Do you want to disable your Pagefile.sys despite the risks?
For example, temporarily in order to subsequently specify a different, larger or faster drive for the location of the virtual memory?
Then you can do this:
- Open Advanced System Settings: Go to the Advanced System Settings in Windows.
- Adjust virtual memory: Click through Advanced > Performance > Settings > Advanced > Virtual Memory > Change—there you'll find the pagefile settings.
- Disable: In the next window, uncheck the box next to "Automatically manage file size for all drives." Then select "No swap file" and confirm your selection.
Remember that this is risky and not recommended.
Data protection: Automatically delete Pagefile.sys on shutdown (instructions)
The automatic deletion of Pagefile.sys at every shutdown can increase security on systems on which sensitive data is processed.
Sensitive data that was temporarily stored in the virtual memory could remain in the file for a long time.
Automatic deletion at every shutdown ensures that this data is no longer accessible at the next start.
Instructions for the registry editor (regedit)
- Open the Registry Editor: Type
regeditin the Windows search bar and open the Registry Editor. - Navigate to the correct key: Go to
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management. - Set ClearPagefileAtShutdown: Change the value of 'ClearPagefileAtShutdown' to '1'.
- From now on Windows 10 will automatically delete the Pagefile.sys every time it is shut down.
Please note the following effects:
- System startup may be slowed down: Deleting the file during shutdown may cause the next startup to take a little longer.
- Use caution: You should only make changes to the registry if you know exactly what you're doing.
Change the size of the Pagefile.sys (reduce and enlarge)
Setting the size of the Pagefile.sys correctly can be crucial to maximize the performance and stability of your PC.
Windows normally sets the size of your file automatically. But there are cases in which a user-defined size can be useful.
When does it make sense to change the size?
Problems with the size of the Pagefile.sys file often occur when there is little available hard drive space—and the file is huge at the same time.
It's not uncommon for it to grow to many gigabytes—sometimes even 40 GB or more.
Or vice versa: it is too small - which leads to performance problems or even Windows blue screens and crashes.
And Windows no longer runs smoothly because the physical RAM is used excessively by computing-intensive applications - now an enlarged Pagefile.sys file provides a remedy.
In these scenarios, a manually defined, user-defined size can help.
But be careful: Reducing its size usually isn't a good idea. It's better to move the Pagefile.sys to a larger drive rather than reduce its size to avoid performance issues.
Enlarge and reduce Pagefile.sys (instructions)
This way you can reduce and enlarge the Pagefile.sys without unnecessarily burdening your hard disk:
- In Windows, go to "Advanced system settings".
- Then select the "Advanced" tab and click on "Settings" under "Performance" .
- In the "Advanced" tab under Virtual memory, click on "Change" '.
- In the next window, uncheck the "Automatically manage file size for all drives" box.
- Select the desired size in megabytes (MB). Important: Always enter the same values for "Initial Size" and "Maximum Size" (a dynamic size for this file would require more processing power and put a greater strain on your hard drive).
- Restart Windows to apply the changes.
Remember that the correct size of the Pagefile.sys depends on many factors, such as your RAM, your hard disk size and your type of use.
What is the optimum size?
We recommend that the size of the Pagefile.sys is only not managed by the system in exceptional cases (see above).
If you specify a custom size, the following recommendations will help.
Recommended size for standard users with 8GB or 16GB RAM
For everyday Windows use with Office, videos and surfing, it is often sufficient if the Pagefile.sys is around 1.5 to 3 times the size of your RAM.
Recommended size for power users with 32GB or 64GB RAM
During intensive use, such as video editing or gaming, it may be a good idea to increase the size of the Pagefile.sys to accommodate spikes in memory demand. It's best not to disable the pagefile.
For example, anyone editing 4K videos in Adobe Premiere may experience crashes or a sluggish Windows system, even with 64 GB of RAM.
The way out:
Set the page file size to 40GB or even 100GB as a test and check whether the performance improves.
Increasing the size could also help with resource-hungry high-end games. Important: Check in advance whether the drive on which the file is located has sufficient free space.
Recommended size for minimum requirements (with risk)
Setting a Pagefile.sys that is too small carries the risk of system instability. A minimum size due to a lack of space on the hard disk should only be selected if there is sufficient physical RAM and the system load is low.
Move Pagefile.sys
Moving the Pagefile.sys can be a clever move to optimize the performance of your PC.
However, please note the following 3 points before changing or moving the file:
- Backup: Before you make any changes to the system settings, it's a good idea to back up your most important data.
- Check disk space: Make sure the destination drive has enough free space.
- System Monitoring: Monitor your system after moving the Pagefile.sys to ensure that everything is working smoothly.
With these instructions you can move the Pagefile.sys - safely and effectively. This will not only improve the performance of your PC, but also make optimum use of your memory resources.
How to move the Pagefile.sys safely (instructions)
- Open System Settings: First, open the advanced system settings. You can do this, for example, by right-clicking on "This PC," selecting "Properties," and then clicking "Advanced System Settings" at the bottom of the window.
- Adjust performance settings: In the new window, click the "Advanced" tab, then click "Settings" under "Performance.".
- Manage virtual memory: In the Performance options, select the "Advanced" tab again and click "Change" under "Virtual memory.".
- Disable automatic management: Uncheck the box next to "Automatically manage the size of the paging file for all drives" if the file is managed by the system.
- Disable the page file on the current drive: Select "No paging file" and click "Set," then confirm the warning message by clicking "Yes.".
- Selecting the New Drive: Now select the drive to which you want to move the Pagefile.sys.
- Set Size: Enter the initial size and the maximum size of the Pagefile.sys for the new drive. It is recommended that you set these values to at least 1.5 to 3 times your RAM. IMPORTANT: Are you a power user with computationally intensive applications (video editing or gaming)? If so, check the size of your current Pagefile.sys beforehand. It may be 20 GB—or even 100 GB in extreme cases—because the system requires more virtual RAM than a standard Windows user. In that case, it’s best not to set the size any smaller, as this could lead to performance issues or crashes (even if you have 32 GB or 64 GB of physical RAM installed)!
- Confirm changes: Click "Set" and then "OK" to save your changes.
- Restart the system: After you make these changes, you'll need to restart your PC for the move of the Pagefile.sys to take effect.
When does it make sense to postpone?
Moving the Pagefile.sys is particularly useful if you realize that your current configuration is not optimal - be it because of slower access times on an HDD or because of a lack of space on one of your Windows system partitions (usually "C") or an SSD that is too small.
Examples:
- Performance Improvement: On a system with a slow HDD, moving the Pagefile.sys to an SSD can noticeably improve the system's overall response time.
- Storage Management: If you're running low on space on your SSD, moving the virtual memory to a larger HDD can help free up valuable SSD storage for other applications.
SSD or HDD - where to move?
If you have an SSD, it's a good idea to move the Pagefile.sys to it. SSDs are faster than HDDs, which means that your Windows system can access the data on them faster.
This can make a noticeable difference, especially under load.
Frequent write operations can theoretically affect the service life of an SSD. And this file is often written to. However, modern SSDs are usually robust enough to cope with this without significant effects.
The only important thing is to always set the same values for the initial size and maximum size of the file. Dynamic enlargement and reduction results in unnecessary load and increased SSD wear.
However:
Do you have only a small SSD with limited free space, but also a larger HDD? If so, it might be a good idea to move the Pagefile.sys to the HDD to save valuable SSD storage space.
And above all, to avoid having to set the size of the page file too small - because this could cause performance problems and, in the worst case, Windows crashes.
Therefore, always make sure that the target drive - whether SSD or HDD - has enough free space to accommodate a sufficiently sized Pagefile.sys.
Virtual RAM: How the page file ensures smooth working & prevents system crashes
The Pagefile.sys acts as an extension of your physical RAM:
Imagine you are working on many applications at the same time in Windows 11, 10 or 7 and your RAM is almost full. Windows then uses Pagefile.sys, which provides additional memory.
You can continue working without your PC slowing down or crashing.
This is because Windows swaps data from RAM to this file - which is why it is also called a swap file.
Without this system file, your operating system or individual apps would crash or slow down. Especially with many parallel or computing-intensive processes.
The Windows system management automatically controls the page file and dynamically adjusts its size depending on your system load.
Normally, you don't have to worry about it taking up too much storage space or not being used efficiently enough.
But in some cases it can help if you manually change, optimize and adapt the Pagefile.sys to your custom needs as described in the instructions above.
Summary
In this article, we have taken an in-depth look at the Pagefile.sys file in Windows. Our mission was not only to show you what this file does, but also how you can use it to your advantage.
Here are the most important points we have covered:
- Virtual RAM: We've explained that Pagefile.sys acts as virtual memory and is essential for system stability and performance. It helps keep your PC running smoothly even under heavy load.
- Resizing: You've learned how to reduce and increase the size of Pagefile.sys to suit your specific needs. When sized correctly, it can significantly improve performance.
- Deleting and Disabling: We have made it clear that deleting or disabling Pagefile.sys is not recommended in most cases, as this can compromise system stability. Instead, we have suggested alternative solutions, such as automatically deleting it during shutdown to enhance security.
- Moving the File: We've shown you how to move the Pagefile.sys file to a different drive to save space on your main drive or improve system performance.
FAQ
References
On Windows Tweaks you will find time-saving tech guides for PC, software & Microsoft. For a stress-free digital everyday life. Already We have been tweaking Windows since 1998 and just don't stop!
















