This is the documentation for version 1.3. Please consider upgrading your code to the latest stable version

Command Line

Markdown can be converted at the command line using the ./bin/commonmark script.


./bin/commonmark [OPTIONS] [FILE]

If no file is given, input will be read from STDIN.

Output will be written to STDOUT.


Converting a file named


Converting a file and saving its output

./bin/commonmark > output.html

Converting from STDIN

echo -e '# Hello World!' | ./bin/commonmark

Converting from STDIN and saving the output

echo -e '# Hello World!' | ./bin/commonmark > output.html