Underline Text in Markdown
Markdown has no syntax for underline, so underlined text is written with HTML: <ins>text</ins> or <u>text</u>. This guide shows which tag to use where, and the shortcuts some apps add.
Quick answer
How do you underline text in Markdown?
Markdown has no underline syntax. Where HTML is allowed, wrap the text in <ins> or <u>: <ins>underlined</ins>. Use <ins> on GitHub, which removes <u>. In Discord, two underscores underline text instead: __text__.
<ins>This text is underlined</ins>
<u>This text is underlined too</u>Result
This text is underlined
This text is underlined too
Ways to underline in Markdown
The HTML tags work in any app that keeps inline HTML. A few apps have their own syntax, shown here with the app it belongs to.
The <ins> tag
Marks inserted text and is underlined by default. It also works on GitHub, which removes <u>.
The API now accepts <ins>bearer tokens</ins>.Result
The API now accepts bearer tokens.
The <u> tag
Underlines text without extra meaning. Works in editors that keep HTML, such as Obsidian, Typora and VS Code.
Read the <u>installation notes</u> before upgrading.Result
Read the installation notes before upgrading.
With bold or italic
Markdown inside the tag still works, and the tag can sit inside bold or italic text.
<ins>**Important:**</ins> restart after upgrading.
**Bold and <ins>underlined</ins>**Result
Important: restart after upgrading.
Bold and underlined
Headings and table cells
The tags work inside headings, list items and table cells too.
## <ins>Release notes</ins>
| Field | Status |
| --- | --- |
| Email | <ins>required</ins> |Result
| Field | Status |
|---|---|
| required |
Discord: two underscores
In Discord, two underscores underline text and combine with asterisks. Discord shows HTML tags as typed.
__underlined__
***__bold, italic and underlined__***Discord only. Other Markdown apps display this differently, so there is no preview.
Pandoc: the underline class
Pandoc underlines a bracketed span with the .underline class and keeps the underline in Word and PDF output.
[underlined text]{.underline}Pandoc only. Other Markdown apps display this differently, so there is no preview.
Underline in popular apps
Support depends on whether the app keeps HTML and which tags it allows.
| App | Support | Notes |
|---|---|---|
| GitHub | Differs | <ins> is underlined. <u> and style attributes are removed. |
| Discord | Differs | __text__ underlines. HTML tags are shown as typed. |
| Slack | Not supported | No typed syntax; underline with the toolbar or ⌘U / Ctrl+U. |
| Obsidian | Supported | <u> and <ins> both work. |
| Notion | Not supported | No typed syntax; underline with Ctrl+U or ⌘U. |
| Typora / VS Code | Supported | <u> and <ins> work in the editor and preview. |
Questions and answers
Does Markdown have underline syntax?
<ins> or <u> where HTML is allowed.How do I underline text on GitHub?
<ins>text</ins>. GitHub removes the <u> tag and style attributes, which leaves plain text.What is the difference between <u> and <ins>?
<u> and <ins>?<ins> marks text added to a document and is underlined by default. <u> marks text that should look different without extra meaning, such as a misspelled word. Both look the same.How do I underline text in Discord?
__text__. Add asterisks for more, as in __**bold and underlined**__.Why does my <u> tag show as plain text?
<u> tag show as plain text?<u> but keeps <ins>; Discord, Slack and Reddit show tags as typed or remove them. Use the app's own syntax, such as __text__ in Discord.Can I underline a heading or a table cell?
## <ins>Title</ins> or | <ins>cell</ins> |.