April 9, 2020

NetBeans Shortcuts and Cheat Sheet

Java Application Development
Open Source

While not as popular as other Java IDEs, NetBeans is still a popular choice for developers who need a lightweight, free IDE. In this article, we’ll give an overview of the NetBeans IDE, then compare IntelliJ vs. NetBeans. Afterward, we'll give our list of helpful NetBeans shortcuts, and end with a link to our one-page NetBeans cheat sheet pdf.

What Is NetBeans?

NetBeans is an open-source IDE used in Java, PHP, C/C##, HTML5 and JavaScript development.

Originally available as a commercial IDE, NetBeans was converted to open source by Sun in June, 2000. NetBeans was later acquired by Oracle who subsequently donated the NetBeans source code to the Apache project, where it now exists as a Top Level Apache Project.

How Many People Use NetBeans?

In our 2020 Java Developer Survey, 3.51% of respondents reported using NetBeans. IntelliJ was far and away the most popular IDE for Java developers at 81.7%.

2020 Java Technology Report - Java IDE Usage Chart

Is NetBeans Free?

The NetBeans IDE and NetBeans Platform are free for commercial and non-commercial use within the stipulations provided in the “Apache License”.

Is NetBeans Open Source?

NetBeans is open source, meaning developers can download the entire source code for NetBeans and use it within the constraints of the Apache License terms of use.

IntelliJ vs. NetBeans

While IntelliJ is by far the more popular of the two IDEs, NetBeans does offer some unique advantages for developers. The primary benefit compared to IntelliJ IDEA, of course, is that the full version of NetBeans is free (IntelliJ offers a free option with limited features).

For students learning to code in Java, or for small or niche development teams looking for a low-overhead, lightweight IDE, NetBeans can be an attractive option. But compared to IntelliJ IDEA, NetBeans does have some shortcomings.


Because NetBeans it’s open-source, and the comparative user base is lower, finding support options and resources can be a challenge. Paid support options do exist, like the Oracle Java Development Tools Support — which runs $1200 per month.


IntelliJ IDEA offers a user-friendly, highly functional IDE out of the box. NetBeans, in comparison, requires added modules in order to reach comparable functionality – especially when developing enterprise level applications. But, for students or small development teams, NetBeans (or IntelliJ Community) can be a good fit.

User Experience

NetBeans has put a big effort into user experience in the last few years. In their latest release, for example, NetBeans introduced a user experience overhaul via the new FlatLaf and FlatLaf Dark themes. But, as a lightweight and open-source IDE, it doesn’t offer the same level of intuitive and user-friendly experience that makes IntelliJ so popular for developers.

What Java Tools Are You Using?

Our 2020 Java Developer Productivity Report looks at the technologies Java developers are using to develop programs today, and gives key insights into the problems they face during development.

Download Now

NetBeans Shortcuts

NetBeans has a variety of shortcuts that make it easy to search, navigate files, edit text, and refactor code. The NetBeans shortcuts below can help developers streamline their coding efforts.

NetBeans has a variety of shortcuts for finding usages, finding and replacing in files and projects, and more.

NetBeans Search Shortcuts
ActionWindowsOS X
Find usagesAlt + F7Ctrl + F7
Find usages (results)Alt + Shift +UCtrl + Shift + U
Find / Replace in fileCtrl + F/H⌘ + F/R
Find / Replace in projectsCtrl + Shift + F/H⌘ + Shift + F/H
Find nextF3⌘ + G
Select in projects / files / favoritesCtrl + Shift + 1/2/3⌘ + Shift + 1/2/3

NetBeans File Navigation Shortcuts

NetBeans has file navigation shortcuts that allow developers to quickly open and navigate files and code.

NetBeans File Navigation Shortcuts
ActionWindowsOS X
Open resource / Navigate to fileAlt + Shift + OCtrl + Shift + O
Open typeCtrl + O⌘ + O
Go to lineCtrl + GCtrl+G
Recent filesCtrl + Shift + TShift + ⌘ + T
Tab / File switcherCtrl + TabCtrl + Tab

NetBeans Text Editing Shortcuts

NetBeans uses the following shortcuts to move, delete, copy, select and format code.

NetBeans Text Editing Shortcuts
ActionWindowsOS X
Move linesAlt + Shift + Up/DownCtrl + Shift + Up/Down
Delete linesCtrl + E⌘ + E
Copy / Duplicate linesCtrl + Shift + Up/DownAlt + Shift + Up/Down
Select identifierAlt + Shift + JCtrl + Shift + J
Format codeAlt + Shift + FCtrl + Shift + F

NetBeans Code Navigation Shortcuts

For code navigation, NetBeans uses the following keyboard shortcuts to find usages, inspect code hierarchy, and open and navigate to type and member hierarchies.

NetBeans Code Navigation Shortcuts
ActionWindowsOS X
Find usages / References in workspaceAlt + F7Ctrl + F7
Find usages resultsAlt + Shift + UCtrl + Shift + U
Inspect code hierachyAlt + Shift + F12Ctrl + Shift + F12
Open / Navigate to declarationCtrl + B⌘ + B
Open / Navigate to type hierarchyAlt + F12Ctrl + F12
Open / Navigate to member hierarchyCtrl + F12⌘ + F12

NetBeans Refactoring Shortcuts

For refactoring, NetBeans uses the following keyboard shortcuts.

NetBeans Refactoring Shortcuts
ActionWindowsOS X
RenameCtrl + RCtrl + R
Surround withAlt + EnterCtrl + Enter
Extract local variableAlt + Shit + VCtrl + Shift + V
Extract / Assign to fieldAlt + Shift + ECtrl + Shift + E
Extract methodCtrl + Shift + MCtrl + Shift + M

Additional Resources

We hope this article gave you some insight into why developers use NetBeans, and some of the NetBeans shortcuts you can use while using this lightweight IDE. While we didn't have time to compare Netbeans to Eclipse this time around, this blog on the benefits of Eclipse vs. Netbeans is a good read. Or, if you want to learn more about the new features being added to NetBeans, and what to expect from future releases, be sure to read this article on the new features in the NetBeans IDE

If you're looking for additional Java cheat sheets, be sure to check out the links below:

If you have additional requests for cheat sheets, be sure to reach out to us on Twitter at @JRebel_Java.

Download the NetBeans Cheat Sheet

Want a one-page version of our NetBeans shortcuts? Click the button below to download our one-page NetBeans cheat sheet.

Image Resource NetBeans Cheat Sheet


Try JRebel for NetBeans

JRebel works great with NetBeans. Want to try it for free on your project? You can request a trial today by clicking the button below.

Try JRebel for Free