Home/Jira formatting reference
Jira text formatting
Numbered lists in Jira: wiki markup, Markdown and ADF
A numbered list in wiki markup uses # at the start of each line, and ##, ### and so on for deeper levels. Jira Cloud stores it as an ADF orderedList with an order attribute that wiki cannot express.
Wiki markup
# item
## deeper item
Markdown shortcuts in the editor
Per the Atlassian documentation, not tested.
| Type | What happens |
|---|---|
1. text | Starts an ordered list in the editor, per the Atlassian documentation. Use Tab to indent and Shift + Tab to outdent. |
2) text | Also starts an ordered list in the editor, per the Atlassian documentation. |
Stored as ADF (REST API v3)
The ADF document Jira Cloud stores for # a
# numbered
# list:
{
"type": "doc",
"version": 1,
"content": [
{
"type": "orderedList",
"attrs": {
"order": 1
},
"content": [
{
"type": "listItem",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "a"
}
]
}
]
},
{
"type": "listItem",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "numbered"
}
]
}
]
},
{
"type": "listItem",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "list"
}
]
}
]
}
]
}
]
}
Examples
Wiki markup (API v2)
# a
# numbered
# listWrite a simple numbered list. Jira numbers the items itself.
Rendered by Jira (HTML)
<ol>
<li>a</li>
<li>numbered</li>
<li>list</li>
</ol>
Back to wiki after the round trip
# a
# numbered
# listSent to Jira Cloud on .
Wiki markup (API v2)
# one
## two
### three
#### fourNest four levels deep with one more # per level.
Rendered by Jira (HTML)
<ol>
<li>one
<ol>
<li>two
<ol>
<li>three
<ol>
<li>four</li>
</ol>
</li>
</ol>
</li>
</ol>
</li>
</ol>
Back to wiki after the round trip
# one
## two
### three
#### fourSent to Jira Cloud on .
ADF (API v3)
{"content": [{"attrs": {"order": 3}, "content": [{"content": [{"content": [{"text": "starts at three", "type": "text"}], "type": "paragraph"}], "type": "listItem"}], "type": "orderedList"}], "type": "doc", "version": 1}Start a list at 3 from the ADF side, for example to continue a list that was split by other content.
Rendered by Jira (HTML)
<ol>
<li>starts at three</li>
</ol>
Back to wiki after the round trip
# starts at threeSent to Jira Cloud on .
Wiki markup (API v2)
1. markdown one
2. markdown twoPaste a Markdown numbered list through the API.
Rendered by Jira (HTML)
<p>1. markdown one<br/>
2. markdown two</p>Back to wiki after the round trip
1. markdown one
2. markdown twoSent to Jira Cloud on .
What changes in conversion
- A # list and its nested levels survive wiki, then ADF, then wiki without changes.
- The ADF order attribute (start number) has no wiki form. A list stored with order 3 is written back through v2 as a plain # item and renders from 1.
- Lines such as 1. text sent through the API are not converted. Jira stores them as paragraph text with a hardBreak between the lines. The conversion only happens when someone types in the editor, per the documentation.
Pitfalls
- A Markdown-style
1.line sent as wiki text is not a list. Use#in wiki, or type the Markdown in the editor. - Wiki markup cannot set the start number. Only ADF carries it, and v2 drops it.
- A
#at the start of a line is a list item, not a heading, in wiki markup. Headings useh1.toh6..