On strong heating, mercury forms into a red powder of mercury(II) oxide.

mercury + oxygen —> mercury(II) oxide
2Hg(l) + O2(g) —> 2HgO(s)

This reaction only occurs around 350°C. However, above 400°C, mercury(II) oxide decomposes back into the elements.
In fact, this is an important experiment carried out by J. Priestley in 1774, leading to the discovery of oxygen.

Reaction with dilute acids

Mercury does not react with dilute hydrochloric and sulfuric acids. However, it can react with concentrated sulfuric and nitric acids.