Comments
You can read and write comments in the merge request diff viewer, in the standard code editor (for files that belong to an open merge request), and in the Comments tab of the details panel.
Creating Comments
To add a comment on a line, click the gutter icon in the diff viewer or use the Create Comment for Line action. You can also select a range of lines to create a multi-line comment.
The comment editor has two buttons:
- Submit — sends the comment to GitLab immediately.
- Save Draft — saves the comment locally without submitting. Drafts are only visible to you. You can submit all saved drafts at once using Submit All Drafts in the toolbar.
Reviews
On GitLab 16.4+, you can batch multiple comments into a single review so the merge request author receives one notification instead of many.
Check Start review when creating your first comment. Subsequent comments are added to the review automatically and remain pending (visible only to you on the server) until you finish the review. Click Finish review to publish all pending comments at once. You can also set your review status when finishing (approve, request changes).
On GitLab 17.2+, all comment types can be pending. On GitLab 16.4–17.1, only inline comments support this.
Resolving Discussions
Discussions can be resolved individually. When replying to a discussion, you can check Resolve discussion to resolve it together with your reply. Resolved discussions are collapsed by default in the Comments tab.
Comment Actions
- Reply — respond to an existing discussion.
- Edit / Delete — modify or remove your own comments.
- React — add an emoji reaction (GitLab 16.1+).
- Copy Link — copy the comment URL.
- Jump to Diff — navigate to the corresponding line in the diff viewer.
- Jump to Source — navigate to the corresponding line in the editor.
- Jump to Original Diff — navigate to the diff at the revision where the comment was originally made.
- Minimize — collapse the comment.