How To Determine and Set Optimal Pagefile Size In Windows 10

One of the many unknown reasons of a Windows 10 PC crash or BSoD is the pagefile. By default, Windows 10 manages the pagefile automatically. However, if you have manually configured the pagefile settings, this may lead to a system malfunction or crash if not configured properly.

If a Pagefile is too small, it may cause the PC to crash frequently. If it is too big, it might take up a significant amount of storage space on your hard drive. So how do you know what the right size is? This article discusses how to determine the optimal Pagefile size on your Windows 10 and set it.

[lwptoc]

What is Pagefile

Pagefile is a hidden system file on your hard drive that is primarily there to compensate for low RAM. Pagefile serves as an extension to RAM. Data that cannot be processed in RAM due to lack of space is saved in pagefile and swapped in RAM when it is free.

This Pagefile is hidden at the root of the system volume and can be seen if hidden files and folders are configured to be visible.

Pagefile.sys

It is also where the Operating System itself places files and logs in case a system crashes. This is known as Crash Dump files. If there is not sufficient space within the Pagefile, the system might throw a BSOD.

Now that you get the gist of what a Pagefile is, let us discuss the optimal size of a Pagefile.

Determine optimal Pagefile size in Windows 10

Since the Pagefile is directly associated with the system RAM, and by default, its size is managed by the Windows itself, its size cannot be fixed. Each system can have a different size for the Pagefile. If a system has a lot of RAM that is not usually consumed, a PC might not even need a Pagefile as it would not need to vacate the RAM at all. However, if a system has low RAM, then the Pagefile can be significantly bigger.

For example, a PC with 2 GB RAM may have a Pagefile of 4 GB in size. Whereas a PC with 8 GB RAM may have a Pagefile size of 2 GB.

Microsoft recommends a range of minimum and a maximum size of Pagefile, and you may set the size of the Pagefile in between that range, according to the criteria that follows:

Microsoft says that a PC should have a minimum Pagefile size of RAM, plus an extra 257 MB. Meaning, if your system’s RAM is 8 GB, then your Pagefile size should be at least 8449 MB.

For the maximum, Microsoft suggests that the Pagefile size should be 3 times that of the system RAM, or 4 GB, whichever is larger. For example, if the RAM on your PC is 1 GB, then the Pagefile size should be a maximum of 4 GB. However, the upper limit is then restricted by the amount of storage on the hard drive. Hence, it is not advisable to set the maximum value of the Pagefile to something that would significantly affect your storage.

There is still to decide what one should set the Pagefile size to, even after Microsoft has designated the upper and lower limits. For that, we suggest that you adapt the technique below to know what the actual size of the Pagefile ought to be.

  1. Run your system as usual. Open all the programs, applications, and services you usually run so that the PC reaches the usual amount of Pagefile utilization.
  2. Now navigate to the following:
    Control Panel -> System and Security -> Administrative tools -> Performance Monitor
  3. In the Performance Monitor window, expand Monitoring Tools on the left, and then click Performance Monitor.
    How To Determine and Set Optimal Pagefile Size In Windows 10 1
  4. On the right-click the blank graph on the right and then click Add counters from the Context Menu.
    How To Determine and Set Optimal Pagefile Size In Windows 10 2
  5. Under the Available counters section, expand the Page file by clicking on the down-arrow beside it, click %usage, and then click Add at the bottom.
    How To Determine and Set Optimal Pagefile Size In Windows 10 3
  6. Ensure that the counter has been added and is visible on the right side, then click OK.
    How To Determine and Set Optimal Pagefile Size In Windows 10 4
  7. Now you get a real-time representation of the Pagefile being consumed, as in the image below where you can see that less than 10 percent is being consumed.
    How To Determine and Set Optimal Pagefile Size In Windows 10 5
    The fields at the bottom of the graph are MBs, except for the time that represents 1 minute and 40 seconds.

You can now figure out what the size of your Pagefile should be, which needs to be just over the amount that is being used.

Now that we know what the size needs to be so that the system has optimal performance and the storage space is not compromised, let us dig into how you can change the Pagefile size.

Set Pagefile size in Windows 10

You can set your Windows 10 to stop managing the Pagefile size and define the upper and lower limits yourself. Use the guide below to customize the Pagefile size.

  1. Navigate to the following:
    Start Menu -> Settings -> System -> About
  2. Now scroll down and click Advanced System Settings.
    How To Determine and Set Optimal Pagefile Size In Windows 10 6
  3. In the System properties popup window, under the Advanced tab, click on Settings under Performance.
    How To Determine and Set Optimal Pagefile Size In Windows 10 7
  4. In the Performance Options window, switch to Advanced tab, and then click Change under Virtual memory.
    How To Determine and Set Optimal Pagefile Size In Windows 10 8
  5. In the Virtual memory window, uncheck the box next to Automatically manage paging file size for all drives. Once done, you should now be able to select Custom size and then enter the minimum and maximum values for the Pagefile size according to your observation from the Performance Monitor. Then, click on Set and Ok.
    How To Determine and Set Optimal Pagefile Size In Windows 10 9
  6. Reboot your computer for the changes to take effect.

You can now check that the Pagefile size has been set to the minimum value you have allotted, increasing to the maximum value over time.

Closing words

For mission critical systems, it is recommended that RAM should be increased so that the system can process data in RAM which is much faster than the hard drive. But for an everyday use system, you can use pagefile settings as recommended in this article.

Also see:

GET DAILY UPDATES IN YOUR INBOX

Join 8,000+ other readers

Photo of author
Subhan Zafar
Subhan holds a degree in Electrical Engineering and has completed several systems and network certifications including Huwaei, Cisco and Microsoft certs. He mostly researches and writes about the Windows world.

Share on:

2 thoughts on “How To Determine and Set Optimal Pagefile Size In Windows 10”

  1. Good day.
    I am a certified tech. I was taught that the pagefile must be set at 1.5X your physical ram size.
    So 2Gb ram = Pagefile size of 3Gb
    4Gb ram = Pagefile size of 6Gb and so forth.

    Also the min size should be the same size as max size to reduce wear and tear in constant resizing.

Comments are closed.