FIX · DISK SPACE
hiberfil.sys: what it is, and how to shrink or remove it
hiberfil.sys is the hidden file at the root of your Windows drive that hibernation, hybrid sleep and Fast Startup all use. It can take several gigabytes, and you can get them back, but not by deleting the file by hand. Windows has a command for this, and the right choice depends on which of those three features you want to keep.
Updated .
TECHNICAL SUMMARY
| Location | Root of the Windows drive, hidden system file |
|---|---|
| Full type, default size | 40% of physical memory |
| Reduced type, default size | 20% of physical memory (Fast Startup only) |
| Remove it | powercfg /h off, as administrator |
| PC Tweaker plan | No control for this file; the command is free |
What the file is for
When a PC hibernates, Windows compresses its user and system state and writes it to disk, then reads it back on the next start. Microsoft lists three users of the hibernation file: standard hibernation, hybrid sleep and Fast Startup. That last one is why the file matters even if you never choose Hibernate: Fast Startup is the default kind of shutdown in Windows, and it saves the kernel session to this file.
Why it is so large
The size follows your RAM, not your files. Microsoft gives a default of 40% of physical memory for a full hibernation file and 20% for a reduced one, so on a PC with 32 GB of RAM that is about 12.8 GB or 6.4 GB. A custom size set with powercfg can make it larger, which is why a file close to the size of your RAM is not necessarily a fault. Installing more memory makes it bigger, and cleaning up your apps does not make it smaller.
Is it safe to delete?
Removing it through powercfg is safe in the sense that Microsoft documents it and one command brings it back, but it does cost you features. Do not try to remove the file in File Explorer: the supported route is the powercfg command.
- Hibernate stops being available
- Hybrid sleep stops working. Microsoft warns that you may lose data if the power fails while hybrid sleep is set to on
- Fast Startup stops as well, because it needs the same file, so every Shut down becomes a full shutdown
Shrink it instead of removing it
If the only thing you use is Fast Startup, the reduced type is the better trade: it keeps Fast Startup and gives up Hibernate and hybrid sleep, at half the default size of a full file. Only Fast Startup can use a reduced file. If you do use Hibernate, keep the full type.
Do it by hand
See what you have (read-only)
Replace C: if Windows is on another drive. With a full file, powercfg /a lists Hibernate as available; with a reduced one it says hibernation is not supported; with no file at all it says hibernation has not been enabled.
cmddir /a C:\hiberfil.sys powercfg /aShrink it, keeping Fast Startup (as administrator)
If this returns "The parameter is incorrect", the file has a custom size. Run powercfg /h /size 0 first, then run the command again.
cmdpowercfg /h /type reducedOr remove it (as administrator)
Hibernate, hybrid sleep and Fast Startup all stop. On our Windows 11 test PC (build 26300) with hibernation off, C:\hiberfil.sys does not exist.
cmdpowercfg /h offBring it back (as administrator)
Microsoft does not recommend the full type on systems with less than 32 GB of storage.
cmdpowercfg /h on powercfg /h /type full
With PC Tweaker
PC Tweaker has no control that creates, resizes or deletes hiberfil.sys, so use the commands above. Its Turn off Fast Startup control in the Maintenance category is a separate Pro setting: it changes HiberbootEnabled and leaves the file as it is, so turning Fast Startup off with it does not give you any disk space back.
Rather not edit the registry by hand?
PC Tweaker shows the exact change before it runs, records the value it replaces and puts it back with Restore. The Free plan needs no account. If a payment fails or a plan ends, Pro tools lock; changes already applied stay as they are and Restore still undoes them.
Common questions
What is hiberfil.sys?
It is the hidden hibernation file at the root of the Windows drive. Windows uses it for hibernation, hybrid sleep and Fast Startup.
Can I delete hiberfil.sys?
Yes, with the command powercfg /h off run as administrator, not by deleting it in File Explorer. Hibernate, hybrid sleep and Fast Startup stop working until you run powercfg /h on.
Why is hiberfil.sys so big?
Its size follows your RAM. Microsoft gives a default of 40% of physical memory for a full hibernation file and 20% for a reduced one, and a custom size set with powercfg can make it larger.
How do I make hiberfil.sys smaller?
Run powercfg /h /type reduced as administrator. That keeps Fast Startup and gives up Hibernate and hybrid sleep. If you get "The parameter is incorrect", run powercfg /h /size 0 first and try again.
Does turning off Fast Startup remove hiberfil.sys?
No. Turning off Fast Startup through its setting changes how Shut down behaves and does not remove the file. To remove the file, turn hibernation off with powercfg /h off.
Try PC Tweaker
Free download for Windows 10 and Windows 11.