Mastering a tool is important to become a more efficient developer. I'll see some very helpful keyboard shortcuts that can save a little bit of time and quite a bit of frustration. We need shortcuts to be on top. Following are most essential Android Studio shortcuts we need.
Navigation Shortcuts
| Shortcut Description | Android Studio Shortcut |
|---|---|
| Go to class | Ctrl + N |
| Go to file | Ctrl + Shift + N |
| Navigate open tabs | ALT + Left-Arrow; ALT + Right-Arrow |
| Lookup recent files | CTRL + E |
| Go to line | CTRL + G |
| Navigate to last edit location | CTRL + SHIFT + BACKSPACE |
| Go to declaration | CTRL + B |
| Go to implementation | CTRL + ALT + B |
| Go to source | F4 |
| Go to super Class | CTRL + U |
| Show Call hierarchy | Ctrl + Alt + H |
| Search in path/project | CTRL + SHIFT + F |
Programming Shortcuts
| Shortcut Description | Android Studio Shortcut |
|---|---|
| Reformat code | CTRL + ALT + L |
| Optimize imports | CTRL + ALT + O |
| Code Completion | CTRL + SPACE |
| Issue quick fix | ALT + ENTER |
| Surround code block | CTRL + ALT + T |
| Rename and refactor | Shift + F6 |
| Line Comment or Uncomment | CTRL + / |
| Block Comment or Uncomment | CTRL + SHIFT + / |
| Go to previous/next method | ALT + UP/DOWN |
| Show parameters for method | CTRL + P |
| Quick documentation lookup | CTRL + Q |
General Shortcuts
| Shortcut Description | Android Studio Shortcut |
|---|---|
| Delete line | CTRL + Y |
| Safe Delete | Alt + DELETE |
| Close Active Tab | CTRL + F4 |
| Build and run | SHIFT + F10 |
| Build | CTRL + F9 |
| All purpose (Meta)Shortcut | CTRL + SHIFT + A |