How do I format a {} as inline-code?

When writing or commenting on a ticket or documentation in either JIRA or Confluence, I often highlight variable names or values with the inline-code markers (which is two open curly-braces, text, two closed curly-braces).


Now something that comes up regularly is the construct {}, which I just had to make italic instead of inline-code, because I don't understand how to escape it properly to make it show up.

I have tried a variety of things, including backslashes and spaces at various places. In the following I'll use a markdown-like syntax to show which part is highlighted. Things in backticks `$foo` are turning up inside the highlighted area in the rendered JIRA output.

{{{}}}     # {`}`
{{ {} }}   # {{ {} }}
{{\{\}}}   # {`}`
{{\{}}}    # {`}`
{{{\}}}    # {{    (that one is my favourite)
           # {\}}
           # }
{{{{}}}}   # {`}`
{{{}}{{}}} # `}{`

This is highly weird. And very frustrating. This thing is relevant to JavaScript, JSON data and various other programming languages.

How do I make that thing highlighted correctly?

5 answers

Yes. Or {code}. But I want to be able to say something like "By default, this method will return {{]}}", but with an empty object, not an empty array.

If you don't need it inline, you can use {noformat}, but you probably know this.

My solution was to separate the }}} with soft hyphens (


That way, You can do something like this:

{{{ \}­}} # returns { }, code formatted. There is a soft hyphen character between the first and second }.

I'm guessing this comes much too late for Julien, but hopefully any future people seeing this will find this useful.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Wednesday in Jira

Make your Atlassian Cloud products more secure: our NEW admin security guide

Hey admins! I’m Dave, Principal Product Manager here at Atlassian working on our cloud platform and security products. Cloud security is a moving target. As you adopt more products, employees consta...

442 views 0 9
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you