GitLab keyboard shortcuts

  • Tier: Free, Premium, Ultimate
  • Offering: GitLab.com, GitLab Self-Managed, GitLab Dedicated

GitLab has several keyboard shortcuts you can use to access its different features.

To display a window in GitLab that lists its keyboard shortcuts, use one of the following methods:

  • Press ?.
  • In the lower-left corner of the application, select Help and then Keyboard shortcuts.

Although global shortcuts work from any area of GitLab, you must be in specific pages for the other shortcuts to be available, as explained in each section.

Global shortcuts

These shortcuts are available in most areas of GitLab:

Keyboard shortcutDescription
?Show or hide the shortcut reference sheet.
Shift + pGo to your Projects page.
Shift + gGo to your Groups page.
Shift + aGo to your Activity page.
Shift + lGo to your Milestones page.
Shift + sGo to your Snippets page.
s / /Put cursor in the search bar.
Shift + iGo to your Issues page.
Shift + mGo to your Merge requests page.
Shift + rGo to your Review requests page.
Shift + tGo to your To-Do List page.
p, then bShow or hide the Performance Bar.
EscapeHide tooltips or popovers.
g, then xToggle between GitLab and GitLab Next (GitLab SaaS only).
.Open the Web IDE.

Additionally, the following shortcuts are available when editing text in text fields (for example, comments, replies, issue descriptions, and merge request descriptions):

macOS shortcutWindows shortcutDescription
Edit your last comment. You must be in a blank text field below a thread, and you must already have at least one comment in the thread.
Command + Shift + pControl + Shift + pToggle Markdown preview when editing text in a text field that has Write and Preview tabs at the top.
Command + bControl + bBold the selected text (surround it with **).
Command + iControl + iItalicize the selected text (surround it with _).
Command + Shift + xControl + Shift + xStrike through the selected text (surround it with ~~).
Command + kControl + kAdd a link (surround the selected text with []()).
Command + ]Control + ]Indent text. Introduced in GitLab 15.3.
Command + [Control + [Outdent text. Introduced in GitLab 15.3.
Command + EnterControl + EnterSubmit or save changes

The shortcuts for editing in text fields are always enabled, even if other keyboard shortcuts are disabled.

Project

These shortcuts are available from any page in a project. You must type them relatively quickly to work, and they take you to another page in the project.

Keyboard shortcutDescription
g + oGo to the Project overview page.
g + vGo to the project Activity page (Manage > Activity).
g + rGo to the project Releases page (Deploy > Releases).
g + fGo to the project files (Code > Repository).
tOpen the project file search dialog. (Code > Repository, select Find Files).
g + cGo to the project Commits page (Code > Commits).
g + nGo to the Repository graph page (Code > Repository graph).
g + dGo to the charts in the Repository analytics page (Analyze > Repository analytics).
g + iGo to the project Issues page (Plan > Issues).
iGo to the New Issue page (Plan > Issues, select New issue ).
g + bGo to the project Issue boards page (Plan > Issue boards).
g + mGo to the project Merge requests page (Code > Merge requests).
g + pGo to the CI/CD Pipelines page (Build > Pipelines).
g + jGo to the CI/CD Jobs page (Build > Jobs).
g + eGo to the project Environments page (Operate > Environments).
g + kGo to the project Kubernetes clusters integration page (Operate > Kubernetes clusters). You must have at least maintainer permissions to access this page.
g + sGo to the project Snippets page (Code > Snippets).
g + wGo to the project wiki (Plan > Wiki), if enabled.
.Open the Web IDE.

Issues

These shortcuts are available when viewing issues:

Keyboard shortcutDescription
eEdit description.
aChange assignee.
mChange milestone.
lChange label.
c + rCopy issue reference.
rStart writing a comment. Pre-selected text is quoted in the comment.
Go to the next design.
Go to the previous design.
EscapeClose the design.

Merge requests

These shortcuts are available when viewing merge requests:

macOS shortcutWindows shortcutDescription
] or jMove to next file.
[ or kMove to previous file.
Command + pControl + pSearch for, and then jump to a file for review.
nMove to next unresolved discussion.
pMove to previous unresolved discussion.
bCopy source branch name.
c + rCopy merge request reference.
rStart writing a comment. Pre-selected text is quoted in the comment.
Shift + Command + EnterShift + Control + EnterPublish your comment immediately.
Command + EnterControl + EnterAdd your comment in a pending state, as part of a review.
cMove to next commit.
xMove to previous commit.
fToggle file browser.

Project files

These shortcuts are available when browsing the files in a project (go to Code > Repository):

Keyboard shortcutDescription
Move selection up (only while searching for files, Code > Repository, then select Find File).
Move selection down (only while searching for files, Code > Repository, then select Find File).
EnterOpen selection (only while searching for files, Code > Repository, then select Find File).
EscapeGo back to the Find File screen (only while searching for files, Code > Repository, then select Find File).
yGo to file permalink (only while viewing a file).
.Open the Web IDE.

Repository graph

These shortcuts are available when viewing the project repository graph page (go to Code > Repository graph):

Keyboard shortcutDescription
or hScroll left.
or lScroll right.
or kScroll up.
or jScroll down.
Shift + or Shift + kScroll to top.
Shift + or Shift + jScroll to bottom.

Incidents

These shortcuts are available when viewing incidents:

Keyboard shortcutDescription
c + rCopy incident reference.

Wiki pages

This shortcut is available when viewing a wiki page:

Keyboard shortcutDescription
eEdit wiki page.

Rich text editor

These shortcuts are available when editing a file with the rich text editor:

macOS shortcutWindows shortcutDescription
Command + cControl + cCopy
Command + xControl + xCut
Command + vControl + vPaste
Command + Shift + vControl + Shift + vPaste without formatting
Command + zControl + zUndo
Command + Shift + vControl + Shift + vRedo
Shift + EnterShift + EnterAdd a line break

Formatting

macOS shortcutWindows/Linux shortcutDescription
Command + bControl + bBold
Command + iControl + iItalic
Command + Shift + xControl + Shift + xStrikethrough
Command + kControl + kInsert a link
Command + Option + 0Control + Alt + 0Apply normal text style
Command + Option + 1Control + Alt + 1Apply heading style 1
Command + Option + 2Control + Alt + 2Apply heading style 2
Command + Option + 3Control + Alt + 3Apply heading style 3
Command + Option + 4Control + Alt + 4Apply heading style 4
Command + Option + 5Control + Alt + 5Apply heading style 5
Command + Option + 6Control + Alt + 6Apply heading style 6
Command + Shift + 7Control + Shift + 7Ordered list
Command + Shift + 8Control + Shift + 8Unordered list
Command + Shift + 9Control + Shift + 9Task list
Command + Option + cControl + Alt + cCode block
Command + Shift + hControl + Shift + hHighlight
Command + ,Control + ,Subscript
Command + .Control + .Superscript
TabTabIndent list
Shift + TabShift + TabOutdent list

Text selection

macOS shortcutWindows shortcutDescription
Command + aControl + aSelect all
Shift + Shift + Extend selection one character to left
Shift + Shift + Extend selection one character to right
Shift + Shift + Extend selection one line up
Shift + Shift + Extend selection one line down
Command + Shift + Control + Shift + Extend selection to the beginning of the document
Command + Shift + Control + Shift + Extend selection to the end of the document

Epics

  • Tier: Premium, Ultimate
  • Offering: GitLab.com, GitLab Self-Managed, GitLab Dedicated

These shortcuts are available when viewing epics:

Keyboard shortcutDescription
eEdit description.
lChange label.
c + rCopy epic reference.

Disable keyboard shortcuts

History

To disable keyboard shortcuts:

  1. On the left sidebar, select your avatar.
  2. Select Preferences.
  3. In the Behavior section, clear the Enable keyboard shortcuts checkbox.
  4. Select Save changes.

Enable keyboard shortcuts

History

To enable keyboard shortcuts:

  1. On the left sidebar, select your avatar.
  2. Select Preferences.
  3. In the Behavior section, select the Enable keyboard shortcuts checkbox.
  4. Select Save changes.

Troubleshooting

Linux shortcuts

Linux users may encounter GitLab keyboard shortcuts that are overridden by their operating system, or their browser.