Travis lord Logo
Markdown Cheat Sheet

Markdown Cheat Sheet

3 min read

Published on: Sun Oct 13 2024

Common Markdown Syntax Elements

Markdown Cheat Sheet Overview

This comprehensive Markdown guide provides a quick reference for common Markdown syntax elements. While it covers most use cases, refer to the extended syntax guide for more advanced features.

# Heading 1
## Heading 2
### Heading 3
#### Heading 4
##### Heading 5
###### Heading 6

Alternative syntax for Heading 1 and 2:

Heading 1
=========

Heading 2
---------

Renders the same as the # syntax above.

Paragraphs and Line Breaks

This is the first paragraph.

This is the second paragraph.

This line ends with two spaces.  
This is on a new line.

Renders as:

This is the first paragraph.

This is the second paragraph.

This line ends with two spaces.
This is on a new line.

Emphasis

**Bold text** or __Bold text__
*Italic text* or _Italic text_
***Bold and italic text*** or ___Bold and italic text___

Renders as:

Bold text or Bold text Italic text or Italic text Bold and italic text or Bold and italic text

Blockquotes

> This is a blockquote.
> It can span multiple lines.
>
> Even multiple paragraphs.

Renders as:

This is a blockquote. It can span multiple lines.

Even multiple paragraphs.

Lists

Ordered Lists

1. First item
2. Second item
3. Third item

Renders as:

  1. First item

  2. Second item

  3. Third item

Unordered Lists

- First item
- Second item
- Third item

* First item
* Second item
* Third item

+ First item
+ Second item
+ Third item

All render as:

  • First item

  • Second item

  • Third item

Nested Lists

1. First item
   - Nested item
   - Nested item
2. Second item

Renders as:

  1. First item

    • Nested item

    • Nested item

  2. Second item

Code

Inline Code

Use the `print()` function in Python.

Renders as:

Use the print() function in Python.

Code Blocks

python def hello_world(): print("Hello, World!")

Renders as:

def hello_world():
    print("Hello, World!")

Horizontal Rules

***

---

___

All render as:


[Visit Travis Lord](https://travislord.xyz/)
[Visit Travis Lord](https://travislord.xyz/ "Travis Lord's Homepage")

Render as:

Visit Travis Lord Visit Travis Lord

[Travis Lord][1] is a software engineer and tech enthusiast.

[1]: https://travislord.xyz/ "Travis Lord's Homepage"

Renders as:

Travis Lord is a software engineer and tech enthusiast.

Images

![Travis Lord Logo](https://travislord.xyz/logo "Travis Lord Logo")

Renders as:

Travis Lord Logo

Escaping Characters

\*This text is surrounded by asterisks, but not italic\*

Renders as:

This text is surrounded by asterisks, but not italic

Tables (Extended Syntax)

| Header 1 | Header 2 |
| -------- | -------- |
| Cell 1   | Cell 2   |
| Cell 3   | Cell 4   |

Renders as:

Header 1Header 2
Cell 1Cell 2
Cell 3Cell 4

Task Lists (Extended Syntax)

- [x] Completed task
- [ ] Incomplete task

Renders as:

  • [x] Completed task

  • [ ] Incomplete task

Footnotes (Extended Syntax)

Here's a sentence with a footnote.[^1]

[^1]: This is the footnote content.

Renders as:

Here's a sentence with a footnote.[^1]

[^1]: This is the footnote content.

Best Practices

  1. Always include a space after the # for headings.

  2. Use asterisks for mid-word emphasis for better compatibility.

  3. Choose one symbol for unordered lists and use it consistently.

  4. Add blank lines before and after horizontal rules.

  5. Check your specific Markdown processor for support of extended syntax features.

This cheat sheet covers the most common Markdown syntax elements, showing examples first for quick reference and understanding.

Before you go please consider supporting by giving a Hart, Share, or Follow!

Share On Social: