Pagefile.sys – How to Configure or Delete the File in Windows

Windows 10, in order to perform multiple types of tasks within the system, is responsible for creating various types of files. The paging file, called pagefile.sys is one of them. This file with the passage of time is filling up more and more and if we do not control it, it can take up too much space on our hard drive. That is why today we are going to see what this type of file consists of and how we can delete it or change its size or unit.

The paging file pagefile.sys may be completely unknown to many users, since Windows creates it internally and we are hardly going to deal with it. In the event that we have a PC with a small hard disk, with a problem that it often fills up, we may be interested in dispensing with the use of this file, or changing its size or moving it to another storage unit. All this is something that we will see next.

Pagefile.sys - How to Configure or Delete

What is the pagefile.sys file for, can we do without it?

This is a system file that the operating system uses to store the Windows paging file . This file acts as if it were virtual RAM , which Windows uses as RAM to store programs that are not in use. This way you put less pressure on the actual RAM and get faster access to them. This also causes this file to become larger and larger, occupying more and more space on our hard drive, so we may still be interested in doing without it. This file can be found inside the C drive of our computer, although it is hidden. So if we want to see it, it will be necessary to activate the “Hidden elements” tab within the Windows 10 File Explorer.

Localizar archivo pagefile en el disco duro

It is possible to dispense with this file without any risk to our system, although on computers with little RAM memory we may notice slowdowns when the computer is using all the RAM available on the computer. For this reason, we configure this paging file so that it is eliminated, we will be able to save some space on our hard disk, in exchange for slightly prolonging the shutdown time of the system. It is also possible to change its size in our operating system to reduce its impact or change it to another storage unit that we have available.

We do not have to be afraid to do without this file, although depending on the amount of RAM we have in our computer, we can notice slowdowns when the equipment is using all the available memory, in the case that we have 8 GB or less of RAM. If we have 16 or 32 GB available, generally, we should not notice any difference, unless we are able to use all the memory of the system.

Ways to delete pagefile.sys file in Windows 10

If we want to delete the pagefile.sys file from our Windows 10 computer, we have several ways to do it. The simplest, from the Control Panel we will have quick access. For the more advanced it is also possible to delete it using the Group Policy Editor and the Registry Editor.

Use the Settings menu

It is possible to delete the pagefile.sys file from the system properties, from where we can access the Settings menu, by pressing the Windows + I keyboard shortcut. Once inside we click on the “System” tab.

Configuración y sistema

Subsequently, in the left column, at the bottom we click on “About”, and on the right we click on “Advanced system configuration”.

Configuración avanzada del sistema

This will open a small window for us. Here, in the “Performance” section, click on “Settings” and a new window will appear.

Propiedades del sistema Configuración

In this new window we will go to the “Advanced options” tab and in the “Virtual memory” section, click on the “Change” button.

Opciones de rendimiento y opciones avanzadas

This will make another window appear again, where at the top we have the “Automatically manage paging file size for all drives” box checked. We uncheck this so that the rest of the options are enabled. Now we mark all the hard drives that we have connected to the computer and within the “Without paging file” section, click on “Set”. This will delete the pagefile.sys file , leaving it taking up 0 KB of space.

Configuración establecer sin archivo de paginación

Use Local Group Policy Editor

In the case that we use a Pro or Enterprise version of Windows 10, we can use the Local Group Policy Editor to delete the Pagefile.sys file automatically. To do this, we use the keyboard shortcut “Windows + R”, to launch the Execute command, where we must write gpedit.msc and click “OK”.

Once we have accessed the “Local Group Policy Editor”, in the left column click on “Computer Configuration” and display the Windows Configuration folder. Then we click on “Security Settings”. Next, in the right column we double click on “Local Policies” and then double click on “Security Options”. Now in the right panel, we must find and double click on the section “Shutdown: delete the paging file from virtual memory “.

Borrar el archivo de paginación de la memoria virtual

This will open a new configuration window within the Local Group Policy Editor, where we must mark the “Enabled” option and click “OK” to save the changes. Now we only have to restart the system for the changes to take effect. If at any time, we want to go back, we simply have to perform the same steps and click on the Disabled button.

Habilitar borrado de archivo de paginación

From the Registry Editor

Lastly, we can also use the Windows 10 Registry Editor to delete the pagefile.sys paging file. To do this, we will press the keyboard shortcut Windows + R to launch the Run command. Here we must write “regedit” and click OK.

Once the Windows 10 Registry Editor appears, we must navigate to the following path:

HKEY_LOCAL_MACHINE / SYSTEM / CurrentControlSet / Control / Session Manager / Memory Management

Once we see the contents of this folder in the right panel, we must double click on the file ClearPageFileAtShutDown . This will open a new window, where we must set 1 as value information and press “OK” to save the changes. Finally, we restart the PC for the changes to take effect. From now on, every time we turn off the computer, the paging file will be deleted.

Editar información de valor de ClearPageFileAtShutDown

Delete pagefile.sys file with PrivaZer

Another option we have available to delete the pagefile.sys file is to use an application like PrivaZer developed to safely clean our computer.

It is a tool that will help us to clean our PC, cleaning unwanted traces of both the operating system and the programs we have used. For this, it is responsible for deleting old files that have been saved on our hard drive. This application has more than 100 analysis and cleaning functions, among which is the possibility to delete the Pagefile.sys file. We can download it for free and in a portable version from its website.

Once we execute it, its main menu appears, where we must click on “Advanced options” in the left column.

PrivaZer Opciones avanzadas

A new window will appear, where we must click on the “Memory” tab. Here we see the section of Pagefile.sys where it gives us the option to delete it in three different ways: “After each cleaning with PrivaZer”; “Only on next PC shutdown” and “Every PC shutdown”.

PrivaZer borrar pagefile

Resize pagefile.sys or move it to another drive

We may not consider it necessary to delete the peafile.sys file, so we can also use other solutions such as the possibility of changing its size or moving it to another unit, in case we have more than one hard disk, and we have of more storage space.

Change file size

If we want, we can choose to change the size of the pagefile.sys file manually. To do this, we must access the “Advanced system configuration”, from the “Configuration” and “System” menu. Within the section “Performance Options” and “Virtual Memory” we have the possibility to change the size of this system file. Here, we must have the option “Automatically manage the paging file size for all units” disabled. Then, we can choose between the option to deactivate the option to Automatically manage the size or opt for the “Custom size” , which will allow us to choose a desired size to our liking, establishing an initial size (in MB) and a size maximum.

Memoria virtual establecer tamaño personalizado

When establishing these values we must take into account a differential factor such as the amount of RAM we have in our computer. Currently, it is to have at least 8 GB of RAM, to be able to move Windows 10 with ease, so in this case we can assign 4000 MB for the initial size and 8000 MB as the maximum size. It is not something that we assign obligatorily since each user can set the value they consider necessary.

Move the file to a different drive

If the pagefile.sys file takes up too much space, it may be interesting for us to change the storage space within our system. This is something that we also do within the Virtual Memory section belonging to the advanced configuration of the system. Here, at the top, we find a table showing the different storage units that we have available. We select the “C drive” and click on the “No mapping file” box and finally click on the “Set” button.

Establecer unidad C sin archivo de paginación

Next, we are going to select the drive where we want to move the data from the pagefile.sys file. Later we will select the option “Size managed by the system” and finally, click on the Set button and OK to save the changes. Now we only have to restart the PC so that the changes are applied.

Establecer unidad D como tamaño administrado por el sistema