# Text Alignment

> Which edge lines of text line up on: left, right, center or both.

**Field:** Design  
**Category:** Typography  
**Also known as:** Justified Text, Flush Left, Ragged Right

## Think of it like

It is like lining up books on a shelf. Push them to one side, or to the middle.

## Definition

Text alignment is which edge the lines of a paragraph line up on. Left-aligned text has a straight left edge and a ragged right one. Centered text works for a few short lines. Justified text stretches every line to both edges. It looks neat, but on screens it can leave wide gaps called rivers. Persian and Arabic text lines up on the right instead.

## Example

A blog switches from justified to left-aligned text. The odd wide gaps between words disappear.

## Example code

```css
p {
  text-align: start;
}
```

start means left in English and right in Persian, so one rule works for both.

## Why it matters

A clean starting edge helps the eye find the start of every line.

## Common mistake

Justifying text on narrow phone screens. The words spread out with big holes between them.

## Three principles

- **Start edge for reading.** Left in English, right in Persian.
- **Center for short bits.** Titles and a few lines.
- **Justify with care.** Watch for rivers of space.

## Related terms

- [Line Length](https://learn.benibix.com/term/design/line-length)
- [Widows and Orphans](https://learn.benibix.com/term/design/widows-and-orphans)
- [Alignment](https://learn.benibix.com/term/design/alignment)
- [Hyphenation](https://learn.benibix.com/term/design/hyphenation)
- [Right-to-Left Text (RTL)](https://learn.benibix.com/term/design/right-to-left-text)
- [Kashida](https://learn.benibix.com/term/design/kashida)

## Taught in

- [Line Length and Paragraphs](https://learn.benibix.com/learn/design-typography/line-length-and-paragraphs): Typography, 9/17

---

Source: https://learn.benibix.com/term/design/text-alignment
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-17
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
