What is pagefile.sys and How to Delete It?

Page file (also known as swapfile or paging file) is a vital part of any modern Windows computer. Because how it works, page file may take up some serious amount of free space on your drive thus making users wonder why the heck pagefile.sys takes so much space. Usually, it occupies around 6 GB+ and this may raise some concerns and question in curios user’s mind.

By default, Windows keeps page file in the root of drive C. Operating system needs this file to keep your apps up and running without interruptions when you are out of RAM. Long story short, when a PC hits RAM limit, Windows moves some data from RAM to the page file. This may slow down some apps (RAM is much faster than the best SSDs out there), but they won’t crash or close and remain running without trouble. In addition, Windows may move some unused data (for example, apps in the background) from RAM to pagefile to free some memory for more important processes. If you turn off or delete pagefile.sys and your PC has a very little amount of RAM, you may end up with a warning message that says your PC has insufficient memory. “There is insufficient system memory for the operation” or “More free memory is required than is currently available on your computer” messages are common signs that your PC is out of free RAM and the paging file is turned off. Even if your PC has more than comfortable 16 GB of RAM and you never reach even half of that, Windows still needs a paging file.

Do note that Windows has two paging files. One is called pagefile.sys and the second is swapfile.sys. Swapfile.sys is required for Universal Windows Apps you can get from Microsoft Store and pagefile.sys is being used for classic Win32 apps.

How to Delete Page File or Reduce/Increase Its Size?

You can’t delete pagefile.sys using Shift + Delete buttons. Windows uses a special tool to manage a paging file which is stored within the Control Panel. From there you can reduce or increase paging file size or turn it off completely. Let’s see how to delete pagefile.sys on Windows 10.

READ ALSO:  How to Check my PC Specs?
  1. Hit Win + R on your keyboard and enter sysdm.cpl.
  2. Go to Advanced tab and click on Settings within the Performance section. pagefile.sys
  3. In the new Performance Options window click on Advanced tab. Look for Virtual memory section. You will find there total paging file size for all drivers. In our case, this is a mere 2.4 GB. Click Change. page file windows 10
  4. Windows automatically defines the correct paging file size. If you think you should increase or decrease it or simply turn it off to free up some space, uncheck Automatically manage paging file size for all drives. Now you can change how paging file works.
  5. To decrease or increase pagefile.sys size, select Custom size and specify initial size and maximum size in megabytes. If you want to delete pagefile.sys, click on No paging file and then Set. Do note that this won’t delete the paging file immediately. Restart your PC and only after that system will get rid of swapfile. windows page file

We do not recommend disabling pagefile because you never know how your apps and games work with this feature. Some apps or games require paging file even if your PC has hundreds of gigabytes of RAM. That how it works, and you should deal with it. But we also should note that if there is critical need to free some storage on your drive and you are pretty sure no apps will crash without pagefile, you can disable it without any harm for the system (a study showed that Windows does not perform any better or worse with pagefile turned on or off). Just make sure to turn it back on if some apps misbehave. Key point is that your PC won’t perform any better with no paging file. In some cases, you may end up crippling your PC even more than with pagefile.sys being turned on.

READ ALSO:  Windows 10: Taskbar not Hiding

Proper Pagefile.sys Size

Just like with turning pagefile off, there won’t be any benefit in increasing pagefile for no reason. The best option is to leave this task to the system. Windows knows better how to manage pagefile and you should not intervene in this process. Still, some developers recommend setting pagefile size manually. Pagefile size depends on how much RAM you have. Initial size should be equal to the difference between the total amount of RAM and the maximum amount of memory in use during peak load (you can check this value in Task Manager on Performance tab). Double this amount for the maximum size. Let’s do the math to get the idea.

Suppose we have 16 GB of RAM. Windows consumes 11 GB during peak load. This means our pagefile should be 5 GB minimum and 10 GB maximum. Simple.

How to Move the Pagefile.sys to a Different Drive?

Let’s make one thing clear before we start. When we say “move the pagefile to different drive” we mean moving the file to a second physical drive, not another partition on the same drive. Moving pagefile from one partition to another won’t give you any benefit.

  1. Go to Virtual Memory setting section as described in this article above.
  2. Deselect automatic paging file size management. Click on drive C: and then press No paging file.
  3. Now click on the drive you want to move the paging file to. Select either custom size or system managed size. Press Set.
  4. Restart your PC.

Leave a Reply

Your email address will not be published. Required fields are marked *