What is Hiberfil.sys? Is it safe?

Sacred of Hiberfil.sys and wondering if it's safe? Here’s what that Hiberfil.sys file is and how you can delete it if you want to.
What is Hiberfil.sys

If you’ve noticed a large file named Hiberfil.sys file sitting on your system drive, and you’re wondering if you can get rid of it to free up some space. Other users who’ve never seen the file also wonder if Hiberfil.sys is safe. 

Here’s what that Hiberfil.sys file is and how you can delete it if you want to. 

What is Hiberfil.sys?

Hiberfil.sys is a Windows system file that stores the current memory contents of your PC’s state just before the user activates the hibernation mode in the Windows operating system. This essentially means that when the computer comes out of Hibernation, Hiberfil.sys restores the user's session when the system boots up after hibernation mode.

what is hyberfil.sys


Hberfil.sys is created and managed by the Windows Operating System itself. Since Hiberfil.sys stores all the data on the PC for hibernate mode, the file could​ end up becoming several gigabytes in size depending on your use of the hibernate feature. For instance, in Windows 10, Hiberfil.sys usually ranges from 3 to 5 GB. This may end up causing storage issues on your PC.

Picture this:

When you select Hibernate, Hiberfil.sys stores all your data on your local disk. This Hiberfil.sys file contains the system configuration that Hibernation uses to launch your system. 

Hiberfil.sys File information in Windows 10

Hiberfil.sys is a hidden file on the PC. This means that you can only see it in the Windows file manager if you checked the ‘Show hidden files and folders, options.

hiberfil file information in Windows 10

 

Windows places the Hiberfil.sys file in the source directory of the system partition itself. Typically, this is in the root directory of C:\. However, since Hiberfil.sys is a hidden and protected OS file, you won’t see it by default. 

If you wish to change this setting, for example, to see the file size, do the following:

  1. Open file explorer (press Windows Key + E). 
  2. Go to the View tab
  3. Locate the Hidden items option and click the checkbox next to it.
  4. Now, on the left side, click on Options.
  5. Next, click the Change folder and search options.
  6. In the next dialog box, go to the View tab and uncheck Hide protected operating system files (Recommended).
  7. Now, you will be able to see the unhidden Hiberfil.sys file in the Windows partition source directory.

Sleep vs Hibernation and Hberfil.sys in Windows 10

Sleep and Hibernation appear similar but they’re not the same power modes for Windows. There are some behind-the-scenes differences between these power modes.

sleep vs hibernation in Windows 10


Although Windows doesn’t fully shut down in both power modes, there are some particular differences in storage description. Hibernation saves your current PC’s status to the Hiberfil.sys file on your hard drive. On the other hand, Sleep saves the machine’s state to the RAM. 

In both power modes, Windows enter into a low-power state, and their combination allows your system to restore incredibly quickly.

Is Hberfil.sys safe?

Yes, hberfil.sys is safe. 

Hiberfil.sys is a genuine file the Windows system creates when the computer goes into hibernation mode. It is created and managed by the Windows Operating System.

However, any malware can be named anything. So, if you’re doubting this file you should check its location on your disk. 

If a “non-Microsoft” .exe file is located in the C:\Windows or C:\Windows\System32 folder, then there is a high risk for malware (virus, spyware, trojan or worm infection) infection in the PC. 

Can I Delete Hiberfil.sys

Typically, hiberfil.sys is a Windows system file that functions when the PC is on Hibernation.  So, this file cannot be deleted if the hibernation mode is on. But this file can grow and become a space hog on your hard drive taking up to tens of gigabytes on your PC. 

If you are not using hibernate mode or the hibernation mode is not on, you can delete hiberfil.sys file. So, technically it is safe to delete hiberfil.sys. 

You need to first check if hibernation mode is on before you disable or delete hiberfil.sys. Here’s how:

  1. Go to the Settings.
  2. Choose System.
  3. Select Power & Sleep
  4. Click on the additional power settings
  5. Now, click on the power plan to change the settings. 
  6. See if Hibernation is on or off for various provided settings.

If you use the ‘Hibernate’ feature when you want to leave your computer for a while, then deleting the Hiberfil.sys isn’t a good idea. 

So, the answer is, Yes, you can safely delete Hiberfil.sys, but, you may have some negative reactions. 

How to Disable Hiberfil.sys in Windows 10

There are two ways to disable Hiberfil.sys in Windows 10:

  • Disable hiberfil.sys through the Command Prompt or Windows PowerShell
  • Change the registry entry for hiberfil.sys.

In both ways, you must have the necessary access privileges since the hiberfil.sys file is a system file. 

How to disable Hibernation in Windows 10

If you want to delete/disable Hiberfil.sys, you must first disable the Hibernation option if it’s on. 

how to disable hiberfil.sys in WIndows 10


Here’s how to disable hibernation in Windows 10: 

  1. Press Windows Key + S to open Windows Search.
  2. Type power then select Power & sleep settings.
  3. Now, select Additional power settings on the right-hand pane (or scroll down in a minimized window).
  4. This will open the Power Options.
  5. Now, on the left pane of Power options, select Choose what the power buttons do.
  6. Next, click the Change settings that are currently unavailable link.
  7. If prompted to enter your Windows user account password do it. 
  8. Uncheck the Hibernate option.
  9. Click on Save changes.
  10. Once you’ve unchecked the Hibernation option, you can then proceed and disable hiberfil.sys.
how to disable hiberfil.sys


Voila, you're done!

Disable Hiberfil.sys Using the Windows PowerShell or Command Prompt

disable hiberfil.sys using PowerShell


Use the wallowing steps to disable hiberfil.sys through the Command Prompt or Windows PowerShell:

  1. Click Windows Key + X.
  2. Select Windows Powershell (Admin).
  3. Click Yes is prompted with a UAC.
  4. Now type (or copy and paste) the following command: powercfg /hibernate off
  5. Press Enter.

You can use the Command Prompt as follows:

disable hiberfil.sys using command prompt


  1. Click Windows Key + S.
  2. Type CMD and select Run as administrator.
  3. Click Yes is prompted with a UAC.
  4. Now type (or copy and paste) the following command: powercfg -h off
  5. Press Enter.

These two commands will successfully delete/disable the hiberfil.sys file. 

If you decide to switch the hiberfil.sys file on again, you will replace the off command with an on command:

  • Use the powercfg /hibernate on Windows PowerShell.
  • Use the powercfg -h on in Command Prompt.

This will re-enable the option to hibernate on Windows and the hiberfil.sys file will be created again.

Delete Hiberfil.sys in Windows 10

Once you disable Hibernate in the system, Windows will delete hiberfil.sys automatically. However, if you want to double-check if it's truly gone, you can find hiberfil.sys in the root of your C: drive: 

The C:\hiberfil.sys is its default location.

hiberfil.sys location


However, if your system is hiding protected operating system files, you won’t see the file anyway. So, to check if the Hibernation file is gone, you must change a few folder settings. 

Here’s how: 

  1. Press Windows Key + E to open File Explorer.
  2. From the top Menu, select the View tab.
  3. Now, select Options, then open the View tab in the new window.
  4. Select Show hidden files, folders and drives.
  5. Uncheck Hide protected operating system files (Recommended). 
  6. When the UAC warning appears, select Yes.
  7. Now, select Apply.

You can now go to your C: drive and see some new files. If hiberfil.sys is not among the files, then the process was a success.

Note: It is strongly recommended to go back and hide your protected operating system files again. Follow the steps above, except you, should check the box in step 4. 

How to delete Hiberfil.sys via the Registry in Windows 10

Use the following procedure to delete the hiberfil.sys file using the registry editor:

Note: You shouldn’t use the registry to disable the hiberfil.sys file unless you have experience using the registry database. Any incorrect entries or changes in the registry can easily damage Windows 10.

  1. Press Windows Key + R to open the Run dialog box.
  2. Type Regedit and press Enter.
  3. Click Yes if prompted with a UAC.
  4. Now, open the “HibernateEnabled” registry entry, which is located at the following path: \HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power
    hiberfil location

  5. Double-click the above entry.
  6. On the right pane, locate HIBERNATENABLED and double click on it.
  7. Change the value in the Value data field from 1 to 0.
  8. This disable Hibernate mode and delete the hiberfil.sys file

How to Resize Hiberfil.sys

By default, Hiberfil.sys occupies 75% of your RAM, and it is stored in the C drive. You can customize the settings in File Explorer. Instead of deleting Hiberfil.sys you can resize it to create more space in your system.

However, if you want to delete it, then there is no need to change the settings.

If you want to resize the Hiberfil.sys file, follow these steps:

  1. Click Windows Key + S.
  2. Type command prompt.
  3. Select Run as administrator.
  4. Click Yes is prompted with a UAC.
  5. In the Command Prompt, enter the powercfg.exe /hibernate /size 50 Command.

This will reduce the 75% occupied space to 50%, which is the minimum that can be obtained.

Final Thoughts

If your PC is a Windows 10 system and you don’t use Hibernate, you can safely delete hiberfil.sys, and the system will create it on the next startup. Deleting Hiberfil.sys doesn’t have any negative side effects, and you will create some extra storage space. Besides, you’ll still use the Sleep option for the temporary shutdown.