Keyboard Shortcuts5 min read

Xcode Keyboard Shortcuts to Speed Up macOS and iOS Development

Navigate storyboards, refactor Swift, and ship builds faster with the Xcode shortcuts every Apple developer should master.

Xcode packs dozens of commands into menus. These shortcuts help you iterate, test, and ship faster.

Workspace layout

ActionShortcut
Show/Hide Navigator⌘ + 0
Show/Hide Inspectors⌘ + ⌥ + 0
Show/Hide Debug Area⌘ + ⇧ + Y
Focus Editor⌘ + ⇧ + Enter
Open in Assistant Editor⌥ + Click on file
Show Standard Editor⌘ + Enter

Navigation

ActionShortcut
Quick Open⇧ + ⌘ + O
Jump to definition⌘ + ⌃ + J
Switch between .h/.m or related files⌘ + ⌃ + ↑
Reveal in Project Navigator⌘ + ⇧ + J
Navigate Back⌃ + ⌘ + ←
Navigate Forward⌃ + ⌘ + →
Jump Bar⌃ + 1 through ⌃ + 6
Navigator Panes⌘ + 1 through ⌘ + 7

Find and replace

ActionShortcut
Find in File⌘ + F
Find and Replace in File⌘ + ⌥ + F
Find in Project⌘ + ⇧ + F
Find and Replace in Project⌘ + ⌥ + ⇧ + F
Find Next⌘ + G
Find Previous⌘ + ⇧ + G

Editing and refactoring

ActionShortcut
Comment or uncomment line⌘ + /
Re-indent selection⌃ + I
Rename symbol⌘ + ⌃ + E
Edit All in Scope⌃ + ⌘ + E
Multi-cursor selection⌥ + Drag or ⌥ + ⌘ + Click
Show Quick Help⌥ + Click or ⌃ + ⌘ + ?
Fold code block⌥ + ⌘ + ←
Unfold code block⌥ + ⌘ + →

Build, run, and test

ActionShortcut
Run⌘ + R
Stop⌘ + .
Build⌘ + B
Clean build folder⇧ + ⌘ + K
Run Tests⌘ + U
Rerun last test⌃ + ⌘ + U
Test current method⌃ + ⌥ + ⌘ + U

File management

ActionShortcut
New File⌘ + N
New Tab⌘ + T
Close Tab⌘ + W
Close Other Tabs⌘ + ⌥ + W
Save All⌘ + ⌥ + S
Next/Previous Tab⌘ + ⇧ + ] / ⌘ + ⇧ + [

Debugger

ActionShortcut
Toggle breakpoint⌘ + \
Enable/disable all breakpoints⌘ + Y
Step overF6
Step intoF7
Step out⇧ + F7
Continue⌃ + ⌘ + Y

Interface Builder

ActionShortcut
Align objects⌃ + =
Add constraints⌃ + ⇧ + =
Update frames⌃ + ⌥ + =
Preview canvas⌥ + ⌘ + Enter
Reload SwiftUI canvas⌥ + ⌘ + P

Customize shortcuts

Open Xcode → Settings → Key Bindings to view and customize all bindings.

Show your shortcuts on screen

Creating tutorials or presenting live? KeyScreen displays your keystrokes beautifully on screen so viewers always know what you pressed.

Discover more posts

Postman Keyboard Shortcuts: The Complete Guide for API Testing
December 25, 20256 min read
Keyboard Shortcuts

Postman Keyboard Shortcuts: The Complete Guide for API TestingPostman Keyboard Shortcuts: The Complete Guide for API Testing

Master Postman with this comprehensive keyboard shortcuts guide. From building requests to managing collections, become a Postman power user.

Sketch Keyboard Shortcuts: The Complete Guide for Mac
December 25, 20257 min read
Keyboard Shortcuts

Sketch Keyboard Shortcuts: The Complete Guide for MacSketch Keyboard Shortcuts: The Complete Guide for Mac

Master Sketch with this comprehensive keyboard shortcuts guide for Mac. From essential tools to advanced layer operations, become a Sketch power user.

CleanShot X Keyboard Shortcuts: The Complete Guide for Mac
December 25, 20256 min read
Keyboard Shortcuts

CleanShot X Keyboard Shortcuts: The Complete Guide for MacCleanShot X Keyboard Shortcuts: The Complete Guide for Mac

Master CleanShot X with this complete keyboard shortcuts guide for Mac. From capturing screenshots to annotating and recording your screen, become a screenshot pro.

Simple no-tricks pricing
Pay once, use forever

You can download the app from the Mac App Store today.