Super efficient keyboard shortcuts in JetBrains IntelliJ IDEA

Jonathan Hermansen
4 min readAug 18, 2020
Photo by Nhu Nguyen on Unsplash

If you work a lot in the IntelliJ IDEA, you may know about some effective keyboard shortcuts that make the coding a lot faster. Since I’ve started using IntelliJ I effectively used keyboard shortcuts, and they keep coming with more and more useful shortcuts. In this article, I will share with you some of my most recent discovered shortcuts that I find very useful!

Copy history

CTRL + SHIFT + V

The first shortcut I want to share with you is a handy one, instead of going back and forth, copy and pasting, you can just copy everything you need one by one, and then open the copy history that will contain all your copies row by row.

Navigate back and forth

CTRL+ ALT+ BACK ARROW / RIGHT ARROW

For you who use the back and forth buttons on the mouse a lot, this shortcut is nice if you want to keep your hands on the keyboard while coding.

Recent locations

CTRL + SHIFT + E

Say you edited a block of code earlier, you can’t remember the file name, but remember the code that you worked on. This shortcut opens a window that not only shows the recent files but also were you edited in that specific file.

Make variable from code

CTRL + ALT + V

A useful shortcut that automatically chooses and assigns a value to type.

Show file structure

CTRL+ F12

For larger classes, this will show you a list of all the methods and Instance variables of the class.

Mark multiple cursors

SHIFT + ALT + LEFT MOUSE

Want to insert some code multiple places? This shortcut helps you mark more than one place with the text cursor, so you can edit more places at the same time. You could also just hold ALT-key and drag down the lines you want to edit.

Extract to method

CTRL + ALT + M

This shortcut lets you mark lines of code and extract it to a new method, a window pops up that lets you edit things like access modifiers, parameters, and more.

Check definition

CTRL + SHIFT + I

This opens a window that shows you where the class got declared. This is handy since you don't have to open the class in a new tab to check it out real quick.

Last edited location

SHIFT + CTRL + BACKSPACE

An effective way to go back to where you last edited code. Say you are working with a piece of code, and need to check out another class, this shortcut quickly takes you back where you edited.

Class hierarchy

CTRL + H

A quick way to see the class hierarchy of the active class, all the way up to the Object class.

That's it!

I hope that you’ve got some new useful keyboard shortcuts out of this.

P.S. Under Help > Productivity Guide in IntelliJ, you will find a lot more useful shortcuts.

--

--