Home/Jira formatting reference
Jira text formatting
[pagetitle] and [space:page] links in Jira wiki markup
[pagetitle] and [spacekey:pagetitle] link to Confluence pages by title in Confluence wiki markup. Jira lists the same notation in its help, but in a Jira Cloud text field the bracket text had no page to resolve to and was rendered as an error.
Wiki markup
[pagetitle]
[spacekey:pagetitle]
[alias|https://example.com/page]
Stored as ADF (REST API v3)
The ADF document Jira Cloud stores for [pagetitle]:
{
"type": "doc",
"version": 1,
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "[pagetitle]"
}
]
}
]
}
Examples
Wiki markup (API v2)
[pagetitle]Link a page by title only.
Rendered by Jira (HTML)
<p><span class="error">[pagetitle]</span></p>Back to wiki after the round trip
[pagetitle]Sent to Jira Cloud on .
Wiki markup (API v2)
[spacekey:pagetitle]Link a page in a named space.
Rendered by Jira (HTML)
<p><span class="error">[spacekey:pagetitle]</span></p>Back to wiki after the round trip
[spacekey:pagetitle]Sent to Jira Cloud on .
Wiki markup (API v2)
[Docs|https://example.com/a-b-c-d]Link a page by its full address instead of its title.
Rendered by Jira (HTML)
<p><a href="https://example.com/a-b-c-d" class="external-link" rel="nofollow noreferrer">Docs</a></p>Back to wiki after the round trip
[Docs|https://example.com/a-b-c-d]Sent to Jira Cloud on .
Wiki markup (API v2)
\[not a link\]Keep brackets as text so they are not read as a page link.
Rendered by Jira (HTML)
<p>[not a link]</p>Back to wiki after the round trip
[not a link]Sent to Jira Cloud on .
What changes in conversion
- Both title forms are rendered as an error span in the v2 HTML. The ADF stores the text, brackets included, as plain text with no link mark.
- A wiki read of that stored text returns the same bracketed text, and it shows an error again when rendered.
- A link with a full address and an alias converts without loss, the same as any external link.
Pitfalls
- Bracketed words in a work item description look like a page link and turn red. Escape them with a backslash if they are just text.
- The title forms are Confluence notation. Link a page from Jira with its full address.
Related
- [alias|url] external links
- {anchor} and [#anchor]
- Work item keys and smart links
- Escaping with backslash