Markdown Nested List
How to create nested and indented lists in markdown. Sub-bullets, mixed ordered and unordered lists, and indentation rules.
What is markdown nested list?
Nested lists are created by indenting list items with 2–4 spaces (or a tab). You can nest unordered lists inside ordered lists and vice versa. The level of indentation determines the depth of nesting.
Syntax
Nested unordered
Indent with 2 spaces (or 4) to create a sub-list.
- Item 1
- Sub-item 1a
- Sub-item 1b
- Item 2...
Nested ordered
Ordered sub-lists use 3 spaces of indentation (to align after the number and period).
- Step one
- Sub-step a ...
Mixed types
Mix ordered and unordered lists at different nesting levels.
- First
- Bullet
Platform support
| Platform | Supported | Notes |
|---|---|---|
| GitHub | Yes | — |
| GitLab | Yes | — |
| Discord | Yes | — |
| Slack | Yes | — |
| Notion | Yes | — |
| Obsidian | Yes | — |
Common mistakes
- Item - Sub-item (no indent)
- Item - Sub-item (2 spaces)
Without indentation, both items appear at the same level. You must indent to create a nested list.
Mixing tabs and spaces
Use consistent 2-space or 4-space indentation
Mixing tabs and spaces causes inconsistent rendering across parsers. Pick one and stick to it.
Tips for nested list
More than three levels of nesting is hard to read. Restructure with headings or separate lists if you find yourself going deeper.
GitHub and most modern parsers accept 2-space indentation. Older parsers (Python-Markdown) require 4 spaces. For safety, use 4.
Frequently asked questions
Everything you need to know.
How do I indent a list in markdown?
Add 2 spaces (or 4) before the - or number on the sub-list item. For ordered lists, align the sub-list with the first character after the number and period.
Related elements
Bullet List
Bullet lists (unordered lists) in markdown start each item with a dash (-), asterisk (*), or plus sign (+) followed by a space. They're the most common way to present non-sequential items, features, or options.
Numbered List
Numbered lists (ordered lists) in markdown start each item with a number followed by a period and a space (1. ). Markdown auto-numbers the output regardless of the numbers you type — all items could be "1." and the rendered list would still count correctly.
Task List
Task lists (also called checklists or to-do lists) are a GitHub Flavored Markdown extension that renders interactive checkboxes. An unchecked item uses - [ ] and a checked item uses - [x]. On GitHub, the checkboxes are clickable in issues and pull requests.
Try it in the editor
Paste your markdown and see nested list rendered instantly with professional themes.