Degree symbol (90° or °C) in LaTeX

In LaTeX, you can print the degree (°) symbol in multiple ways. However, you can notice different outputs for different methods. In this tutorial, I will show you all of those methods to write degree symbol in LaTeX.

All the packages and commands

This table will help you choose your preferred package and command to print the degree symbol in LaTeX.

PackageCommandOutput
None$0^\circ$
gensymb0\degree
gensymb$0\degree$
textcomp0\textdegree
textcomp0\textcelsius0°C
siunitx\ang{0}

Degree symbol without package

You can use the default command \circ, which will print a small circle symbol. Now you have to use this symbol in superscript. This command works in  LaTeX math mode.

\documentclass{article}
\begin{document}

  $$ \verb|30^\circ C| \rightarrow 30^\circ C $$
  $$ \verb|\angle 90^\circ| \rightarrow \angle 90^\circ $$

\end{document}

Output:

30 degree celsius and 90 degree angle.

Degree symbol in LaTeX text mode

In order to print the degree symbol in text mode you can use the \ang(<value>) from siunitx package or \textdegree from textcomp package. These commands give you slightly different outputs. Take a look.

\documentclass{article}
\usepackage{siunitx}
\usepackage{textcomp}
\begin{document}

  \verb|\ang{30} C| $\rightarrow$ \ang{30} C\\[4pt]
  \verb|30\textdegree C| $\rightarrow$ 30\textdegree C\\[4pt]
  \verb|\angle \ang{90}| $\rightarrow$ \angle \ang{90}\\[4pt]
  \verb|\angle 90\textdegree| $\rightarrow$ \angle 90\textdegree

\end{document}

Output:

Degree symbol in text mode.

Leave a Reply

Your email address will not be published. Required fields are marked *