How to improve Netbeans performance?

Is there a real way to get Netbeans to load and work faster?

It is too slow and gets worse when you have been coding for some time. It eats all my RAM.

I am on a Windows machine, specifically Windows Server 2008 Datacenter Edition x64, 4Gb of RAM, 3Ghz Core 2 Duo processor, etc. I am using the x64 JDK. I use the NOD32 Antivirus since for me it is the best in machine performance.

In Task Manager netbeans.exe only shows no more than 20 Mb, java.exe more than 600Mb.

My project is a J2EE web application, more than 500 classes, only the project libraries not included (externals). And when I said slow, I mean 3, 4, 5 minutes or more Netbeans is frozen.

Is my project just too large for Netbeans, if it has to read all files to get the state of files like error warnings, svn status and more? Can I disable all this? Is it possible to set it to scan only when I open a file?

My CPU use is normally at 30 percent with all my tools opened, I mean Netbeans, MS SQL Manager, Notepad, XMLSpy, Task Manager, Delphi, VirtualBox. Netbeans eats more RAM than my virtualized systems.

In Linux it is as slow as in Windows in the same machine (Ubuntu 8.04 x64).

It is true that the Netbeans team improved startup speed but when it opens it begins to cache ALL.

I have used some JVM parameters to set high memory usage and others: "C:\Program Files\NetBeans Dev\bin\netbeans.exe" -J-Xms32m -J-Xmx512m -J-Xverify:none -J-XX:+CMSClassUnloadingEnabled

But it is still slow.

Asked by: Roman210 | Posted: 23-01-2022

Answer 1

Very simple solution to the problem when your NetBeans or Eclipse IDE seems to be using too much memory:

  1. Disable the plugins you are not using.
  2. close the projects you are not working on.

I was facing similar problem with Netbeans 7.0 on my Linux Mint as well Ubuntu box. Netbeans was using > 700 MiB space and 50-80% CPU. Then I decided do some clean up. I had 30 plugins installed, and I was not using most of them. So, I disabled the plugins I was not using, a whopping 19 plug ins I disabled. now memory uses down to 400+ MiB and CPU uses down to 10 and at max to 50%.

Now my life is much easier.

Answered by: Patrick935 | Posted: 24-02-2022

Answer 2

Don't invest time in optimizing your NB installation as long as you can scale vertically: get a SSD (and faster hardware in general).


  • Add an exception for all relevant folders (e.g. project dir, temp dir) to your anti virus software (or better, get rid of it).
  • Don't use network drives for your projects
    • check if your home drive is local
    • check if your IDE uses non-local folders (e.g. %AppData%)

Answered by: Kristian225 | Posted: 24-02-2022

Answer 3

  • Download the latest Netbeans
  • Remove all the plugins you don't need.
  • Use the latest version of Java

Answered by: Marcus572 | Posted: 24-02-2022

Answer 4

We can use the following JVM option to make NetBeans load/run bit faster.

JVM Option: -J-Xverify:none

  • this option tells JVM not to verify byte-code during class loading and avoids preloading unnecessary classes.

How to set:

Edit the file C:\Program Files\NetBeans <version>\etc\netbeans.conf (check your NetBeans installation folder if you installed it in another location)

  • Find the line that says


  • Add the option -J-Xverify:none to the list of options.

  • Restart NetBeans.

Answered by: Roman249 | Posted: 24-02-2022

Answer 5

deactivate Git, Subversion, Local History, Spell checker and other unused plugins

Answered by: Agata696 | Posted: 24-02-2022

Answer 6

I use Windows 7. I suggest right-clicking the NetBeans shortcut, go to Properties, and on the Shortcut tab at the Target, add -J-Xmx1024m -J-Xms256m.

This sets the memory usage of the JVM. Xms is the minimal value, while Xmx is the max.

This is the value of target textfield:

"C:\Program Files\NetBeans 7.1\bin\netbeans.exe" --jdkhome "C:\Program Files\Java\jdk1.6.0_10" -J-Dorg.netbeans.modules.php.dbgp.level=400 -J-Xmx1024m -J-Xms256m

Since I add that attribute, my NetBeans run so fast!

Another way to try More Reference Here

In the etc directory under your Netbeans-Home, edit the file netbeans.conf file. -Xms and -Xmx should be increased to the values that allow your program to compile.

instructions in netbeans.conf :

# Note that default -Xmx and -XX:MaxPermSize are selected for you automatically.
# You can find these values in var/log/messages.log file in your userdir.
# The automatically selected value can be overridden by specifying -J-Xmx or
# -J-XX:MaxPermSize= here or on the command line.

Put the values in the netbeans_default_options string. Example :

netbeans_default_options="-J-client -J-Xss2m -J-Xms32m -J-XX:PermSize=32m -J-Dapple.laf.useScreenMenuBar=true -J-Dsun.java2d.noddraw=true -J-Dsun.java2d.dpiaware=true  -J-Dsun.awt.disableMixing=true -J-Dswing.aatext=true -J-Dawt.useSystemAAFontSettings=lcd --laf Nimbus"

What to do to speed up / free up memory windows:

  1. Disable Windows Update :

    • Open Task Manager, open tab Services, disable Windows Update:

disable win update

  1. Hit Ctrl + R and type Services.msc and press enter.
    • Sort by Startup Type
    • Select Services from 3rd party (non windows) which run Automatic, Right click, click Properties and change startup type to Manual


  • Sort by Status and Stop services from (3rd party) app you think unused

Answered by: Kevin603 | Posted: 24-02-2022

Answer 7

Is it a corporate Windows machine? If so aggressive virus scanners can really slow down modern IDEs. Check your task manager for processes that are using a lot of CPU or disk reads.

Answered by: Abigail230 | Posted: 24-02-2022

Answer 8

Everyone should note that Sun's Java Virtual Machine for Windows does not use shared memory. This means that the more heap you give to your VM, the more memory it keeps to itself. The advantage of more heap is less garbage-collection, and perhaps faster performance of the Java application you're running, but the downside is that your other applications may have less memory to work with, and your system may feel slower due to this.

Answered by: Blake711 | Posted: 24-02-2022

Answer 9

Also defragment your disk. Netbeans is very aggressive about creating caches of one form or another. Most of them get persisted to disk at some point or another which can affect startup time. Virus scanners (Symantec in particular), Desktop search engines, and any other intrusive I/O product can drastically reduce performance.

I have noticed that Netbeans can be tempermental at times and its performance can vary greatly between two machines with nearly identical specs. My work machine has terrible performance and is unusable at times, but it's lightning fast when I use it on my home machine (with bigger projects in many cases).

Answered by: Robert792 | Posted: 24-02-2022

Answer 10

Here are my netbeans options for etc/netbeans.conf using G1 GC and some other improvements.

netbeans_default_options="-J-server -J-Xss4m -J-Xms256m -J-Xmx512m -J-XX:PermSize=256m -J-Dapple.laf.useScreenMenuBar=true -J-Dsun.java2d.noddraw=true -J-Dsun.java2d.dpiaware=true -J-Xverify:none -J-XX:+UseG1GC -J-XX:+TieredCompilation -J-XX:+AggressiveOpts -J-Dswing.aatext=true -J-Dawt.useSystemAAFontSettings=lcd -J-Dorg.netbeans.editor.aa.extra.hints=true"

The font settings (swing.aatex and following) are optional - set as you need or remove.

Those settings are boosting my netbeans a lot!

Answered by: Adrian279 | Posted: 24-02-2022

Answer 11

I've decided to research for last time why my NetBeans was running slow.

I am running PC with 16GB ram and 3.5GHz 8 Core Processor. My CPU usage is around 5-20%, memory is below 40% yet NetBeans is slower than my 15-year-old PC that I have stashed in the garage.

After finding this topic and going through I have realised that in the bottom right corner of the NetBeans I keep seeing a bar that states "Scanning...", after trying to stop it and nothing happening I have looked further at what "Scanning..." was doing and I have realised:

Each time I start the NetBeans, the NetBeans will automatically scan any open projects.

And here it is, I've closed 20 opened projects and NetBeans runs as fast as Notepad.

Answered by: Alberta107 | Posted: 24-02-2022

Answer 12

If its on a corporate machine - make sure that the caches aren't stored on the network

Answered by: Samantha670 | Posted: 24-02-2022

Answer 13

In order to improve Netbeans startup and build times one should (in this order):

  1. Make sure that one has enough free RAM memory (4GB Windows is enough on my 64-bit system)
  2. Buy an SSD, it makes all the difference in startup time and build time (my project build time wend from 60 seconds to 6 seconds!)
  3. Watch out for the virus scanner, they can slow down random file access considerably (make sure they don’t scan your .java and .class files!)
  4. Buy the fastest processor you can get your hands on.

Answered by: Elise622 | Posted: 24-02-2022

Answer 14

I had the same problem with Netbeans being so slow, but it is now much better after deactivating the SVN plug-in. I think that may help.

Good luck

Answered by: Daisy743 | Posted: 24-02-2022

Answer 15

This works for me:

netbeans_default_options="-J-client -J-Xverify:none -J-Xmx1024m -J-Xss2m -J-Xms256m -J-XX:PermSize=32m -J-Dnetbeans.logger.console=true -J-ea -J-Dapple.laf.useScreenMenuBar=true -J-Dsun.java2d.noddraw=true -J-Dsun.java2d.dpiaware=true -J-Dplugin.manager.check.updates=false -J-Dnetbeans.extbrowser.manual_chrome_plugin_install=yes"

Settings in the etc/netbeans.conf.

Answered by: Rafael315 | Posted: 24-02-2022

Answer 16

Simplest solution:

Go to Preferences->Editor and Disable: Auto Popup Completion Window

Use: Meta key + \ instead when you need code completion.

The biggest problem I found was the auto code completion feature. As I typed, it kept on trying to run code completion the whole time. This was causing really slow performance since my project has a lot of libraries that it depends upon.

The best thing of all is you can stop fighting the editor as it keeps picking up false positives in the completion popup.

Have not looked back since I switched this off.

Answered by: Chelsea826 | Posted: 24-02-2022

Answer 17

Really useful article about reasons why your NetBeans is slow:

Answered by: Arnold486 | Posted: 24-02-2022

Answer 18

A more or less detailed description, why NetBeans if slow so often can be found in the article:

Boost your NetBeans performance

First. check what NetBeans is actually doing on your disk. On a Mac you can issue this command:

  sudo fs_usage | grep /path/to/workspace

In my special case I got a directory which didn't exist any longer, but NetBeans tries to access the folder all the time:

  14:08:05 getattrlist /path/to/workspaces/pii 0.000011 java

Repeated many, many, many times. If you have a similar problem, fix it by deleting your NetBeans cache folder here:


If your is still making a lot of disk I/O. Check if it's accessing the subverison folders and svncache.

I had to disable the subversion features with config file:


add a line:


SOURCE: Netbeans forums

IMHO it's mainly related to a lot of disk I/O caused by missing files or folders and svncache.

Answered by: Emma427 | Posted: 24-02-2022

Answer 19

Put your .netbeans Homefolder into a Ramdisk and Netbeans its going to be incredible fast.

I detected on my Ubuntu 16.04 that every Key-Press causes a HDD read or write action. Reason enougth for me to use a Ramdisk. As a little positive side-effect my HDD is quite now (no tickclickrrickrrrticktick any more) and has a longer live.

Answered by: Julian437 | Posted: 24-02-2022

Answer 20

Similar to the suggestion to put everything on an SSD.

I run netbeans from freeBSD. The netbeans cache files were in my home directory in .netbeans. My home directory was mounted over nfs so access was very slow. Moving .netbeans to the local machine greatly improved performance. I added a softlink from .netbeans in my home directory to the local directory. Netbeans describes how to change the usedir and cachedir here and lists this as a reason under item 4.

Prior to this I could write entire sentences in comments before the gui caught up and displayed them. After text appears as I type.

Answered by: Julian129 | Posted: 24-02-2022

Answer 21

For Windows - Should work for other OS as well

Netbeans is just like any other java application which requires tuning for its JVM.

Please read the following link to have some benchmark results for netbeans

The following settings works fine in my Windows 7 PC with 4GB RAM and I5 Quad core processor.

(Check for the line netbeans_default_options in the netbeans config file inside bin folder and replace the config line as follows)

netbeans_default_options="-XX:TargetSurvivorRatio=1 -Xverify:none -XX:PermSize=100M -Xmx500m -Xms500m -XX+UseParallelGC ${netbeans_default_options}"

Small Suggestion: Garbage collection plays a vital part in JVM heap size and since I had a quad core processor, I used Parallel GC. If you have single thread processor, please use UseSerialGC. From my experience, if Xmx Xms values are same, there is no performance overhead for JVM to switch between min and max values. In my case, whenever my app size tries to exceed 500MB, the parallel GC comes in handy to cleanup unwanted garbage so my app never exceed 500MB in my PC.

Answered by: Elise861 | Posted: 24-02-2022

Answer 22

NetBeans 8.0.2 (PHP) has two problems: the SubVersion client and the Twig templates. In order to drastically improve overall performance, a) disable teh "Twig Templates" plugin (this will also deactivate Symphony2, in case you may require it) and b) override the SVN client with this switch:


^ lets one define the CLI arguments individually (which may also make sense with RAM settings and other customization). guess one could re-enable Twig once that linked bug-report has been closed. re-scanning isn't really the issue, while the rescan performs as it should a timely manner.

Just was testing some more and noticed, that on Linux it runs way smoother with the Oracle JDK than the (common) OpenJDK - have seen there is even one version of NetBeans bundled with it.

Answered by: Joyce127 | Posted: 24-02-2022

Answer 23

Had the same issue with Netbeans 7.3.* and 7.4 Beta on Windows 7. Switching some plugins on and off, I figured out it was the svn plugin which boosted the CPU constantly to about 27%, converting my laptop into a toaster. Turn it off and code happy again :)

Answered by: Lucas342 | Posted: 24-02-2022

Answer 24

For me worked out to enable auto-scanning of sources.

Answered by: Carlos317 | Posted: 24-02-2022

Answer 25

I had big problems with NetBeans 8.0.2. It's an old question but perhaps somebody else will end up here like me with the same problem, and I found no answer that helped me anywhere.

I have NetBeans 8.0.2 with Ruby on Rails plugin, on Windows 7. The IDE was hanging up to 10 seconds on almost every change I did in some files. It was problem only with big files, but it must depend on more than that, there were other big files without the problem.

The problem was caused by the "hint" "Rails 3 Deprecations", I turned it off and now it's very fast, I can have everything else turned on without problems.
It's under Tools -> Options -> Editor -> Hints.

There is also some suggestions in the other answers of optimizing with startup parameters. I found these links about JVM-switches that helped me when testing to optimize (but it turned out that these settings have nothing to do with my problem), they are very old but have some useful information:
Explanation of JVM-switches.
Some (old) recommendations

Answered by: Edgar914 | Posted: 24-02-2022

Answer 26

Open the file:


I added some options shown below:

netbeans_default_options="-J-Dsun.java2d.opengl=true -J-Dsun.java2d.d3d=false -J-Xmx2048m ...

Using opengl may help you, depending on your system. I am running OsX. 2048m may be too much, but does not seem to hurt :-) ...

Answered by: Brianna167 | Posted: 24-02-2022

Answer 27

Try to profile Netbeans using VisualVM. If the "hot spot" is org.gnome.accessibility.atkwrapper.emitsignal(), try to run Netbeans with

-J-Djavax.accessibility.assistive_technologies=" "

It helped a lot in my case.

I don't really know why exactly this toolkit used, but looks like it's generally safe to disable it.

Answered by: Eric594 | Posted: 24-02-2022

Answer 28

Close all the instences you have running. You might not have closed any of them in a while causing them to stack up and run in the background. Therefore causing lag/making the program work slower.

Answered by: Maria204 | Posted: 24-02-2022

Answer 29

In my case, I got a huge performance advantage by disabling Rainbow (it's a plugin that is used to color brackets in the code):

Tools -> Options -> Miscellaneous -> Rainbow (uncheck enabled)

Tested on Netbeans 10 with Java 8.

The problem of serious slowdowns occurred exclusively with particularly large Java files (more than 5000 lines of code), while there was no problem with smaller files (within 1000 or 2000 lines of code).

I made other optimizations, but this one was the most relevant, because it drastically reduced the amount of CPU used.

Answered by: Walter327 | Posted: 24-02-2022

Answer 30

The simplest answer to this is to explicitly set Xms and Xmx in the $NETBEANS_HOME/etc/netbeans.conf file. for general cases, the default memory allocation works fine, but for large projects or large numbers of projects, explicitly setting those flags to decently high values will alleviate a lot of the startup lag and runtime stalling of NB during operation.

e.g. on my workstation i typically set NB to Xms=768m and Xmx to upwards of 1536m. obviously tune to your needs and requirements, but that should provide a decent starting point.

Answered by: Vanessa368 | Posted: 24-02-2022

Similar questions

performance - Java program is slower as a dist build than when ran from Netbeans

So I have this neat physics sim I made that, while running at certain settings, runs at around 34 fps when ran via the Netbeans "run" -command. Then I click "clean and build" and go open the program from the dist folder, and it runs at around 10 fps with the same setup. Can it be about Java settings? I don't have any special setting done in Netbeans but I'm not sure how to check my the settings on the installed JRE...

Performance question: Fastest way to convert hexadecimal char to its number value in Java?

I want to convert from char representing a hexadecimal value (in upper or lower case) to byte, like '0'-&gt;0, '1' -&gt; 1, 'A' -&gt; 10, 'a' -&gt; 10, 'f' -&gt; 15 etc... I will be calling this method extremely often, so performance is important. Is there a faster way than to use a pre-initialized HashMap&lt;Character,Byte&gt; to get the value from? Answer

performance - Java very large heap sizes

Closed. This question needs to be more focused. It ...

java - Is there a performance difference between Javac debug on and off?

If I switch on the generating of debug info with Javac then the class files are 20-25% larger. Has this any performance effects on running the Java program? If yes on which conditions and how many. I expect a little impact on loading the classes because the files are larger but this should be minimal.

performance - Size of a byte in memory - Java

I have heard mixed opinions over the amount of memory that a byte takes up in a java program. I am aware you can store no more than +127 in a java byte, and the documentation says that a byte is only 8 bits but here I am told that it actua...

java - Is there a performance difference between a for loop and a for-each loop?

What, if any, is the performance difference between the following two loops? for (Object o: objectArrayList) { o.DoSomething(); } and for (int i=0; i&lt;objectArrayList.size(); i++) { objectArrayList.get(i).DoSomething(); }

performance - Java File Cursor

Is there some library for using some sort of cursor over a file? I have to read big files, but can't afford to read them all at once into memory. I'm aware of java.nio, but I want to use a higher level API. A little backgrond: I have a tool written in GWT that analyzes submitted xml documents and then pretty prints the xml, among other things. Currently I'm writing the pretty printed xml to a temp file (my lib woul...

performance - Accelerate 2D images in Java *without* disturbing JMenus

Already implemented performance boosters : - Get compatible image of GraphicsConfiguration to draw on - Enable OpenGL pipeline in 1.5: Not possible due to severe artifacts So far I am fine, the main profiled bottleneck of the program is drawing an image with several thousand tiles. Unfortunately it is not regular, else I simply could set pixels and scale them. I accerelated the image with VolatileImages and own ren...

performance - Measuring Java execution time, memory usage and CPU load for a code segment

For a particular segment of Java code, I'd like to measure: Execution time (most likely thread execution time) Memory usage CPU load (specifically attributable to the code segment) I'm a relative Java novice and am not familiar with how this might be achieved. I've been referred to

Can anyone quantify performance differences between C++ and Java?

Java was initially slow before the JIT but today performance is pretty close to C++. I want to know if someone has done measurable performance comparisons between the two languages? Where does Java fall short when compared to C++? Java provides many productivity gains to developers so they can write applications much quicker because of garbage college, lack of pointers, etc. Applications such as Firefox, Webkit ...

performance - ArrayList vs. Vectors in Java if thread safety isn't a concern

Is there really that much of a difference between the performance of Vector and ArrayList? Is it good practice to use ArrayLists at all times when thread safety isn't an issue?

Still can't find your answer? Check out these amazing Java communities for help...

Java Reddit Community | Java Help Reddit Community | Java Community | Java Discord | Java Programmers (Facebook) | Java developers (Facebook)