Taming Windows 95/98/98SE/ME Out of Memory Errors

Last Updated on May 12, 2023 by Dave Farquhar

The symptom: If you install more than 512 MB of RAM in a system running Windows 9x (that’s any version of Windows 95, 98, 98SE, or ME), you get weird out of memory errors. Here’s how to get around those memory limitations to make Windows 95 and Windows 98 work with 2 GB of RAM.

The culprit is a bug in Windows 9x’s disk cache. The solution is to limit the cache to use 512MB of memory, or less, which is a good thing to do anyway.

Windows 98 out of memory when you have 2 gigabytes?

The problem is Windows 95 and 98 weren’t designed for those amounts of memory. But there’s a workaround.

Open c:\windows\system.ini in a text editor. Scroll down to the section titled VCACHE and add these two lines:



If you’re using 1 GB of RAM, you may want to set MaxFileCache to 262144 instead.

How much cache is enough?

Windows 95 and 98 out of memory error 512 MB 2 GB
With Windows 95 and 98, there was such thing as too much memory, and 1 GB too much, unless you know my trick.

In my book Optimizing Windows, I recommended you use 1/8 of available system RAM or 1024, whichever was smaller, for the MinFileCache, and 1/4 of available RAM or 16384, whichever was lower, for MaxFileCache. I think I found that 16384 was the point of diminishing returns, but keep in mind that at the time I had no more than 256 MB of RAM in any of my systems, and in 1999, people thought I was nuts for putting that much in.

With that 1-2 GB of memory available, even if you set the maximum cache size to 512 MB, you’ll always have more memory available than I had when I wrote the book. So I guess there’s no real harm in it.

On a really slow machine–and by that I meant a 386 or a 486 CPU–I suggested setting both MinFileCache and MaxFileCache to 1/4 of available memory to save CPU cycles. But if you’re putting 2 GB of RAM in a system, you’re not using a 486.

If you have a P3 or P4, you might as well let Windows use its smarts.

What is the RAM limit for Windows 98?

Without the hack I described above, the RAM limit for Windows 98, 95, 98SE, and Windows Me is effectively 512 MB. With the hack I describe above, you can put 2 GB of RAM in a Windows 98 system and not get the out of memory error that results from having too much RAM.

Is 512 MB enough to run Windows 95 or 98?

I hear people say today that Windows 9x doesn’t run well with any less than 512 MB of RAM, but I never ran any version of Windows 9x on a machine with that much memory in it. By the time it was affordable to put even 256 MB of RAM in a system, I was running Windows 2000 on everything. When I started my career, I supported desktops running Windows 95 with 16-24 MB of RAM in them. There may be certain programs you’re trying to run that don’t like having less than 512 MB of RAM, but the operating system itself is perfectly happy with 64-256 MB of RAM. When Windows 95 came out, 8 megabytes was the standard, and 16-32 megabytes was what power users had.

The other thing to check, if you’re experiencing poor performance, is the size of the disk. The FAT16 and FAT32 filesystems don’t deal all that well with large disks, and by large, we’re talking hundreds of gigabytes. Use a smaller disk, and consider an SD card. It’s more reliable, and will usually perform better too. The driver issue that kills CD-ROM drives can also hurt performance.

Other benefits to tuning VCACHE

Tuning the VCACHE settings, in addition to eliminating the out of memory errors, improves performance. Sometimes Windows 9x didn’t make good decisions about how much memory to allocate to the disk cache versus what it allocated for applications, especially on low-memory systems. Setting some boundaries really helped, in those instances. And I suspect that those people who say their Win9x performance went through the roof after they upgraded beyond 512MB of RAM would have seen a similar benefit just from tweaking their VCACHE settings and partitioning their drives so their operating system and programs were on smaller volumes. I used to partition the C drive to 2 GB or less and format it FAT16 and install the operating system on that. That caused performance to go through the roof.

But as cheap as memory is these days, if putting a ton of RAM in a Windows 9x box makes you happy, go ahead and do it. Just don’t ask me how well it runs or doesn’t run. My Windows 98 machine is a Pentium II with 256 MB of RAM.

If you found this post informative or helpful, please share it!

3 thoughts on “Taming Windows 95/98/98SE/ME Out of Memory Errors

  • April 7, 2017 at 3:07 pm

    Reminds me of the time I was trying to put the swap file of a Win95/Win98 machine at the beginning of the disk for faster access. I asked around and around to no avail. Finally some smart-ass told me any time I’d save had already been wasted by trying to figure out how to do it!

    • April 7, 2017 at 10:02 pm

      I’m pretty sure some of the third-party defragmenters from the utility suites for Win9x could do that. Think Norton Utilities, but there were others at the time too. If they could, it’s in my old book. But that’s mostly trivia now.

      It might have also been possible to create a small partition at the front of the drive, install Windows to drive D, then redirect swap to the smaller drive C. I can’t think of a reason that wouldn’t have worked, not that I’m going to mess around with trying it…

Comments are closed.

%d bloggers like this: