Android Studio Keyboard Shortcuts
Android Studio is built on the same JetBrains IntelliJ Platform underlying IntelliJ IDEA, PyCharm, and WebStorm, so a huge portion of its core editing and navigation shortcuts are shared across that entire family of IDEs — a developer fluent in one IntelliJ-based tool transfers most of that muscle memory directly. What's genuinely Android-specific is the Layout Editor for visually building XML-based UI layouts and the Logcat/emulator toolchain for running and debugging against a virtual or physical Android device. Windows and Linux rely mostly on Ctrl with a scattering of Alt combos, and Mac swaps in Cmd for the bulk of those, though a few IntelliJ-platform conventions — Shift+Shift for Search Everywhere among them — stay identical no matter which of the three operating systems you're on. Beyond the shared IntelliJ foundation, Android Studio's own release cadence means several shortcuts have shifted meaning over the years as Google reworked the emulator toolchain and the Layout Editor's constraint system, so developers returning to the IDE after a long break sometimes find a once-familiar binding now opens a different panel entirely. A newcomer's most efficient path in is usually to learn navigation-search shortcuts first, since jumping to a class, file, or symbol by name replaces an enormous amount of manual folder-tree clicking, then layer in build-run-debug shortcuts once a project is actually running on an emulator or device, and only later invest time in the Layout Editor and refactoring shortcuts that pay off more gradually as a codebase grows.
Navigation Search
| Action | Windows | Mac | Description |
|---|---|---|---|
| Search Everywhere | Shift, Shift (double-tap) | Shift, Shift | Double-tapping Shift opens a universal search box covering files, classes, symbols, actions, and settings across the entire project, the single fastest general-purpose navigation entry point inherited from the IntelliJ platform. |
| Go to Class | Ctrl+N | Cmd+O | Opens a search box that only matches against class names, trading Search Everywhere's broad net for a shorter, more predictable results list on the frequent occasions when a class is specifically what you're hunting for. |
| Go to File | Ctrl+Shift+N | Cmd+Shift+O | Opens a fuzzy-search box scoped to file names across the project, including non-code files like XML layouts and Gradle configuration files that Go to Class wouldn't surface. |
| Find Usages | Alt+F7 | Option+F7 | Opens a Find Usages results panel listing every call site across the module (or the whole project if scoped that way) that references the symbol under the cursor — the safety check to run before deleting or changing the signature of anything another class might depend on. |
| Go to Symbol | Ctrl+Alt+Shift+N | Cmd+Option+O | Narrows the fuzzy search to symbols only — methods, fields, and other named members below class level — the right tool when you can recall a method or field name precisely but have no idea which class or file actually holds it. |
| Show Recent Files | Ctrl+E | Cmd+E | Surfaces a chronological list of recently touched files, which beats typing a name into any search box when you just need to hop back to whatever you were editing a minute or two ago. |
| Navigate back to previous location | Ctrl+Alt+Left | Cmd+Option+Left | Steps back one entry in your navigation history, returning the cursor to wherever it sat before a Go to Class, Find Usages, or similar jump carried you off elsewhere. |
Editing Refactoring
| Action | Windows | Mac | Description |
|---|---|---|---|
| Rename (Refactor) | Shift+F6 | Shift+F6 | Renames the symbol under the cursor everywhere it's referenced throughout the project, not just the current file, inherited directly from IntelliJ's refactoring engine. |
| Reformat Code | Ctrl+Alt+L | Cmd+Option+L | Automatically reformats the current file's indentation, spacing, and line breaks according to the project's configured code style settings. |
| Optimize Imports | Ctrl+Alt+O | Ctrl+Option+O | Removes unused import statements and organizes the remaining ones according to the project's import ordering rules, keeping a file's imports section clean without manual review. |
| Generate code (constructors, getters, overrides) | Alt+Insert | Cmd+N | Opens a menu for auto-generating boilerplate code like constructors, getter/setter methods, equals/hashCode implementations, or overriding a superclass method, saving manual typing of repetitive, mechanically-derivable code. |
| Extract Method | Ctrl+Alt+M | Cmd+Option+M | Carves the highlighted lines out into a brand-new method, working out which parameters it needs from the variables the selection actually references. Kotlin gets an extra bit of intelligence here that Java doesn't: if the selected block's last line is an expression, Android Studio infers a sensible return type from it directly, something Java extraction in the same IDE can't do since Java requires an explicit return statement to know a value is even being returned. |
| Inline variable or method | Ctrl+Alt+N | Cmd+Option+N | Undoes an Extract by replacing every place a variable or method gets called with its actual value or body inlined directly, useful for stripping out a layer of indirection that's stopped pulling its weight. |
Build Run Debug
| Action | Windows | Mac | Description |
|---|---|---|---|
| Run app | Shift+F10 | Ctrl+R | Builds the current run configuration and launches it on the selected emulator or connected physical device, the primary build-and-test loop during active development. |
| Debug app | Shift+F9 | Ctrl+D | Builds the app and launches it on the emulator or device with the JDWP debugger already attached, so any breakpoint you've set fires from the very first line executed instead of requiring a separate attach-to-process step after a plain Run. |
| Toggle line breakpoint | Ctrl+F8 | Cmd+F8 | Sets or removes a breakpoint on the current line. In Kotlin files the debugger sometimes needs to stop on an inline lambda body rather than the line you clicked, since Kotlin's compiled bytecode can spread a single source line across several actual execution points — Android Studio usually resolves this correctly, but if a breakpoint seems to get skipped on a one-line lambda, placing it explicitly inside the lambda body rather than on the enclosing call tends to fix it. |
| Open Logcat panel | Alt+6 | Cmd+6 | Opens the Logcat panel showing real-time system and app log output from the running emulator or device, essential for diagnosing crashes and tracing runtime behavior beyond what the debugger's breakpoints alone reveal. |
| Stop running app | Ctrl+F2 | Cmd+F2 | Forcibly terminates the currently running app process on the target emulator or device, useful for cleanly restarting a test session rather than launching a second instance on top of one that's already running and potentially conflicting. |
| Apply Changes (hot-swap code/resources) | Ctrl+F10 | Cmd+F10 | Pushes certain code and resource changes to the already-running app without a full restart, considerably faster than a complete Run cycle for small, targeted iterations during active UI or logic tweaking. |
| Step Over (debugger) | F8 | F8 | Advances execution past the current line and lands on the next one at the same call depth, skipping over the internals of any method it happens to call. In a Compose UI debug session this is the stepping command you reach for most, since stepping into every recomposition-related internal call the framework makes would otherwise bury you dozens of frames deep in Compose runtime code for a single tap on one button. |
Layout Editor
| Action | Windows | Mac | Description |
|---|---|---|---|
| Switch to Design view (Layout Editor) | Click Design tab, no default key | Same | Switches an open XML layout file from Code view (raw XML) to Design view, showing a visual drag-and-drop canvas representation of the layout instead of markup, with no default keyboard shortcut bound to the switch itself. |
| Show Component Tree | Part of Layout Editor panel, no default key | Same | Displays the hierarchical tree of views within the current layout in the Layout Editor's side panel, useful for understanding and navigating a complex nested layout's structure at a glance rather than only seeing the flat visual canvas. |
Frequently Asked Questions
Why does double-tapping Shift sometimes not open Search Everywhere?
Search Everywhere's double-Shift trigger requires two quick, distinct taps of the Shift key alone, without any other key held simultaneously — if you're holding Shift as part of another combination (like Shift-selecting text) immediately beforehand, or another IDE plugin has intercepted the Shift-Shift binding, it may not trigger. Reassigning or checking for shortcut conflicts under Settings > Keymap resolves persistent issues.
What's the real difference between Run (Shift+F10) and Debug (Shift+F9)?
Run just launches the app with no debugger attached, which starts a beat faster and is fine when you only need to see it working. Debug attaches the debugger before the process even starts, so anything you've already set a breakpoint on will actually pause — the only way to catch a problem that happens during app initialization, before Run would have given the debugger a chance to attach at all.
Why do some IntelliJ-platform shortcuts (like Cmd+O for Go to Class on Mac) differ from Ctrl+N on Windows in a way that feels inconsistent?
This particular case is actually a genuine platform-convention difference rather than an error — Mac's Cmd+O by convention means 'Open,' which the IntelliJ platform maps specifically to opening/navigating to a class on Mac, while on Windows and Linux the same conceptual action uses Ctrl+N instead, following a different but internally consistent set of platform mnemonics JetBrains chose per OS rather than a uniform cross-platform key mapping.
Why does Go to File sometimes fail to find an XML layout I know exists?
Go to File indexes based on Android Studio's project model, which can occasionally lag behind the actual file system right after creating a new file outside the IDE (via a terminal, or a tool like Android Asset Studio) or after switching Git branches. Triggering File > Sync Project with Gradle Files, or simply waiting for the background indexing spinner in the bottom status bar to finish, resolves most cases where a known-existing file doesn't show up in search yet.
Do Layout Editor changes and hand-edited XML ever conflict with each other?
They shouldn't, since both views read from and write to the same underlying XML file, but rapid switching between Code and Design view while the IDE is still processing a previous edit can occasionally show a stale rendering in Design view until you click back into it or force a rebuild of the preview. If a layout preview looks wrong after a manual XML edit, switching to Code view, making a trivial whitespace change, and switching back usually forces Design view to re-render from the current file state.
Does Android Studio's IntelliJ-shared keymap ever get out of sync with a plain IntelliJ IDEA install?
Google periodically pulls in a newer version of the underlying IntelliJ Platform with each Android Studio release, but not always the very latest one available to standalone IntelliJ IDEA users, so a small number of newer IntelliJ-only shortcuts can lag behind by a release or two in Android Studio specifically. The core navigation, refactoring, and editing bindings covered here have stayed stable for years regardless of this lag.