Minecraft sometimes lags on my PC, and I read that allocating more RAM can help. I’m not sure how to do this with the Minecraft Launcher. Need instructions for both Java Edition and if possible, Windows version.
I’ve done this a few times — it’s pretty easy. Open the Minecraft Launcher, go to the Installations tab, click the three dots → Edit → More Options, and in the JVM Arguments, change the part that says -Xmx2G to something like -Xmx4G (that gives Minecraft 4GB of RAM). Just make sure you don’t allocate more than half of your total system memory, or your PC might slow down.
In order to assign more RAM to Minecraft, open the Minecraft Launcher, select "Installations" and then your profile and choose More Options. Go to the JVM Arguments box and replace the -Xmx2G with a larger number such as -Xmx4G to specify 4GB of RAM. Make sure there is sufficient memory on your system.
To allocate more RAM to Minecraft, you need to open the Minecraft Launcher, then you need to select "Installations" and your profile and choose More Options. In JVM Arguments box, change -Xmx2G to a higher number of 4GB e.g. -Xmx4G. Ensure that you have enough memory in your system.
To allocate more RAM to Minecraft, open the Minecraft Launcher, go to Installations, select your profile, click More Options, and adjust the JVM Arguments. For example, change -Xmx2G to -Xmx4G to give Minecraft 4GB of RAM. Ensure your PC has enough free RAM before increasing.
Yes-no answer: Java Edition yes you can (via the launcher). Windows/Bedrock Minecraft Minecraft does not have a direct slideable RAM; it can be optimized by using Windows settings and game settings. Steps below.
Java Edition (Minecraft Launcher)
Open Minecraft Launcher.
At the top, there is Click Installations.
Identify the profile you are working with (e.g. Latest release) - click the three dots or Edit (pencil)- Edit.
Click More Options.
In "JVM Arguments" search for -Xmx2G (or something like that). Change that to the amount that you need e.g. -Xmx4G Machine has 4G or -Xmx6G Machine have 6G (Use G for GB or M for MB: -Xmx4096M = 4GB.)
More to the point, click Save, and start Minecraft.
Tips:
Vanilla: 2-4 GB is usually fine. Modded packs- 4-8 GB or above based on mods.
Do not use over half of your total RAM and always keep some 2-4GB to use by Windows/ other applications.
Linux compatible Minecraft Minecraft for Windows / Bedrock (Windows 10/11)
It has no preconfigured RAM allocation setting. Do this rather to have improved performance:
Quite unnecessary processes (Kleaner - end heavy apps)
Switch Game Mode On/Switch Settings - Gaming On Game mode
Setting Power plan to High performance (Settings - System - Power & battery).
Fewer in-game graphics: less render distance, less particles, flashy graphics.
(Optional) increase Windows virtual memory (pagefile) if low on RAM System - Advanced system settings - Performance Settings - Advanced - Virtual memory - Change
Go to the Minecraft Launcher → “Installations” → select your version → click “More Options” → in JVM Arguments, change -Xmx2G to a higher value (e.g., -Xmx4G) to allocate more RAM.
In the case of Minecraft: Java Edition, open the Launcher, then go to Installations and then clicking on your version, More options and then JVM Arguments. modify the figure in the -Xmx2G option (i.e., -Xmx4G to 4GB) and save.
Open the Minecraft Launcher, go to Installations, click your version’s three dots → Edit → More Options, and find the JVM Arguments box. Change -Xmx2G to a higher value, like -Xmx4G (for 4GB RAM). Ensure your system has enough free memory to avoid performance issues.
To allocate more RAM to Minecraft, open the Minecraft Launcher, go to Installations, select your version, click More Options, and in the JVM Arguments box, change the -Xmx value (e.g., -Xmx4G for 4GB RAM). Then save and launch the game.
To assign additional RAM to Minecraft, you'll need to access the launcher, head over to Installations, choose the version you've selected, navigate to More Options, and then adjust the JVM argument -Xmx (e.g., -Xmx4G for 4GB). Once you save your changes and relaunch Minecraft, the performance should be improved.
In order to set more RAM to Minecraft, it is needed to open Minecraft Launcher, choose profile and More Options in Installations. Select JVM arguments window and replace -Xmx2G by whatever higher value such as -Xmx4G which implies 4Gb of RAM. Make sure that there is sufficient memory on your system.
During the Minecraft Launcher (Java Edition), find the section Installations under More options, and write down the following in the JVM Arguments part: -Xmx2G and replace it with a bigger number, such as -Xmx4G.
With windows (Bedrock) version you cannot allocate RAM manually, it will automatically make adjustments depending on your system.
Open the Minecraft launcher, and then open the installation tab. Click the three dots next to the version and select Edit. Click More options and then under Java settings, locate JVM Arguments. Set the command from "-Xmx2G" to "-Xmx[amount of RAM you want in gigabytes]G".
Start Minecraft Launcher ->Installations-> Edit->More Options, and alter the JVM argument -Xmx (e.g. -Xmx4G 4GB RAM). Ensure you do not use up your total RAM more than half.
To allocate more RAM in Minecraft, open the Minecraft Launcher, go to “Installations,” select your game version, and click “More Options.” In the JVM Arguments field, change “-Xmx2G” to your desired RAM allocation, like “-Xmx4G” for 4GB. Ensure your system has enough free RAM. Allocating more memory reduces lag and improves performance significantly.
To allocate more RAM to Minecraft, open the Minecraft Launcher → go to “Installations” → select your version → click “More Options” → adjust the JVM argument -Xmx to increase RAM (e.g., -Xmx4G for 4GB). Save and launch.