This tutorial will show you how to manage the virtual memory paging file for each drive on your Windows 10 and Windows 11 PC.
A paging file (aka: "page file" and "virtual memory") enables the system to remove infrequently accessed modified data from physical memory to let the system use physical memory more efficiently for more frequently accessed data.
Windows also uses the page file to store data when physical memory (RAM) is full.
The system automatically manages the size of the paging file ("C:\pagefile.sys") on the Windows drive by default.
However, there may be times you may need to manually manage the paging file. For example:
- If the C: drive that Windows is installed on is small in size, you may wish to remove the paging file from that drive, and add a paging file to another drive with more space instead.
- If you use a lot of memory, then you may wish to add a paging file to another drive to have available if needed.
- If you don't use a lot of memory and your paging file is large in size, you may wish to use a smaller custom size.
- If you are getting a BSOD PAGE_FAULT_IN_NONPAGED_AREA or KERNEL_DATA_INPAGE_ERROR or Low Memory type error when the paging file size is not system managed, you may need to set a larger custom size for the paging file.

Introduction to the page file - Windows Client

Virtual memory in 32-bit version of Windows - Windows Server
You must be signed in as an administrator to manage the paging file.
- Option One: Set Paging File Size for All Drives to be Automatically Managed
- Option Two: Add or Set Paging File Size for Specific Drive to be System Managed
- Option Three: Add or Set Custom Paging File Size for Specific Drive
- Option Four: Remove Paging File for Specific Drive
- Option Five: Set Paging File Size for All Drives to be Automatically Managed using Command
- Option Six: Set Custom Paging File Size for Specific Drive using Command
This is the default setting.
1 Open System Properties (SystemPropertiesAdvanced.exe).
2 Click/tap on Settings under the Performance section. (see screenshot below)
3 Click/tap on the Advanced tab, and click/tap on Change under the Virtual memory section. (see screenshot below)
4 Check Automatically manage paging file size for all drives, and click/tap on OK. (see screenshot below)
This will be applied to each drive you have set a paging file for.
5 Click/tap on OK. (see screenshot below)
6 Click/tap on OK. (see screenshot below)
7 Click/tap on OK. (see screenshot below)
8 Click/tap on Restart Now when ready to restart the computer to apply. (see screenshot below)
This option is good when you only want the paging file size for specific drive(s) to be system managed instead of for all drives.
1 Open System Properties (SystemPropertiesAdvanced.exe).
2 Click/tap on Settings under the Performance section. (see screenshot below)
3 Click/tap on the Advanced tab, and click/tap on Change under the Virtual memory section. (see screenshot below)
4 Uncheck Automatically manage paging file size for all drives, and click/tap on OK. (see screenshot below step 8)
5 Select the drive (ex: "C") with a paging file or to add a paging file you want its size to be system managed. (see screenshot below step 8)
6 Select (dot) System managed size. (see screenshot below step 8)
7 Click/tap on the Set button. (see screenshot below step 8)
8 Click/tap on OK. (see screenshot below)
9 Click/tap on OK. (see screenshot below)
10 Click/tap on OK. (see screenshot below)
11 Click/tap on OK. (see screenshot below)
12 Click/tap on Restart Now when ready to restart the computer to apply. (see screenshot below)
1 Open System Properties (SystemPropertiesAdvanced.exe).
2 Click/tap on Settings under the Performance section. (see screenshot below)
3 Click/tap on the Advanced tab, and click/tap on Change under the Virtual memory section. (see screenshot below)
4 Uncheck Automatically manage paging file size for all drives, and click/tap on OK. (see screenshot below step 9)
5 Select the drive (ex: "C") with a paging file or to add a paging file you want to set a custom size for. (see screenshot below step 9)
6 Select (dot) Custom size. (see screenshot below step 9)
7 Enter the Initial size (minimal) you want in MB (1024 MB = 1 GB) for the paging file on the selected drive. (see screenshot below step 9)
8 Enter the Maximum size you want in MB (1024 MB = 1 GB) for the paging file on the selected drive. (see screenshot below step 9)
9 Click/tap on the Set button. (see screenshot below)
10 If prompted, click/tap on Yes to confirm. (see screenshot below)
11 Click/tap on OK. (see screenshot below)
12 Click/tap on OK. (see screenshot below)
13 Click/tap on OK. (see screenshot below)
14 Click/tap on OK. (see screenshot below)
15 Click/tap on Restart Now when ready to restart the computer to apply. (see screenshot below)
1 Open System Properties (SystemPropertiesAdvanced.exe).
2 Click/tap on Settings under the Performance section. (see screenshot below)
3 Click/tap on the Advanced tab, and click/tap on Change under the Virtual memory section. (see screenshot below)
4 Uncheck Automatically manage paging file size for all drives, and click/tap on OK. (see screenshot below step 9)
5 Select the drive (ex: "C") with a paging file you want to remove. (see screenshot below step 9)
6 Select (dot) No paging file. (see screenshot below step 7)
7 Click/tap on the Set button. (see screenshot below)
8 If prompted, click/tap on Yes to confirm. (see screenshot below)
9 Click/tap on OK. (see screenshot below)
10 Click/tap on OK. (see screenshot below)
11 Click/tap on OK. (see screenshot below)
12 Click/tap on OK. (see screenshot below)
13 Click/tap on Restart Now when ready to restart the computer to apply. (see screenshot below)
This is the default setting.
This command does the same as Option One.
1 Open Windows Terminal (Admin), and select Command Prompt.
2 Copy and paste the command below into Windows Terminal (Admin), and press Enter. (see screenshot below)
wmic computersystem where name="%computername%" set AutomaticManagedPagefile=True
3 Close Windows Terminal (Admin).
4 Restart the computer to apply.
This option does the same as Option Three.
1 Open Windows Terminal (Admin), and select Command Prompt.
2 Copy and paste the command below into Windows Terminal (Admin), and press Enter. (see screenshot below)
wmic computersystem where name="%computername%" set AutomaticManagedPagefile=False
3 Copy and paste the command below into Windows Terminal (Admin), and press Enter. (see screenshot below step 4)
wmic pagefile list /format:list
4 Make note of the paging file Name (ex: "C:\pagefile.sys") you want to set a custom size for. (see screenshot below)
5 Type the command below into Windows Terminal (Admin), and press Enter. (see screenshot below)
wmic pagefileset where name="<paging file name>" set InitialSize=<min size>,MaximumSize=<max size>
Substitute <paging file name> in the command above with the actual paging file Name (ex: "C:\pagefile.sys") from step 4.
Substitute <min size> with the actual initial size in MB you want for the paging file size.
Substitute <max size> with the actual maximum size in MB you want for the paging file size.
For example:
wmic pagefileset where name="C:\pagefile.sys" set InitialSize=800,MaximumSize=2924
6 Close Windows Terminal (Admin).
7 Restart the computer to apply.
That's it,
Shawn Brink