Tips

What Is the Hiberfil.sys File and Can You Delete It?

By Geethu 4 min read
computer

If you’ve ever noticed a large file named hiberfil.sys taking up space on your system drive, you might wonder what it is and whether it’s safe to delete. Let’s break it down in simple terms.

What Is Hiberfil.sys?

The hiberfil.sys file is created automatically by Windows when you use the Hibernate feature. When you put your computer into hibernation, Windows saves everything in your system’s memory—like open programs and unsaved files—to this file. That way, when you power your PC back on, it restores everything exactly as it was before you shut down.

In short:

  • Hiberfil.sys stores your session data before hibernation.
  • It allows Windows to resume where you left off after restarting.
  • It’s managed entirely by Windows and located in the C:\ drive.

Because this file holds all the data from your system memory, it can grow quite large—usually between 3 GB and 5 GB, but sometimes much more depending on your RAM size.

Where to Find It

The file is hidden by default because it’s a protected system file. If you want to see it:

  1. Open File Explorer (Windows + E).
  2. Go to the View tab and check Hidden items.
  3. Click Options → Change folder and search options.
  4. In the View tab, uncheck Hide protected operating system files (you’ll need to confirm the warning).

Now you should see hiberfil.sys in the root of your C: drive.

Sleep vs. Hibernate: What’s the Difference?

Both Sleep and Hibernate help save power, but they work differently.

Feature Sleep Hibernate
Where data is saved RAM (temporary memory) Hard drive (hiberfil.sys)
Power usage Low (uses battery) Almost none
Speed to resume Very fast Slower but saves more power

Sleep mode keeps your PC running in a low-power state, while Hibernate completely powers it off but remembers everything using hiberfil.sys.

Is Hiberfil.sys Safe?

Yes, it’s completely safe. It’s a legitimate Windows file, not a virus. However, if you see a file named hiberfil.sys somewhere other than C:\, or with an .exe extension, that could be suspicious. The real file will always be in your main Windows directory.

Can You Delete Hiberfil.sys?

Yes — but only if you don’t use Hibernate. The file can’t be deleted while Hibernate mode is active, because Windows needs it. If you don’t use that feature and want to free up several gigabytes of space, you can safely remove it.

How to Disable Hibernate (and Delete Hiberfil.sys)

Option 1: Using Command Prompt

  1. Click Start, type Command Prompt, right-click it, and select Run as administrator.
  2. Type this command and press Enter:
    powercfg -h off
  3. This turns off Hibernate and automatically deletes the hiberfil.sys file.

If you ever want to bring Hibernate back, use the same command but replace off with on:
powercfg -h on

Option 2: Using Windows PowerShell

  1. Press Windows + X and select Windows PowerShell (Admin).
  2. ype:
    powercfg /hibernate off
    Press Enter. Hibernate will be disabled and the file removed.

To re-enable it later:
powercfg /hibernate on

Option 3: Through the Registry (Advanced)

This method is only for experienced users. Editing the registry incorrectly can cause system issues.

  1. Press Windows + R, type regedit, and hit Enter.
  2. Navigate to:
    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power
  3. Find HibernateEnabled on the right.
  4. Double-click it and change the Value data from 1 to 0.
  5. Restart your PC.

Optional: Resize the Hiberfil.sys File

If you want to keep Hibernate but reduce its size, you can shrink the file instead of deleting it.

  1. Open Command Prompt (Admin).
  2. Enter this command:
    powercfg.exe /hibernate /size 50

This reduces the file size to 50% of your RAM (the minimum allowed).

Conclusion

The hiberfil.sys file is useful if you rely on Hibernate mode. But if you never use that feature, disabling Hibernate is a quick and safe way to reclaim several gigabytes of disk space. Deleting it won’t harm your system, and you can always re-enable it later with a simple command.

Geethu

Geethu is an educator with a passion for exploring the ever-evolving world of technology, artificial intelligence, and IT. In her free time, she delves into research and writes insightful articles, breaking down complex topics into simple, engaging, and informative content. Through her work, she aims to share her knowledge and empower readers with a deeper understanding of the latest trends and innovations.

Leave a Comment

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