Pijlsymbolen

Richtingspijlen, dubbele pijlen en harpoenen voor LaTeX-documenten.

LaTeX arrows: how to write an arrow in LaTeX

LaTeX arrows are math-mode commands named after their direction: to type an arrow in LaTeX, write $\rightarrow$ for →, $\leftarrow$ for ← and $\Rightarrow$ for the double arrow ⇒. The table below lists the 12 arrows people use most, with the package each one needs; the full list of arrow symbols follows further down the page.

Quick reference: the most used arrows

SymbolCommandUsePackageCopy
→\rightarrow
\rightarrowRight arrowbuilt in
→\to
\toMaps to a set, limits (x → ∞)built in
←\leftarrow
\leftarrowLeft arrow, assignmentbuilt in
↔\leftrightarrow
\leftrightarrowLeft-right arrow (both directions)built in
⇒\Rightarrow
\RightarrowImplies (double arrow)built in
⇔\Leftrightarrow
\LeftrightarrowIf and only ifbuilt in
↦\mapsto
\mapstoFunction rule, x ↦ x²built in
⟶\longrightarrow
\longrightarrowLong right arrowbuilt in
↑\uparrow
\uparrowUp arrowbuilt in
↓\downarrow
\downarrowDown arrowbuilt in
↪\hookrightarrow
\hookrightarrowInjection, inclusionbuilt in
→f\xrightarrow{f}
\xrightarrow{f}Arrow with text above, stretches to fitamsmath

Arrows in text mode vs math mode

Every command in the table is a math symbol, so it must sit inside $...$ or an equation environment; in running text use $\to$ or the text-mode commands \textrightarrow and \textleftarrow. The basic arrows are built in; add these lines to your preamble for labelled arrows (\xrightarrow, \implies) and the extra arrows from the AMS fonts (\twoheadrightarrow, \rightsquigarrow, \nrightarrow):

\usepackage{amsmath}
\usepackage{amssymb}

Which arrow to use

The arrows people look up most are the plain right arrow \rightarrow (or its shorthand \to, used in f: A \to B and limits like x \to \infty), the left arrow \leftarrow, the double-headed \leftrightarrow, and the thick double arrows \Rightarrow and \Leftrightarrow that stand for implication and equivalence. Function rules use \mapsto (x \mapsto x^2), and the long variants \longrightarrow, \Longrightarrow and \longmapsto give you extra room in commutative diagrams. Vertical and diagonal arrows are \uparrow, \downarrow, \nearrow and \searrow; hooked and harpoon arrows such as \hookrightarrow, \rightharpoonup and \rightleftharpoons mark injections and equilibria.

For logic, prefer \implies (from amsmath) and the built-in \iff, which add the correct spacing around the arrow, and for labelled arrows use \xrightarrow{f} and \xleftarrow{g}, also from amsmath, which stretch to fit the label. Negated and squiggly arrows (\nrightarrow, \rightsquigarrow, \twoheadrightarrow) need \usepackage{amssymb}.

For the meaning behind each arrow and how to type them outside LaTeX, see our guide to arrow symbols and how to type them, or the overview of mathematical expressions in LaTeX. Click any card below to copy its command.

Frequently asked questions about LaTeX arrows

How do I write an arrow in LaTeX?
Arrows are math symbols, so put them in math mode: $\rightarrow$ (or the shorthand $\to$) gives a right arrow, $\leftarrow$ a left arrow and $\leftrightarrow$ a left-right arrow. Capitalising the first letter gives the double-line version, for example \Rightarrow and \Leftrightarrow. None of these need a package.
How do I make a long arrow in LaTeX?
Prefix the name with long: \longrightarrow, \longleftarrow and \longleftrightarrow, or \Longrightarrow and \Longleftrightarrow for double arrows, and \longmapsto for a long maps-to arrow. If the arrow needs to grow with a label, use \xrightarrow{...} from amsmath instead.
How do I put text above an arrow in LaTeX?
Load amsmath and use \xrightarrow{text} or \xleftarrow{text}; the arrow stretches to fit the label. An optional argument adds text below the arrow: \xrightarrow[below]{above}. For a fixed-size arrow you can also write \overset{f}{\rightarrow}.
How do I write a double arrow in LaTeX?
Use \Rightarrow for ⇒, \Leftarrow for ⇐ and \Leftrightarrow for ⇔. In logic, \implies (amsmath) and the built-in \iff give the same arrows with wider spacing. For two arrows stacked on top of each other use \rightleftarrows (amssymb) or \rightleftharpoons for chemical equilibria.
How do I use an arrow in text mode in LaTeX?
Writing \rightarrow outside math mode causes a “Missing $ inserted” error. Either wrap it as $\rightarrow$, or use the text-mode commands \textrightarrow, \textleftarrow, \textuparrow and \textdownarrow, which are part of the LaTeX kernel (textcomp) and match the surrounding text font.
←\leftarrow

Left Arrow

\leftarrow
→\rightarrow

Right Arrow

\rightarrow
↑\uparrow

Up Arrow

\uparrow
⟵\longleftarrow

Long Left Arrow

\longleftarrow
⟶\longrightarrow

Long Right Arrow

\longrightarrow
↓\downarrow

Down Arrow

\downarrow
⇐\Leftarrow
⇒\Rightarrow
⇑\Uparrow
⟸\Longleftarrow
⟹\Longrightarrow
⇓\Downarrow
↔\leftrightarrow

Left Right Arrow

\leftrightarrow
⟷\longleftrightarrow

Long Left Right Arrow

\longleftrightarrow
↕\updownarrow

Up Down Arrow

\updownarrow
⇔\Leftrightarrow
⟺\Longleftrightarrow
⇕\Updownarrow
↦\mapsto

Maps To

\mapsto
⟼\longmapsto

Long Maps To

\longmapsto
↗\nearrow

Near Arrow

\nearrow
↩\hookleftarrow

Hook Left Arrow

\hookleftarrow
↪\hookrightarrow

Hook Right Arrow

\hookrightarrow
↘\searrow

Search Arrow

\searrow
↼\leftharpoonup

Left Harpoon Up

\leftharpoonup
⇀\rightharpoonup

Right Harpoon Up

\rightharpoonup
↙\swarrow
↽\leftharpoondown

Left Harpoon Down

\leftharpoondown
⇁\rightharpoondown

Right Harpoon Down

\rightharpoondown
↖\nwarrow