# \overline

Used to place a bar over a mathematical symbol or expression, e.g. conjugates, closures, or repeated decimals.

https://texform.dev/latex/commands/overline

## Metadata

| Field | Value |
| --- | --- |
| Topic | [Accents](https://texform.dev/latex/topics/accents) |
| Packages | base |
| Allowed mode | math |
| Tags | decoration |
| Commonality | high |
| Kind | prefix |

## Syntax

### base

Argument specification: `m`

Used to place a bar over a mathematical symbol or expression, e.g. conjugates, closures, or repeated decimals.

## Common tasks

### How to draw a line over an expression

```latex
\overline{AB}
```

[Open in Playground](https://play.texform.dev/?input=%5Coverline%7BAB%7D)

### How to write a complex conjugate

```latex
\overline{z}=x-iy
```

[Open in Playground](https://play.texform.dev/?input=%5Coverline%7Bz%7D%3Dx-iy)

### How to write a repeating decimal

\overline stretches; \bar is the single-letter accent.

```latex
0.\overline{3}
```

[Open in Playground](https://play.texform.dev/?input=0.%5Coverline%7B3%7D)

## Examples

```latex
\overline x
```

[Open in Playground](https://play.texform.dev/?input=%5Coverline+x)

## Renderer support

| Package | MathJax | KaTeX | XeTeX |
| --- | --- | --- | --- |
| base | full | full | full |

## Usage frequency

3.16% of formulas in the measured corpus contain this entry, rank 20 of 263 entries with frequency data.

## In TeXForm

TeXForm parses this entry as prefix syntax; the package determines its argument specification.

## Equivalent forms

```latex
\bar{#1}
```

approximate. \bar typically produces a shorter line centered over a single character, whereas \overline spans the entire expression

## See also

- [\\overbrace](https://texform.dev/latex/commands/overbrace)
- [\\overleftarrow](https://texform.dev/latex/commands/overleftarrow)
- [\\overleftrightarrow](https://texform.dev/latex/commands/overleftrightarrow)
- [\\overparen](https://texform.dev/latex/commands/overparen)
- [\\overrightarrow](https://texform.dev/latex/commands/overrightarrow)
- [\\underbrace](https://texform.dev/latex/commands/underbrace)
- [\\underleftarrow](https://texform.dev/latex/commands/underleftarrow)
- [\\underleftrightarrow](https://texform.dev/latex/commands/underleftrightarrow)
- [\\underline](https://texform.dev/latex/commands/underline)
- [\\underparen](https://texform.dev/latex/commands/underparen)
- [\\underrightarrow](https://texform.dev/latex/commands/underrightarrow)

## Test cases

### base

| Input | Case | MathJax | KaTeX | XeTeX |
| --- | --- | --- | --- | --- |
| \overline{a} | Positive: baseline | Pass | Pass | Pass |
| \overline a | Positive: bare[0] | Pass | Pass | Pass |
