> ## Content Index
> Fetch the complete content index at: https://itsfoss.com/llms.txt
> Use this file to discover other available public pages before exploring further.

# Adding Comments in Markdown
- URL: https://itsfoss.com/markdown-comments/
- Published: 2023-02-08T13:38:14.000Z
- Updated: 2025-08-04T10:30:36.000Z
- Description: There is no straightforward way of adding comments in Markdown. Still, here's a neat trick you can use and add comments.
- Author: Abhishek Prakash
- Tags: Markdown

Unlike HTML, Markdown doesn't provide a proper way to add comments. Perhaps because it was not created to write codes. 

But that doesn't mean you cannot add comments in Markdown. Different implementations of Markdown has different ways of adding comments.

Let me share the most reliable one with you.

## How to add comments in Markdown?

To add a comment in Markdown, **first add an empty line** (by pressing enter key twice) and use the following code:

```
[comment]: Comment text
```

Actually, you can use anything instead of \[comment\]. All you need is something in the brackets followed by the colon (and an empty line in the previous line). Anything on this line is not shown in the rendered text.

![Adding comments in Markdown](https://itsfoss.com/content/images/2023/02/markdown-comments.png)

Examples of comments in Markdown (click to enlarge)

## Comment, please 💬

As I said, there is no proper way of adding comments in Markdown. Why should be there? It was created to write text in a simple language, not for programming web pages. This trick that I just discussed is actually like adding reference links in Markdown. 

But it works and in some rare cases if you need to add comments that is not seen in the rendered text, you can use this trick.

Markdown is all about syntax. The more you practice, the easier it gets to write in Markdown. 

I have created this cheat sheet to help you remember the common Markdown syntax. Feel free to download it, print it (if you want) and keep it at your desk for quick reference.

[Download Markdown Syntax Cheatsheet](https://itsfoss.com/content/files/2023/01/Markdown-Cheat-Sheet.pdf)

If you want a detailed explanation of [Markdown syntax](https://itsfoss.com/markdown-guide/), we have a guide for that as well.

[Basic Markdown Syntax Explained \[With Free Cheat Sheet\]Learning markdown could help you a lot with writing for web. Here’s a complete beginner’s guide to Markdown syntax with downloadable cheat sheet.![](https://itsfoss.com/content/images/size/w256h256/2022/12/android-chrome-192x192.png)It's FOSSBill Dyer![](https://itsfoss.com/content/images/wordpress/2021/04/markdown.png)](https://itsfoss.com/markdown-guide/)

I hope you find this helpful in adding links in Markdown. If you have any questions or suggestions, please feel free to leave a comment.