--- title: GitLab Flavored Markdown Official Specification version: alpha ... --- title: GitLab Flavored Markdown (GLFM) Spec version: alpha ... # Introduction GitLab Flavored Markdown (GLFM) extends the [CommonMark specification](https://spec.commonmark.org/current/) and is considered a strict superset of CommonMark. It also incorporates the extensions defined by the [GitHub Flavored Markdown specification](https://github.github.com/gfm/). This specification will define the various official extensions that comprise GLFM. These extensions are GitLab independent - they do not require a GitLab server for parsing or interaction. The intent is to provide a specification that can be implemented in standard markdown editors. This includes many of the features listed in [user-facing documentation for GitLab Flavored Markdown](https://docs.gitlab.com/ee/user/markdown.html). The CommonMark and GitHub specifications will not be duplicated here. NOTE: The example numbering in this document does not start at "1", because this official specification only contains a subset of all the examples which are supported by GitLab Flavored Markdown. See [`snapshot_spec.html`](https://gitlab.com/gitlab-org/gitlab/-/blob/master/glfm_specification/output_example_snapshots/snapshot_spec.html) for a complete list of all examples, which are a superset of examples from: - CommonMark - GitHub Flavored Markdown - GitLab Flavored Markdown Official Specification (the same ones from this specifiation) - GitLab Flavored Markdown Internal Extensions. # GitLab Official Specification Markdown Note: This specification is a work in progress. Only some of the official GLFM extensions are defined. We will continue to add any additional ones found in the [user-facing documentation for GitLab Flavored Markdown](https://docs.gitlab.com/ee/user/markdown.html). There is currently only this single top-level heading, but the examples may be split into multiple top-level headings in the future. ## Task list items See [Task lists](https://docs.gitlab.com/ee/user/markdown.html#task-lists) in the GitLab Flavored Markdown documentation. Task list items (checkboxes) are defined as a GitHub Flavored Markdown extension in a section above. GitLab extends the behavior of task list items to support additional features. Some of these features are in-progress, and should not yet be considered part of the official GitLab Flavored Markdown specification. Some of the behavior of task list items is implemented as client-side JavaScript/CSS. The following are some basic examples; more examples may be added in the future. Incomplete task: ```````````````````````````````` example gitlab - [ ] incomplete .
inapplicable
text in loose list
title: YAML front matter
````````````````````````````````
TOML front matter:
```````````````````````````````` example gitlab
+++
title: TOML front matter
+++
.
title: TOML front matter
````````````````````````````````
JSON front matter:
```````````````````````````````` example gitlab
;;;
{
"title": "JSON front matter"
}
;;;
.
{
"title": "JSON front matter"
}
````````````````````````````````
Front matter blocks should be inserted at the top of the document:
```````````````````````````````` example gitlab
text
---
title: YAML front matter
---
.
text
[[TOC]]text
text[TOC]
```````````````````````````````` A table of contents can be indented with up to three spaces. ```````````````````````````````` example gitlab [[_TOC_]] # Heading 1 .