A page file is a hidden section of your hard drive that your computer uses when it runs out of physical memory

When you open many programs at once or run something that needs a lot of memory, your computer's RAM (the fast memory it uses right now) fills up. Instead of crashing, your operating system moves some data to your hard drive temporarily and calls this space a page file. You do not create or manage a page file yourself — Windows and Mac both set one up automatically. But understanding what it does helps you recognize when your computer is struggling and what you might do about it.

You cannot "open" a page file the way you open a document or a photo. It is not a file you click on. It is a system tool that runs in the background. What you can do is check whether your computer is using one, see how much space it is taking up, and adjust its size if you know what you are doing.

Key Takeaways

  • A page file is automatic — your operating system creates and manages it without you doing anything.
  • On Windows, you can view page file settings in System Properties under Advanced tab, then Performance Options.
  • On Mac, page files exist but are managed entirely by the system and you cannot adjust them.
  • If your computer is slow and your hard drive is nearly full, a large page file may be part of the problem.
  • Changing page file size is rarely necessary and can make things worse if done incorrectly.

How to check your page file on Windows

Open the Start menu and type "System" into the search box. Click System (not System Settings). On the left side, click Advanced system settings. A window will open with several tabs at the top. Click the Advanced tab.

In the Advanced tab, you will see a section called Performance. Click the Settings button inside that section. Another window opens. Click the Advanced tab again (yes, there is another one). At the bottom, you will see Virtual Memory with a button that says Change. Click it.

This window shows your page file. The top of the window lists your hard drives. Below that, you will see numbers for the current size and maximum size of the page file on each drive. If the box at the very top that says Automatically manage paging file size for all drives is checked, Windows is handling it and you do not need to do anything.

How to check your page file on Mac

Mac computers create page files automatically, but Apple does not give you a way to view or adjust them through the normal settings. If you want to see whether your Mac is using a page file, you need to open a program called Activity Monitor.

Click the Spotlight search icon (magnifying glass in the top right corner) and type "Activity Monitor". Open it. Click the Memory tab. Look at the bottom of the window. You will see a line that says Swap Used — this is Mac's version of a page file. If the number is 0 MB or very small, your Mac is not using the page file much. If it is large (hundreds of MB or more), your Mac is running low on physical memory.

What a large page file means for your computer

A page file is much slower than RAM because it lives on your hard drive instead of in your computer's memory. When your computer has to use the page file a lot, everything slows down — opening programs takes longer, switching between windows lags, and even typing can feel sluggish.

If you notice your computer is slow and you check the page file and it is very large, the real problem is usually that you do not have enough RAM for what you are doing. Adding more RAM is the best fix, but that requires opening your computer or buying a new one. In the meantime, closing programs you are not using will help.

When to change your page file size on Windows

Most people should leave the page file on automatic. Windows is good at managing it. But if your hard drive is almost full and your page file is taking up several gigabytes, you might want to shrink it.

Go back to the Virtual Memory window (System > Advanced system settings > Advanced tab > Performance Settings > Advanced tab > Virtual Memory). Uncheck the box that says Automatically manage paging file size for all drives. Select your main hard drive from the list. Click the radio button next to Custom size. Type a smaller number in the Initial size and Maximum size boxes — most people use 1024 MB (1 GB) as a starting point. Click Set, then OK. You will need to restart your computer for the change to take effect.

Do not set the page file to zero. Even if you have plenty of RAM, some programs expect a page file to exist and will crash without one.

Why you probably should not change your page file

Changing the page file size can cause problems if you get it wrong. If you set it too small, programs will crash when they run out of memory. If you set it too large on a nearly-full hard drive, you will have no space left for other things. If you set it to zero, Windows will not let you do it — it will reject the change and keep the old size.

The better solution is almost always to close programs you are not using, restart your computer, or add more RAM. These fixes address the actual problem instead of working around it.

Page files and your hard drive space

A page file takes up real space on your hard drive. On a computer with 8 GB of RAM, the page file might be 8 GB or more. On a computer with 16 GB of RAM, it could be 16 GB. If your hard drive is small (like 256 GB) and almost full, a large page file can leave you with almost no room for documents, photos, or program updates.

You can see how much space your page file is using by checking the Virtual Memory window on Windows. If the number is very large and your hard drive is nearly full, you have three options: delete files you do not need to free up space, move your page file to a second hard drive if you have one, or reduce the page file size manually. On Mac, you cannot adjust the page file, so your only option is to free up hard drive space or add a second drive.

Frequently Asked Questions

Is a page file the same as virtual memory?

Yes, mostly. Virtual memory is the general term for using hard drive space as extra memory. A page file is the specific file your computer creates to do that. When someone says "virtual memory", they usually mean the page file.

Will deleting my page file make my computer faster?

No. Your operating system will recreate it when ready. You cannot delete it permanently, and if you somehow did, your computer would not work correctly. The page file itself is not the problem — needing to use it is the problem, which means you need more RAM or fewer programs open.

Can I move my page file to a USB drive or external hard drive?

On Windows, you can move it to a second internal hard drive if you have one, but moving it to a USB drive or external drive will make your computer much slower because those are slower than internal drives. It is not worth doing.

What happens if my hard drive is full and I have no page file space left?

Your computer will slow down dramatically or crash when it tries to use the page file and cannot find space. The fix is to delete files you do not need, move files to cloud storage, or add a second hard drive. Do not try to disable the page file — that will cause more problems.

Do I need to restart my computer after changing the page file?

Yes, on Windows you must restart for page file changes to take effect. On Mac, you cannot change the page file, so this does not explore.