GitHub keyboard shortcuts for Mac

57 shortcuts · Updated

These are the default GitHub keyboard shortcuts on a Mac, curated from GitHub's official documentation for github.com in the browser (not GitHub Desktop). Most of them are single letters with no modifier: t opens the file finder, w switches branches, y turns the URL into a permanent link, b opens blame, and . opens the repository in the github.dev editor. Where a shortcut does use a modifier, the Mac version uses Command or Option in place of Ctrl or Alt, and pressing ? on any page shows the keys that page supports.

57 shortcuts

Getting around9

ShortcutAction
?Show the keyboard shortcuts for the current page
/Focus the search bar (S works too)
G, then NGo to your notifications
G, then CGo to the repository's Code tab
G, then IGo to the Issues tab
G, then PGo to the Pull requests tab
G, then AGo to the Actions tab
G, then GGo to the Discussions tab
G, then WGo to the Wiki tab

Browsing code11

ShortcutAction
TOpen the file finder
WSwitch to another branch or tag
YExpand the URL to its permanent (canonical) form
BOpen blame view
LJump to a line in the file
.Open the repository or pull request in github.dev, same tab
>Open the repository or pull request in github.dev, new tab
EOpen the current file in the Edit file tab
Shift JHighlight the line the cursor is on
Shift Option COpen the line menu for the selected line
Command ReturnHighlight every occurrence of the symbol under the cursor

Writing comments14

ShortcutAction
Command BBold
Command IItalic
Command EInline code
Command KInsert a link
Command VPaste a URL over selected text to make it a link
Command Shift VPaste an HTML link as plain text
Command Shift 7Numbered list
Command Shift 8Bulleted list
Command Shift .Quote
Command GInsert a suggestion in a review comment
RQuote the selected text in your reply
Control ., then Control 1Insert saved reply 1 (any number works)
Command Shift PToggle between Write and Preview
Command ReturnSubmit the comment

Issues & pull requests11

ShortcutAction
CCreate an issue (from the issue list)
Command /Focus the issues or pull requests search bar
UFilter the list by author
OOpen the selected issue (Return works too)
QRequest a reviewer
ASet an assignee (or filter by assignee on a list)
LApply a label (or filter by label on a list)
MSet a milestone (or filter by milestone on a list)
XLink an issue or pull request from the same repository
Option Shift CCreate a new sub-issue
Option Shift PEdit the parent issue

Reviewing changes5

ShortcutAction
TJump to the Filter changed files field
COpen the Commits menu to pick which commits the diff shows
Command Shift ReturnSubmit a review comment
Click, then Shift ClickComment on several lines: click one line number, then Shift-click another
Option ClickExpand or collapse all outdated or resolved comments

Actions & notifications7

ShortcutAction
G, then FGo to the workflow file
TToggle timestamps in the logs
FToggle full-screen logs
EMark a notification as done
Shift UMark as unread
Shift IMark as read
Shift MUnsubscribe

Curated from the official GitHub Docs - Keyboard shortcuts. Defaults only - shortcuts you've remapped will differ.

Frequently asked questions

How do I see all GitHub keyboard shortcuts?

Press ? on any GitHub page. It opens a dialog listing the shortcuts available on that page, so the list changes between a repository, a pull request and your notifications.

Can I turn off GitHub's single-letter shortcuts?

Yes. In your GitHub accessibility settings you can disable character key shortcuts (the single letters like t, w and g n) while keeping the shortcuts that use modifier keys, such as ⌘B for bold.

What does pressing the period key do on GitHub?

. opens the repository or pull request in the github.dev editor (VS Code for the Web) in the same browser tab, and > opens it in a new tab. You must be signed in to use the editor.

Does GitHub have a command palette?

Yes, but it is off by default; turn it on in feature preview. On a Mac, ⌘K opens it in search mode and ⌘⇧K in command mode. While editing Markdown text, open it with ⌘⌥K instead. You can change these keys in the Accessibility section of your settings.

Templates for GitHub

Ready-made Super Shortcuts commands for GitHub, each with its steps spelled out before you install it.

Mac keyboard guides

Shortcuts for other apps

Your download is starting.

  1. 1
    Open the file and drag Super Shortcuts to Applications.
  2. 2
    Launch it and click Open if macOS asks.
  3. 3
    Turn on Accessibility when it asks. That's how it presses keys and clicks menus for you.

Didn't start? Download again