I have been trying for ages to get my minecraft to use more RAM, but it refuses to allocate more than 20% ram on my 4G computer. I want to allocate 2G, so the first method I tried was to type this into the JVM Arguments box in the edit profile option in the new launcher. This is what everyone told me to type in:

-Xms2048 -Xmx2048

Unfortunately after typing this in, saving my profile, and running minecraft, I get a window that pops up that says: there was an error in the Java Virtual Machine. Is there anyway I can get minecraft to allocate more RAM? I also tried going to Java and changing the settings there, but it still didn't work.

  • 1
    Have you tried restarting Minecraft? I know it's a stupid solution, but sometimes it works. Perhaps try just -Xms512M -Xmx2048M because min and max aren't the same number there; that could be causing the problem. Also, +1 for the very clearly stated question.
    – Atutouato
    Apr 30, 2014 at 22:54
  • @Atutouato Yes I have restarted minecraft, time and time again over. Apr 30, 2014 at 23:14
  • 6
    Yeah, these numbers are in bytes, add M at the end to make them megabytes
    – Kcats
    May 1, 2014 at 6:49
  • 1
    @Kcats this sounds like it should be and answer instead of a comment.
    – MrLemon
    May 2, 2014 at 8:05
  • @Kcats FTW. Additionally, Appending G will spec gigs of memory. More is always better too. You should make sure you have 2gb of memory free before allocating. 4gb of total memory is kinda lean these days, especially if you're running Windows. You can get away with MC on linux in 4gb no problem. May 9, 2014 at 16:02

2 Answers 2


These numbers are in bytes, add M at the end to make them megabytes.

Contrary to the popular belief, more is not always better. As always with performance optimizations you should measure first, understand the problem, and then increase JVM memory only if that is indeed the problem (and then measure yet again to check if that fixed anything). For example, look at the "Used Memory: xx%" at the top right of the F3 screen. Normal behavior is it increases for a few seconds and then drops sharply and then starts to increase again and so on. If the minimum is hovering above 75%, or the maximum consistently hits 90%+, then Java memory might be a problem.

  • While I agree with your answer, I do not agree with your statement that more memory isn't better. Having 4gb of memory might be fine for someone playing minecraft and nothing else, but open a browser with 15 tabs at the same time. Better yet, run eclipse at the same time as minecraft with a browser and 25 tabs. You can play with settings all you want, but as soon as you run something else that interferes with that finely tuned JVM, your work will be for naught. computermemoryupgrade.net/why-more-ram-is-better.html tomshardware.com/forum/285680-30-more-faster-memory May 12, 2014 at 16:21
  • The OP said "more is not always better" (as in allocating more is not always better) not "more physical RAM is not always better". There comes a threshold where allocating too much physical memory to a particular process becomes counter productive.
    – k1DBLITZ
    May 14, 2014 at 16:05

This may because you are running a 32-bit operating system and Minecraft only allows itself to use 1.5bgs of ram when using a 32-bit version of Java, and the reason why I know this is because of me trying to play Feed the Beast with a 4gb 32-bit computer. It says when you launch the Feed the Beast launcher that "Your system is using a 32-but version of Java. This will limit Minecraft to 1.5gb of RAM." I found this page because I was wondering if there was a way around this error popping up without upgrading to a 64-bit version of Java.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .