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

LaTeX Vec: Vector Arrow Syntax, Multi-Letter and Bold Alternatives

\vec puts an arrow over one symbol; use \overrightarrow for multi-letter vectors and \boldsymbol for bold. Syntax, column vectors and fixes.

Written and maintained by CASRAI Editorial Board

Last updated

Short answer: in math mode, \vec{v} puts a vector arrow over a single symbol. For a label with two or more letters such as AB, use \overrightarrow{AB}. For bold vectors instead of arrows, use \mathbf{v} or amsmath’s \boldsymbol{v}. This guide is for researchers and analysts writing equations in LaTeX who need to choose one vector notation and typeset it correctly.

What \vec is used for in research writing

In the LaTeX2e reference manual’s section on math accents, \vec is listed as the “math vector symbol”, alongside \hat (math hat accent) and \widehat (math wide hat accent). It is an accent: it sits above the one symbol it is applied to. Papers in physics, engineering, statistics and machine learning use it to mark quantities such as velocity \vec{v} or force \vec{F} as vectors rather than scalars.

Arrow notation is one of several conventions. Many journals and textbooks print vectors in bold type instead, so follow your target journal’s style or thesis template and keep one convention across the whole document. The comparison table below sets out the options side by side.

Install or access

\vec is part of core LaTeX, so it needs no package. Two optional packages extend it, both distributed through CTAN (the Comprehensive TeX Archive Network):

  • amsmath, the principal AMS-LaTeX package, which CTAN describes as “highly recommended as an adjunct to serious mathematical typesetting in LaTeX”. It is part of the required LaTeX distribution. Load it with \usepackage{amsmath}. It supplies \overrightarrow, \boldsymbol and the pmatrix environment used below.
  • esvect, a CTAN package for vectors with an arrow that differs from the standard Computer Modern one. Load it with \usepackage{esvect}; it provides \vv{...}. Its documentation lists arrow-height options a to h (option d is the default), chosen when you load the package, for example \usepackage[a]{esvect}.

Step-by-step: typeset a vector arrow

  1. Load the packages you need in the preamble: \usepackage{amsmath} (and \usepackage{esvect} only if you want the alternative arrow).
  2. Enter math mode: inline with $...$, or display with \[ ... \].
  3. For a one-letter vector, write \vec{v}. A single Greek letter works the same way: \vec{\omega}.
  4. For a vector named by two or more letters, such as the displacement from point A to point B, write \overrightarrow{AB} instead of \vec{AB}.
  5. For the unit vectors i and j, write the dotless forms: \vec{\imath} and \vec{\jmath}. The LaTeX2e reference manual states that when you put an accent on an i or a j, the tradition is to use the one without a dot, \imath or \jmath.
  6. For a bold vector, write \mathbf{v}. For a bold Greek letter, which \mathbf does not reliably affect, write \boldsymbol{\omega}.

A complete, compilable example:

\documentclass{article}
\usepackage{amsmath}
\begin{document}
Velocity $\vec{v}$, displacement $\overrightarrow{AB}$,
unit vectors $\vec{\imath}$ and $\vec{\jmath}$, bold $\mathbf{v}$.
\[
  \vec{F} = m\,\vec{a}
\]
\end{document}

\vec vs \overrightarrow vs bold: which to use

Command Package What it does Typical use
\vec{v} Core LaTeX Vector accent over one symbol Single-letter vectors
\overrightarrow{AB} amsmath (basic LaTeX also provides it, per the amsmath guide) Right-pointing arrow over its whole argument Multi-letter vectors such as a displacement between two points
\mathbf{v} Core LaTeX Bold roman letters Bold-style vectors in Latin letters
\boldsymbol{\omega} amsmath Bold version of symbols that \mathbf leaves unchanged, if the math fonts include a bold form Bold Greek-letter vectors
\pmb{\omega} amsmath “Poor man’s bold”: overprints copies of a symbol with slight offsets Last resort when no true bold exists; the amsmath guide says quality is inferior for hairline strokes
\vv{AB} esvect Vector with an alternative arrow; the star form \vv*{e}{r} adds a subscript; arrow size follows the math environment When you want a different arrow from Computer Modern

The amsmath guide notes that \mathbf works for bold Latin letters but, for most other kinds of symbol, has no effect or depends unreliably on the math fonts in use. That is why bold Greek vectors need \boldsymbol.

Column vectors and brackets

A vector written as a column of components is a matrix with one column. The amsmath package provides pmatrix (round brackets), bmatrix (square brackets), Bmatrix (braces), vmatrix and Vmatrix (single and double vertical bars), each with its delimiters built in:

\[
  \mathbf{x} =
  \begin{pmatrix} x_1 \\ x_2 \\ x_3 \end{pmatrix}
  \quad\text{or}\quad
  \begin{bmatrix} x_1 \\ x_2 \\ x_3 \end{bmatrix}
\]

Round and square brackets are both common; pick one and keep it for every vector and matrix in the document. For operators that act on vectors, see the guide to the LaTeX vector product (cross and dot product symbols).

Output and how to read it

\vec{v} renders as the letter v with a small right-pointing arrow above it. \overrightarrow{AB} renders as A and B under one arrow that spans both letters. \mathbf{v} renders an upright bold v with no arrow, so the vector nature is signalled only by typography; state your convention once in the text (“vectors are written in bold”) so readers are not left to guess.

If you need a bar rather than an arrow, see LaTeX overline. For free-standing arrow symbols such as the implication arrow, see LaTeX rightarrow. For blackboard-bold sets such as the real numbers, see LaTeX mathbb.

Troubleshooting

  • The arrow looks too short over several letters. \vec is an accent for a single symbol. Switch to \overrightarrow{...}.
  • “Undefined control sequence” on \boldsymbol or pmatrix. Check that \usepackage{amsmath} is in the preamble.
  • “Undefined control sequence” on \vv. It comes from esvect, not core LaTeX; load \usepackage{esvect}.
  • Bold Greek letters are not bold. \mathbf does not reliably affect them; use \boldsymbol, or \pmb as a last resort.
  • The dot on i or j collides with the arrow. Use \imath and \jmath.

Free alternatives to the standard arrow

Option Availability Notes
Bold vectors with \mathbf / \boldsymbol amsmath is part of the required LaTeX distribution No arrow; state the convention in the text
\overrightarrow amsmath Arrow spans multi-letter labels
esvect \vv Package on CTAN Eight selectable arrow heights (options a to h)

See also LaTeX math signs, commands and required packages for other symbols that depend on amsmath.

FAQ

How do I put a vector arrow over a letter in LaTeX?

In math mode, write \vec{v}. It places a vector arrow accent over the single symbol in the braces.

How do I put a vector arrow over two letters?

Use \overrightarrow{AB} so one arrow covers both letters, rather than \vec{AB}.

How do I write a bold vector in LaTeX?

Use \mathbf{v} for Latin letters. For Greek letters and other symbols, use amsmath’s \boldsymbol{...}.

How do I write a column vector?

Use amsmath’s pmatrix (round brackets) or bmatrix (square brackets) with one entry per row, separated by \\.

What is the difference between \vec and \overrightarrow?

\vec is a single-symbol accent in core LaTeX; \overrightarrow draws an arrow over its entire argument and is the usual choice for multi-letter labels.

Sources

  • LaTeX2e unofficial reference manual, “Math accents” (read 2026-11-07): latexref.xyz/Math-accents.html
  • American Mathematical Society, User’s Guide for the amsmath Package (version 2.1, 1999-12-13), sections 4.8, 9.3 and the matrix environments (read 2026-11-07): amsldoc.pdf
  • CTAN, amsmath package page (read 2026-11-07): ctan.org/pkg/amsmath
  • E. Saudrais, Typesetting vectors with beautiful arrow with LaTeX 2e, esvect version 1.3 (read 2026-11-07): esvect.pdf; CTAN page ctan.org/pkg/esvect

Follow CASRAI

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

Ask CASRAI · free to try

Ask about LaTeX Vec: Vector Arrow Syntax, Multi-Letter and Bold Alternatives

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 →