Can Markdown Have Images?


Yes, markdown supports adding images. The goal of Markdown is to provide a more readable alternative syntax to that of HTML for writers and editors. The majority of the Markdown syntax covers typographic HTML tags.

For example, to make a text bold in HTML you will use the following syntax < b > text to bolden whereas in Markdown that will be ** text to bolden **. As you can see the Markdown version is more readable although it still has special constructs around it. Also since Markdown is focused on the typographical part of HTML there is no syntax or construct for most HTML tags such as input fields in Markdown.

There is however syntax for adding images to your Markdown document.

How to add an image using markdown

Below is an example of how to add an image to your document using Markdown syntax.

01: ![alt text](path/to/image.png)

It's very similar to the Markdown anchor link syntax, the only difference being that the image syntax starts with !.

How to add an image using HTML

As explained at the beginning of this post using the b tag as an example Markdown has a one-to-one syntax mapping with HTML.

This means Markdown parsers in the end take Markdown syntax and convert them to their HTML equivalent. So whenever a parser finds HTML within a markdown document it does not need to covert it.

This means you can use HTML directly within your markdown document. So if we would like to add an image to our Markdown we can use the HTML IMG tag.

01: <img src="path/to/image.png" alt="alt text">

Here is another article for you 😊 "5 terms to know as a technical writer [part 1]"