Markdown Cheat Sheet for Mac Users — Syntax, Shortcuts & Tips
A complete markdown cheat sheet covering basic and extended syntax, LaTeX math, Mermaid diagrams, and Mac keyboard shortcuts. Bookmarkable quick reference.
Markdown is one of those formats that takes 15 minutes to learn and a lifetime to use well. This cheat sheet covers everything — from the basics you use every day to the advanced syntax for diagrams, math, and footnotes. Bookmark it.
For an interactive version with a copy button on every example, see the Markdown Cheat Sheet quick reference page.
Basic Syntax: The Daily Essentials
Headings
# Heading 1
## Heading 2
### Heading 3
#### Heading 4
Use one # per heading level. Leave a blank line before and after headings. Don't skip levels (don't jump from ## to ####).
Text Formatting
**bold text**
*italic text*
~~strikethrough~~
`inline code`
**bold and _nested italic_**
For bold, use **double asterisks**. For italic, *single asterisk* or _underscore_ both work — but don't mix them in the same document. Strikethrough requires GFM (GitHub Flavored Markdown) — see the section below.
Links and Images
[Link text](https://example.com)
[Link with title](https://example.com "Hover title")


<!-- Reference-style links -->
[link text][ref]
[ref]: https://example.com
Reference-style links keep long URLs out of your prose. Useful in READMEs and documentation where you have many links.
Lists
- Unordered item
- Another item
- Nested item (two spaces indent)
- Another nested
1. First ordered item
2. Second item
3. Third item
- [ ] Task item (unchecked)
- [x] Task item (checked)
For nested lists, indent with two or four spaces. Task lists (the [ ] syntax) are a GFM extension — they render as interactive checkboxes on GitHub and in editors like OpenMark that support GFM.
Blockquotes
> This is a blockquote.
>
> It can span multiple paragraphs.
> Nested:
> > Deeply nested quote
Horizontal Rules
---
***
___
Three hyphens, asterisks, or underscores create a <hr>. The --- version is most conventional.
Extended Syntax (GFM)
GitHub Flavored Markdown (GFM) is the de facto standard for developer markdown. Most tools that say they support markdown actually support GFM.
Tables
| Feature | OpenMark | VS Code |
|------------|----------|----------|
| Native macOS | ✓ | — |
| Mermaid | ✓ | Extension|
| LaTeX math | ✓ | Extension|
| Launch time| Instant | Slow |
Alignment with colons in the separator row:
| Left | Center | Right |
|:-----------|:----------:|----------:|
| aligned | aligned | aligned |
For a deep dive on tables including edge cases, see Markdown Tables: Complete Syntax Guide with Examples.
Fenced Code Blocks
```javascript
function greet(name) {
return `Hello, ${name}!`
}
```
```python
def greet(name):
return f"Hello, {name}!"
```
```bash
npm install && npm run build
```
The language identifier after the opening backticks enables syntax highlighting. Common identifiers: javascript, typescript, python, bash, sql, json, yaml, rust, go, swift.
Footnotes
This claim needs a citation.[^1]
[^1]: The original source, published 2024.
Footnotes are supported in GFM and render as superscript numbers that link to the footnote list at the bottom of the document.
Math Syntax (LaTeX / KaTeX)
Inline math goes between single dollar signs. Display math (centred, larger) between double dollar signs.
Inline: The formula is $E = mc^2$.
Display:
$$
\int_0^\infty e^{-x^2} dx = \frac{\sqrt{\pi}}{2}
$$
Common operators:
| What you want | Syntax |
|---|---|
| Fraction | \frac{numerator}{denominator} |
| Subscript | x_i |
| Superscript | x^2 |
| Square root | \sqrt{x} |
| Sum | \sum_{i=0}^{n} |
| Integral | \int_a^b |
| Greek letters | \alpha, \beta, \gamma, \pi |
| Vectors | \vec{v} |
OpenMark renders math via KaTeX — fast, fully offline, no network requests required. For a tutorial with practical examples, see Getting Started with LaTeX Math in Markdown.
Mermaid Diagram Syntax
Mermaid lets you write diagrams as text inside fenced code blocks with the mermaid language identifier.
Flowchart
```mermaid
flowchart TD
A[Start] --> B{Decision?}
B -->|Yes| C[Do thing]
B -->|No| D[Skip it]
C --> E[End]
D --> E
```
Direction: TD (top-down), LR (left-right), RL, BT.
Node shapes: [Rectangle], (Rounded), {Diamond}, ([Pill]), [(Database)].
Sequence Diagram
```mermaid
sequenceDiagram
participant Client
participant API
participant DB
Client->>API: GET /users/1
API->>DB: SELECT * FROM users WHERE id=1
DB-->>API: { id: 1, name: "Alice" }
API-->>Client: 200 OK
```
Gantt Chart
```mermaid
gantt
title Sprint 12
dateFormat YYYY-MM-DD
section Features
Auth redesign :done, 2026-02-01, 2026-02-10
Dashboard v2 :active, 2026-02-10, 2026-02-20
section Bugs
Fix search :2026-02-15, 2026-02-17
```
For more Mermaid examples including ER diagrams, state diagrams, and pie charts, see How to Render Mermaid Diagrams in Markdown on Mac.
Mac Keyboard Shortcuts in OpenMark
OpenMark follows macOS conventions throughout:
| Action | Shortcut |
|---|---|
| Bold | ⌘B |
| Italic | ⌘I |
| Insert link | ⌘K |
| Toggle edit/preview | ⌘E |
| New document | ⌘N |
| Open file | ⌘O |
| Save | ⌘S |
| Export to PDF | ⌘⇧E |
| Find | ⌘F |
| Zoom in/out | ⌘+ / ⌘- |
These shortcuts work the same way as other macOS apps — no remapping or configuration needed.
Editor Feature Comparison
Not every markdown editor supports the full syntax. Here's where things stand:
| Feature | OpenMark | Obsidian | Typora | iA Writer | VS Code |
|---|---|---|---|---|---|
| GFM tables | ✓ | ✓ | ✓ | ✓ | ✓ |
| Mermaid | ✓ | Plugin | — | — | Extension |
| LaTeX math | ✓ | Plugin | ✓ | — | Extension |
| Task lists | ✓ | ✓ | ✓ | — | ✓ |
| Footnotes | ✓ | ✓ | ✓ | ✓ | ✓ |
| Strikethrough | ✓ | ✓ | ✓ | ✓ | ✓ |
| Native macOS | ✓ | — | — | ✓ | — |
For a full breakdown of each editor's strengths and weaknesses, see The Best Markdown Editors for Mac in 2026.
Tips That Aren't Obvious
Escape characters. To show a literal * or # without it being interpreted as markdown, backslash-escape it: \*, \#, \[.
Line breaks. A single line break in markdown doesn't create a new paragraph — you need a blank line. For a <br> within a paragraph, end the line with two spaces or a backslash.
HTML works. Most markdown processors pass through raw HTML. <kbd>⌘</kbd> renders as a keyboard key. <details>/<summary> creates a collapsible section. Use HTML for things markdown can't do.
Don't over-format. Markdown is most readable when it's used sparingly. A wall of bold and inline code is harder to read than prose. Reserve formatting for genuinely important information.
Try OpenMark
If you're writing markdown on a Mac, OpenMark renders all of this syntax natively — GFM tables, Mermaid diagrams, LaTeX math — offline, with no extensions or configuration.
Download OpenMark on the Mac App Store → $9.99, one-time purchase. Built for macOS Tahoe.