Markdown Tutorial

By Xah Lee. Date: . Last updated: .

Mardown is a simple markup language, designed to be converted to HTML.

Here's a simple example.

# this is 1st level heading

something something. This is a paragraph.

## this is 2nd level heading

### this is 3rd level heading

# Inline Code

Code: Use the backtick character: `x = 3;`.

# Code Block

Code block can be marked by 4 space indentation (or 1 tab), with a blank line before, like this:

    x = 4

# Italic, Bold

Italic is between asterisks. Like this: *important*

Bold is 2 asterisks. Like this: **critical**

# Blockquotes

Blockquotes, is done with preceding each line with >, like this:

He said:
> something something
> something something else
> and more

# Unordered List

List is done with preceding each line with asterisk. Like this:

* 1st item
* another item
* and 3rd item


- 1st item
- another item
- and 3rd item

# List Ordered list

1. 1st item
2. another item
3. and 3rd item

# Nested List

Use indent by 2 spaces:

1. something
  1. and more
  2. so much more
2. Secondly,
  * this is seconod sublist
    * and 3rd level list
    * 2nd item of 3rd level list
3. and lastly.

# Link

write link like this:
Google search site is [Google Search](

# Images

![Alt text](/path/to/img.jpg)

![Alt text](/path/to/img.jpg "Optional title")

Markdown Filename Extension

Markdown filename extension is .md

How to convert markdown to HTML?

Download the script at

Then, just run

markdown filename

It'll create a HTML file at the same directory.