Partner – Moderne – NPI EA (cat=Spring Boot)
announcement - icon

Refactor Java code safely — and automatically — with OpenRewrite.

Refactoring big codebases by hand is slow, risky, and easy to put off. That’s where OpenRewrite comes in. The open-source framework for large-scale, automated code transformations helps teams modernize safely and consistently.

Each month, the creators and maintainers of OpenRewrite at Moderne run live, hands-on training sessions — one for newcomers and one for experienced users. You’ll see how recipes work, how to apply them across projects, and how to modernize code with confidence.

Join the next session, bring your questions, and learn how to automate the kind of work that usually eats your sprint time.

Course – Black Friday 2026 – NPI EA – main – before_post_content
announcement - icon

Yes, we're now running our Black Friday Sale. All Courses are 33% off until 4th December, 2026 at 17:00 Romania time:

>> EXPLORE ACCESS NOW

Course – Black Friday 2026 – NPI – main – before_post_content
announcement - icon

Yes, we're now running our Black Friday Sale. All Courses are 33% off until 4th December, 2026 at 17:00 Romania time:

>> EXPLORE ACCESS NOW

1. Overview

IntelliJ IDEA is a popular integrated development environment (IDE) with robust features and capabilities. However, as projects become complex, we may encounter scenarios in which the amount of memory IntelliJ allocates by default is insufficient for our needs.

In this tutorial, we’ll learn to increase the memory size limit on IntelliJ IDEA. Overall, this ensures a smoother and more responsive development experience.

2. Adjusting the Memory Settings

Adjusting memory settings involves modifying the configuration to allocate sufficient memory resources for the Java Virtual Machine (JVM) to operate efficiently. This process is crucial when working on large projects or dealing with memory-intensive tasks.

Let’s now go through the step-by-step process of adjusting the memory allocation.

2.1. Updating the idea.vmoptions File

The first step is to determine the installation directory of the IntelliJ IDEA application on the machine. Further, we’ll locate the idea.vmoptions file inside the installation directory. This file is generally present inside the bin folder.

Once we’ve located the idea.vmoptions file, let’s now adjust the JVM parameters -Xms (minimum heap size) and -Xmx (maximum heap size) to allocate more memory:

idea.vmoptions File

The above settings will allocate an initial heap size of 256 megabytes and a maximum heap size of 2048 megabytes. Make sure to adjust these values based on the project’s requirements and available system resources.

At last, save the changes and restart IntelliJ IDEA to apply the new memory settings.

2.2. Updating Memory Settings from the UI

Alternatively, we can also modify memory settings from the IntelliJ UI, using the “Help” ->“Change Memory Settings” menu option:

Memory Settings from the UI

Using this method, we can only update the maximum heap size. Moreover, all the changes made from the UI will be saved to the idea.vmoptions file:

maximum heap size

At last, we need to restart IntelliJ IDEA for our changes to take effect. Click on the “Save and Restart” button.

3. Monitor Memory Usage

After updating the allocated memory to a desired value, monitoring memory usage is essential to ensure optimal performance. IntelliJ IDEA provides a way to track memory consumption to help developers identify potential issues.

Right-click on the bottom right part of the taskbar. Select the “Memory Indicator” option to enable the memory indicator:

Memory Indicator

After enabling it, we can easily monitor memory consumption by heap and JVM. Hover over the bottom right corner of the status bar to view the breakdown:

monitor memory consumption by heap and JVM

Alternatively, we can double-press the “Shift” key and search for the “Memory Indicator”.

4. Conclusion

This article discussed the importance of memory allocation in a development environment and how to increase it for IntelliJ IDEA. Firstly, we updated the memory using the configuration file. Further, we learned to update it using IntelliJ’s UI.

Remember to regularly evaluate the project’s requirements and adjust memory settings accordingly.

Partner – Moderne – NPI EA (tag=Refactoring)
announcement - icon

Modern Java teams move fast — but codebases don’t always keep up. Frameworks change, dependencies drift, and tech debt builds until it starts to drag on delivery. OpenRewrite was built to fix that: an open-source refactoring engine that automates repetitive code changes while keeping developer intent intact.

The monthly training series, led by the creators and maintainers of OpenRewrite at Moderne, walks through real-world migrations and modernization patterns. Whether you’re new to recipes or ready to write your own, you’ll learn practical ways to refactor safely and at scale.

If you’ve ever wished refactoring felt as natural — and as fast — as writing code, this is a good place to start.

Course – Black Friday 2026 – NPI EA – main – after_post_content

announcement - icon

Yes, we're now running our Black Friday Sale. All Courses are 33% off until 4th December, 2026 at 17:00 Romania time:

>> EXPLORE ACCESS NOW

Course – Black Friday 2026 – NPI – main – after_post_content

announcement - icon

Yes, we're now running our Black Friday Sale. All Courses are 33% off until 4th December, 2026 at 17:00 Romania time:

>> EXPLORE ACCESS NOW