Correct syntax to display subscript in markdown content?

In my content file I use syntax such as CO~2~ for subscript. As far as I know this is the correct syntax for markdown subscript. This does not get rendered as a subscript though, just literally as CO~2~. I’m having a difficult time finding documentation for the correct syntax to display a subscript in our markdown content files using Blackfriday with Hugo. Can anyone help?

I guess this is the closest to a Markddown spec:

https://daringfireball.net/projects/markdown/syntax

And there is no subscript, so you would be better off using CO<sub>2</sub>.

Thanks for the response! Yeah we were hoping HTML tags wouldn’t be the case. We use a text to markdown converter so we can just copy and paste everything, so in this case will have to go through and convert all ~ to tags.

This is also a font issue. If the font you are using on the page doesn’t contain a subscript glyph then it won’t show one. Not all fonts contain subscripts. If the text is encoded correctly at the source (using e.g. U+2082 for the subscript 2) then you don’t have to do anything special in markdown to get it on to your page - but the page’s font still has to have the glyph.