Java Tutorial: Giving Minecraft more RAM
Posted: 06 Jul 2013, 17:22
Giving Minecraft more RAM
There are a few things to keep in mind before you start:- You need to have a 64bit OS and 64bit Java to use more than 2GB of RAM.
- When selecting your maximum RAM to give to Minecraft it can only be the max of what your system can handle AFTER taking in to account how much memory your Operating System requires.
- Typically the max will be 512MB to 1024MB less than your system's capacity.
- You shouldn't assign more RAM than Minecraft actually needs to run smoothly.
- e.g. if Minecraft will run fine with 3GB of RAM don't allocate 6GB just because you can.
- If you've assigned PermGen this is added on-top of the RAM you assign to Minecraft.
- e.g. if you assign 2GB of RAM to MC and 256MB of PermGen that equals 2.25GB of RAM total.
- Note: Java 8 and over no longer has PermGen at all.
Linux users can type the following in to terminal and divide the result by 1,024,000 to convert it to GB:
Code: Select all
grep MemTotal /proc/meminfo
The Official Minecraft Launcher
Show Newest Launcher- Open the Launcher and click "Minecraft: Java Edition" on the left to show your installations
- Hover over the installation you want to modify and click the ··· icon on the right and in the menu that appears click "Edit"
- In the "Edit installation" window that appears click "More options" at the bottom
- In the area that appears find "Java arguments" and edit the part that says -Xmx2G to a new setting e.g. -Xmx4G
- Click Save and then launch your game as normal
Show Old "New" Launcher
- Open the Launcher and click the ≡ in the top right
- Click "Launch Options" and then enable "Advanced settings"
- Select the profile you want to change the settings for
- Enable "JVM arguments"
- Edit the part that says -Xmx2G to new setting e.g. -Xmx4G
- Click Save and then launch your game as normal
Show Old Launcher
Open the Launcher and click "Edit Profile" > Check the "JVM Arguments" box and type in the amount of RAM you want, e.g. -Xmx4G (you can also type -Xmx4096M) to give Minecraft 4GB > Click "Save Profile"
MultiMC / PrismLauncher
ShowMultiMC and PrismLauncher are free, open source launchers for Minecraft. They allow you to have multiple, cleanly separated instances of Minecraft (each with their own mods, texture packs, saves, etc) and helps you manage them and their associated options with a simple and powerful interface.
- Right click your instance
- Select "Edit Instance" from the menu
- Check the "Memory" box
- Set "Minimum memory allocation" and "Maximum memory allocation" to desired limit
Feed the Beast, Technic, AT Launcher, VoidLauncher
Note: All of this information was correct for each launcher at the time of writing.Show
Modpack launchers generally have a setting to change the RAM easily via a dropdown or slider.
Feed the Beast
Open the launcher > click Options > adjust the "RAM Maximum (MB)" slider:Technic
Open the launcher > click Options > adjust "Memory to allocate" dropdown:ATLauncher
Open the launcher > click Settings > adjust "Memory/RAM" dropdown:VoidLauncher
Open the launcher > click Options > uncheck "Let java decide optimal values." > specify "Max" RAMChangelog
Show
12 May, 2023: Added PrismLauncher
08 August, 2019: Added instructions for the newest Minecraft launcher.
24 October, 2018: Tidied up the thread, mainly to simplify the information a bit.
18 January, 2017: Added Minecraft New Launcher
29 September, 2015: Added note about not allocating more RAM than necessary
22 September, 2014: Added info about finding amount of RAM in system
08 August, 2014: Added some info about PermGen
15 June, 2014: Renamed Feed the Beast, Technic and AT Launchers to Feed the Beast, Technic, AT Launcher, VoidLauncher and added VoidLauncher
08 March, 2014: Updated Minecraft Launcher image
26 October, 2013: Renamed Feed the Beast and Technic Launchers to Feed the Beast, Technic and AT Launchers and added ATLauncher
2nd July, 2013: Added MC Launcher section
08 August, 2019: Added instructions for the newest Minecraft launcher.
24 October, 2018: Tidied up the thread, mainly to simplify the information a bit.
18 January, 2017: Added Minecraft New Launcher
29 September, 2015: Added note about not allocating more RAM than necessary
22 September, 2014: Added info about finding amount of RAM in system
08 August, 2014: Added some info about PermGen
15 June, 2014: Renamed Feed the Beast, Technic and AT Launchers to Feed the Beast, Technic, AT Launcher, VoidLauncher and added VoidLauncher
08 March, 2014: Updated Minecraft Launcher image
26 October, 2013: Renamed Feed the Beast and Technic Launchers to Feed the Beast, Technic and AT Launchers and added ATLauncher
2nd July, 2013: Added MC Launcher section