Skip to main content
v2026.11,986 entries · CC-BY 4.0

LaTeX Degree Symbol (°): Commands for Text, Math and Units

Choose the right LaTeX degree-sign command for text, math, angles and temperatures, with a sourced task table and short answers on int and real numbers.

Written and maintained by CASRAI Editorial Board

Published · Last updated

On this page

Who this is for: researchers writing papers, theses or reports in LaTeX who need a degree sign (°) for an angle, a temperature or a coordinate, and want the right command for the context. After reading you can pick one command, load the package it needs, and know what it prints.

Short answer: in running text use \textdegree (a textcomp/TS1 command); \degree from gensymb works in both text and math mode; for angles and units use siunitx, \ang{30} for an angle and \qty{25}{\degreeCelsius} for a temperature.

What it is used for in research

The degree sign appears in angles (a 30° incidence angle), temperatures (25 °C), latitude and longitude, and rotation or orientation parameters. LaTeX has no single built-in “degree” key; the right command depends on whether the sign sits in text, in a formula, or inside a quantity with a unit. The table below maps each task to the command documented in the Comprehensive LaTeX Symbol List, the gensymb package page and the siunitx manual.

Task Command Needs Source
Degree sign in running text \textdegree textcomp (TS1) symbol; part of the LaTeX distribution Symbol List; CTAN textcomp
Degree sign in text or math with one command \degree \usepackage{gensymb} CTAN gensymb; Symbol List
Degree sign inside a formula ^\circ (or \ensuremath{^\circ}) standard math mode Symbol List
Angle with a number \ang{30}, \ang{1;2;3} \usepackage{siunitx} siunitx manual, section 3.2
Temperature with a unit \qty{25}{\degreeCelsius}, \qtyrange{2}{4}{\degreeCelsius} \usepackage{siunitx} siunitx manual
Celsius symbol as one glyph \textcelsius or \celsius textcomp / gensymb Symbol List; CTAN gensymb

Install or access

All the packages above are free and distributed through CTAN, the Comprehensive TeX Archive Network. Per its CTAN page, textcomp “has been adopted as part of the LaTeX distribution”, so TS1 symbols such as \textdegree need no separate installation. Package pages: gensymb, textcomp, siunitx.

Step-by-step: how to write a degree in LaTeX

How to write a degree in LaTeX?

  1. Decide the context. Plain prose: \textdegree. A number with an angle: \ang{}. A temperature or other quantity with a unit: \qty{}{} with \degreeCelsius. Inside an equation: ^\circ.
  2. Load the package if the command needs one. In the preamble: \usepackage{gensymb} for \degree and \celsius, or \usepackage{siunitx} for \ang and \qty.
  3. Type the command. Examples:
    The beam hits the surface at 30\textdegree.
    Rotate by $90^\circ$.
    \ang{12.3}   \ang{1;2;3}
    \qty{25}{\degreeCelsius}
    \qtyrange{2}{4}{\degreeCelsius}
  4. Compile and check the output (see below).

Output and how to read it

The siunitx manual (v3.6.7, last revised 2026-11-06, read 2026-11-07) states that \ang takes the angle “either as a decimal number or as a semi-colon separated list of degrees, minutes and seconds, which is called arc format”. So \ang{12.3} prints 12.3° and \ang{1;2;3} prints 1° 2′ 3″. The manual’s example \qtyrange{2}{4}{\degreeCelsius} prints “2 °C to 4 °C”.

The Symbol List adds a note for formulas: if you prefer a larger degree symbol you might define one as \ensuremath{^\circ}. The gensymb page says its commands “work in both text and math mode” and that the package falls back to faking the symbol or taking it from a symbol font if it is absent (version 1.0.2).

Troubleshooting

  • \degree is undefined. It comes from gensymb; add \usepackage{gensymb} to the preamble.
  • \ang or \qty is undefined. They come from siunitx; load it in the preamble.
  • \textdegree fails in an old setup. textcomp is now part of the LaTeX distribution according to its CTAN page, so updating the distribution is the cleaner fix.
  • Wrong command for the mode. \textdegree is a text-mode command; in a formula use ^\circ or \degree.

Free alternatives: which route to use

Route Suited to Mode
\textdegree (textcomp/TS1) A degree sign in prose Text
\degree (gensymb) One command for text and math, plus \celsius Text and math
^\circ Angles inside equations Math
\ang, \qty (siunitx) Numbers with units, degree-minute-second angles Text and math

For the surrounding unit conventions see SI units in scientific writing.

FAQ

How to write a degree in LaTeX?

Use \textdegree in text, ^\circ in math, \degree with gensymb for either, or \ang{30} with siunitx when the degree belongs to a number.

How to write int in LaTeX?

The integral sign is \int, a standard math operator listed with \iint, \iiint and \oint in the Symbol List’s variable-sized operator tables. Example: $\int_0^1 f(x)\,dx$. For limits and multiple integrals see integration in LaTeX.

What is ALT 248?

It is a keyboard code entry, not a LaTeX command, so it is not what you put in a .tex file. The degree sign itself is Unicode U+00B0 (hex B0, decimal 176, as listed in the Symbol List’s encoding table). In LaTeX, produce it with the commands above.

How to type real numbers in LaTeX?

The set of real numbers ℝ is written with blackboard-bold R, \mathbb{R}; the Symbol List shows \mathbb among its math alphabets. Package requirements are covered in LaTeX mathbb. For Greek letters and other symbols see Greek symbols in LaTeX.

Sources

Follow CASRAI

Research-administration guidance, standards updates and independent tool reviews.

Ask CASRAI · free to try

Ask about LaTeX Degree Symbol (°): Commands for Text, Math and Units

Ask your first 2 questions free below. Subscribers get 150 a day for $29 a month.

An AI assistant specialized in research administration. It cites the sources behind every answer, labels web answers and says when it can't answer.

Answers draw on CASRAI's guides and dictionary plus the federal and funder documents we index: Federal Register, Grants.gov, Regulations.gov and UKRI.

Works on this site and inside Claude, Cursor and the AI tools you already use.

Everything CASRAI publishes — this page, the dictionary, the guides and the news — stays free to read, with no account and no card.

Referenced across the research world

University of Cambridge logoColumbia University logoCrossref logoUniversity of Edinburgh logoHarvard University logoUniversity of Oxford logoPrinceton University logoStanford School of Medicine logoUniversity College London logoORCID logoUniversity of Cambridge logoColumbia University logoCrossref logoUniversity of Edinburgh logoHarvard University logoUniversity of Oxford logoPrinceton University logoStanford School of Medicine logoUniversity College London logoORCID logo
  • University of Cambridge logo
  • Columbia University logo
  • Crossref logo
  • University of Edinburgh logo
  • Harvard University logo
  • University of Oxford logo
  • Princeton University logo
  • Stanford School of Medicine logo
  • University College London logo
  • ORCID logo

View CASRAI adoption →