GitLab Issue Template (Markdown)
Create a GitLab-compatible issue template using Markdown format. Covers file placement in .gitlab/issue_templates/ and GitLab-specific features.
Detailed Explanation
GitLab Issue Template
GitLab uses Markdown-based issue templates stored in a specific directory. Unlike GitHub's YAML issue forms, GitLab templates are editable Markdown documents with front matter.
File Placement
.gitlab/
issue_templates/
Bug Report.md
Feature Request.md
Note: GitLab uses the file name (without .md extension) as the template name in the dropdown. Spaces in file names are supported.
Template Structure
<!-- Template: Bug Report -->
## Summary
<!-- Provide a brief summary of the issue -->
## Steps to Reproduce
1.
2.
3.
## Expected Behavior
<!-- What should happen? -->
## Actual Behavior
<!-- What actually happens? -->
## Environment
- **GitLab Version**: <!-- e.g., 16.0 -->
- **Browser**: <!-- e.g., Chrome 120 -->
- **OS**: <!-- e.g., macOS 14 -->
## Severity
<!-- /label ~"severity::low" ~"severity::medium" ~"severity::high" ~"severity::critical" -->
/label ~bug
/milestone %"Next Release"
GitLab Quick Actions
GitLab supports quick actions (slash commands) at the bottom of templates:
| Quick Action | Purpose |
|---|---|
/label ~bug |
Apply the "bug" label |
/milestone %"v1.0" |
Set the milestone |
/assign @username |
Assign to a user |
/due 2024-12-31 |
Set a due date |
/weight 3 |
Set issue weight |
Differences from GitHub
| Feature | GitHub | GitLab |
|---|---|---|
| Template format | YAML forms + Markdown | Markdown only |
| Form fields | Dropdown, checkbox, input | Free-form Markdown |
| Auto-labels | YAML front matter | Quick actions |
| Directory | .github/ISSUE_TEMPLATE/ |
.gitlab/issue_templates/ |
| Template chooser config | config.yml | Built-in settings |
Default Templates
In GitLab, you can set a default template in Project Settings > General > Default issue template. This pre-fills the issue body when no template is explicitly selected.
Use Case
Teams using GitLab for project management that want to standardize issue reporting with consistent templates, particularly organizations migrating from GitHub or setting up new GitLab projects.