OutOfMemoryErrorGeneral 8,917 views

How to Fix java.lang.OutOfMemoryError: Java heap space

Proper JVM heap allocation (-Xmx) configuration in SuperLauncher for smooth modpack & shader gameplay.

Compatibility:OS: windows, macos, linux, steam-deck•Loaders: vanilla, fabric, forge, neoforge•Versions: 1.21.1, 1.20.4, 1.20.1, 1.19.4, 1.16.5, 1.12.2
oomheaprammemoryxmx

Causes of Error & Description

Why OutOfMemoryError Occurs? The JVM has reached its allocated upper limit set by `-Xmx`. Heavy modpacks usually require 4GB to 8GB of RAM.

Step-by-Step Solutions

Allocate 6GB RAM in SuperLauncher Memory Slider

Automated Fix
1
Open Settings

Click gear icon in SuperLauncher.

2
Adjust RAM Slider

Set allocated memory to 6144 MB (6GB).

3
Save and Play

Launch game and monitor memory with F3 screen.

Quick Repair in SuperLauncher
Execute action without manual configuration "allocate_ram"
Run Repair in SuperLauncher

Did this article solve your problem?

Your feedback helps improve our guides and launcher algorithms.

SuperLauncher

Жива підтримка

👤 Чат з оператором

Напиши повідомлення — оператор побачить його одразу і відповість тут же в чаті.