This wikiHow teaches you how to increase the amount of memory (RAM) that Minecraft can use, which may help solve memory errors. If you're using your personal version of Minecraft, you can easily allocate RAM from launcher versions 1.6 through 2.0.X; you can check your launcher version number in the lower-left corner of the launcher window. If you're editing a server's RAM, you will need to create a file that will launch Minecraft with more memory. It's a good idea not to allocate more than half to two-thirds of your computer's total RAM to Minecraft.
Steps
-
Check your computer's available RAM. The amount of available RAM will dictate how much memory you can allocate to Minecraft. To check RAM:
- Windows - Open Start , click the Settings gear, click System , click About , and look at the number next to "Installed RAM".
- Mac - Open the Apple menu , click About This Mac , and look at the number to the right of the "Memory" heading.
-
Update your Java program . Go to Java's website at https://www.java.com/en/download/ and click the "Download" button below the latest version of Java. This will ensure that your Java version is up-to-date and ready for RAM allocation.
- If you're on Windows, make sure you download the correct bit version for your operating system. You can only allocate 1 GB of RAM on a 32-bit computer.
Advertisement -
Open your Minecraft server directory. This is the folder that contains the Minecraft_server.exe file that you launch to start your Minecraft server.
- The easiest way to find this is by searching for the "Minecraft_server" file and then opening its file location.
-
Create a text document in your server folder. Click either Home (Windows) or File (Mac), then either click New item (Windows) or select New (Mac) and click Text Document . This will create a new text document in the same location as the minecraft_server.exe file.
-
Enter in the code to allocate more RAM. Enter the following code into your text document depending on the operating system you are using:
Windows
java -Xmx #### M -Xms #### M -exe Minecraft_Server.exe -o true
PAUSE
OS X#!/bin/bash
cd "$( dirname "$0" )"
java -Xms #### M -Xmx #### M -exe Minecraft_Server.exe -o true
Linux#!/bin/sh
BINDIR=$(dirname "$(readlink -fn "$0")")
cd "$BINDIR"
java -Xms #### M -Xmx #### M -exe Minecraft_Server.exe -o true
- Change #### to the value in megabytes that you want to allocate. To allocate 2 GB, type 2048 . To allocate 3 GB, type 3072 . To allocate 4 GB, type 4096 . To allocate 5 GB, type 5120 .
-
Save the file. If you are using windows, save the file as a ".bat" file. Click File and select Save As... . Change the file extension from ".txt" to ".bat". If you are using OS X, save the file as a ".command" file. If you are running Linux, save the file as a ".sh" file.
- You may first have to enable file extensions on Windows to view them.
-
Run the new file to start Minecraft. The file you create will be the new launcher for your Minecraft server. Launching with the new file (.bat for Windows, .command for Mac, or .sh for Linux) will allocate the new amount of RAM to the server.
-
Check your computer's available RAM. The amount of available RAM will dictate how much memory you can allocate to Minecraft. To check RAM:
- Windows - Open Start , click the Settings gear, click System , click About , and look at the number next to "Installed RAM".
- Mac - Open the Apple menu , click About This Mac , and look at the number to the right of the "Memory" heading.
-
Update your Java program . Go to Java's website at https://www.java.com/en/download/ and click the "Download" button below the latest version of Java. This will ensure that your Java version is up-to-date and ready for RAM allocation.
- If you're on Windows, make sure you download the correct bit version for your operating system.
-
Open the Minecraft launcher. Double-click the Minecraft icon to do so.
- If the launcher window has "1.6..." in the bottom-left corner (or at the top of the window), use the launcher version 1.6.X method instead.
-
Click the Installations tab. It's at the top of the launcher.
-
Make sure the Advanced settings switch is on. This switch is in the top-right side of the Launch Options page. If the switch isn't green, click it before continuing.
-
Click the profile you want to change. If you only see one option on this page, just click that option.
-
Ensure the JVM arguments are enabled. See the text box called JVM arguments to enable this feature.
-
Edit the amount of RAM that Minecraft can use. You'll see a line of text in the "JVM arguments" text field, the first section of which says -Xmx1G ; change the "1" to the number of gigabytes of RAM you want to use for Minecraft.
- For example, you would change this text to say "-Xmx4G" to use four gigabytes of RAM with Minecraft.
-
Click SAVE . It's at the bottom of the window. Minecraft will now use your selected amount of RAM for the specified profile.
-
Check your computer's available RAM. The amount of available RAM will dictate how much memory you can allocate to Minecraft. To check RAM:
- Windows - Open Start , click the Settings gear, click System , click About , and look at the number next to "Installed RAM".
- Mac - Open the Apple menu , click About This Mac , and look at the number to the right of the "Memory" heading.
-
Update your Java program . Go to Java's website at https://www.java.com/en/download/ and click the "Download" button below the latest version of Java. This will ensure that your Java version is up-to-date and ready for RAM allocation.
- If you're on Windows, make sure you download the correct bit version for your operating system.
-
Start the Minecraft launcher. In 1.6.X and newer, you can allocate more RAM directly from the Minecraft launcher. If you are using an older version, see the next section.
- If the launcher window has "2.0..." in the bottom-left corner, use the launcher version 2.0.X method instead.
-
Select your profile. Click Edit Profile and select a profile from the list.
-
Enable JVM Arguments. In the "Java Settings (Advanced)" section, check the "JVM Arguments" box. This will allow you to enter commands to modify the Minecraft program.
-
Allocate more RAM. By default, Minecraft will allocate 1 GB of RAM for itself. You can increase this by typing -Xmx # G . Replace # with the number of gigabytes you want to allocate. For example, if you wanted to allocate 18 GB, you would type -Xmx18G .
-
Save your profile. Click Save Profile to save your settings. Your specified amount of RAM will now be applied to your selected profile.
Community Q&A
-
QuestionAfter using method one, my Minecraft still runs at 38-42 fps, and it only uses 1250 MOB out of the 4,000 I assigned it. How do I fix this?Community AnswerRAM isn't the only thing that contributes to the amount of FPS. You need to consider how powerful your CPU is and what your graphics settings are in game. My suggestion is try lowering your render distance and particles. Also, make sure V-Sync is off, as this does limit your frame rate. Another thing you could try is installing Optifine, which gives you more control over your graphics settings.
-
QuestionIf I have 2 GB of RAM, do I use -Xmx1G or -Xmx2G?Community AnswerI would say the first one, as you would then allocate 1 GB of RAM, and you don't want everything else on your computer quitting.
-
QuestionMy newly built computer has 16 GB total of RAM. Am I okay to allocate half of it to Minecraft?Community Answer16 BG is a lot of space.You shouldn't need all 8 GB to play Minecraft.
Video
Tips
- Leave a generous amount (at least a third) of RAM for your computer's operating system.Thanks
- Allocating more RAM in Minecraft enhances your gameplay experience. This can also be helpful at all if ever you use a high-quality texture pack or shaders which uses more RAM at all. That means you can also improve the FPS by using your dedicated graphics card or consider purchasing a new high-end graphics card.Thanks
- If you experience some FPS fluctuation either serious freezing of the game, consider reducing the given size allocated of the JVM into half or a partial.Thanks
Warnings
- Be careful that you do not allocate more RAM than your computer has, or else you will get an error that the Java VM failed to start, and Minecraft will not run.Thanks
- Minecraft is not ideal to run on a Guest Virtual Machine that runs on your PC. Otherwise, use the Host one (or your main boot OS).Thanks
About This Article
1. Open the launcher.
2. Click Launch Options
.
3. Enable Advanced Settings
.
4. Select a profile.
5. Enable ″JVM arguments.″
6. Edit the amount of RAM.
7. Click SAVE
.