Sub topic 4
How long should a line be?
This chapter assumes you know what the measure is (the length of a line of text) and can read basic CSS. It covers the commonly cited ranges for body text, how to count characters, and the cases where the ranges need adjusting. It does not cover leading or the CSS techniques in detail. Later chapters handle those.
Why the number matters
When you read a paragraph, your eyes jump across a line, then sweep back to the start of the next one. Two things go wrong at the extremes.
- Lines that are too long make the return sweep hard. The eye lands on the wrong line, or loses its place, and you reread text you already read.
- Lines that are too short force the eye to turn around constantly. Reading becomes choppy, and the text breaks into fragments that don't carry a full thought.
Both problems hurt comprehension and speed, and readers rarely notice the cause. They just feel that the page is tiring.
Measure is counted in characters
Designers describe the measure in characters per line (CPL), not in pixels or inches. A character count stays meaningful when the font size changes. A 600-pixel column holds about 75 characters in 16px text, but only about 55 in 22px text. The pixel width says little about how the line reads. The character count says a lot.
When you count, include letters, spaces, and punctuation. Count a few typical lines in a real paragraph, not a line of placeholder text, and take the average.
The commonly cited ranges
Typography references give a consistent set of numbers for body text on a screen or page.
| Situation | Characters per line |
|---|---|
| Comfortable range for body text | 45 to 75 |
| Widely used single target | about 66 |
| Practical web target | 50 to 75 |
| Multi-column layouts | about 40 to 50 |
| Tolerable but tiring | above 80 |
| Too choppy for continuous reading | below 35 |
Treat these as guidelines grounded in long experience with print and in reading studies. They are not laws. Studies disagree on exact thresholds, and some find that readers read fast on longer lines and still prefer shorter ones. The 45 to 75 range is a safe default, not a proof.
Where a short line is fine
The ranges apply to continuous reading, where a person reads many lines in a row. Some text is not read that way.
- Captions, pull quotes, and sidebar notes are short passages. A narrower line of 30 to 45 characters often suits them.
- Headings and labels are scanned, not read line by line.
- Narrow newspaper-style columns can drop to about 40 characters. They need justified or carefully ragged text and enough hyphenation to avoid large gaps.
In the other direction, long lines are sometimes acceptable in code listings and tables, where the content is not prose and the reader is not sweeping through sentences.
How the measure relates to type size
Size and measure are linked, because a line's character count depends on how big the characters are. Making the type larger shortens the line in characters unless you widen the column. Making the type smaller does the opposite.
This is why setting the width in a unit that follows the type is useful. In CSS, the ch unit equals the width of the "0" glyph in the element's font. A width of 65ch is therefore roughly 65 characters, and it grows or shrinks with the font size. The later chapter on CSS measure covers this in detail. Here is the basic form so you can see the idea.
p {
max-width: 65ch;
}Because ch is based on the digit "0", it is an approximation. In most text, average letters are narrower than "0", so a 65ch box often holds a little more than 65 characters of real prose, commonly 70 to 80 in a proportional font. That is why many designers choose a ch value near 60 to 66 to land inside the 45 to 75 range.
Checking the actual count
Do not trust the CSS value alone. Measure the rendered result in the browser.
- Open a page with real paragraph text.
- Pick three or four full lines in the middle of a paragraph. Avoid the first and last lines, which are often shorter.
- Count the characters in each, including spaces.
- Average them and compare with the target range.
You can also automate the check in the console. The script below counts characters per rendered line for the first paragraph on a page by walking its text and noting where the line breaks.
function charsPerLine(el) {
const text = el.firstChild;
const range = document.createRange();
const lines = [];
let lineStart = 0;
let lastTop = null;
for (let i = 0; i < text.length; i++) {
range.setStart(text, i);
range.setEnd(text, i + 1);
const rects = range.getClientRects();
if (!rects.length) continue;
const top = Math.round(rects[0].top);
if (lastTop !== null && top !== lastTop) {
lines.push(i - lineStart);
lineStart = i;
}
lastTop = top;
}
lines.push(text.length - lineStart);
return lines;
}
const counts = charsPerLine(document.querySelector("p"));
console.log(counts);This works only when the paragraph is a single text node with no inline elements such as links or emphasis. If your paragraph contains child elements, the function reads only the first text node, so test it on plain paragraphs.
A diagram of the trade-off
The figure shows what happens to reading as the line gets longer or shorter.
Common errors
Most measure problems come from a few repeated mistakes.
- Letting text span the full window. A paragraph with no width limit on a wide monitor can reach 150 or more characters per line. This is the most common failure on the web.
- Setting the width in pixels and forgetting the type size. Raising the font size afterward changes the character count without anyone noticing.
- Judging from placeholder text. Lorem ipsum has unusual word lengths. Check with real content.
- Applying one value everywhere. A caption, a sidebar, and an article body need different measures.
- Limiting the paragraph but not its container. If the heading and image span the full width but the text sits in a narrow column, the layout can look unbalanced. Limit the text, not necessarily the whole page.
Edge cases
Some situations push the measure outside the usual range, and the right response depends on the cause.
- Very narrow screens. On a phone, a 16px font may fit only 35 to 40 characters across the screen. This is acceptable. Do not shrink the font to reach 45. Readability of the type size takes priority over the character count.
- Very wide screens. Do not let text stretch to fill the space. Cap the line with
max-widthand let the extra space be margin. - Languages other than English. Languages with longer average words, such as German, fill a line with fewer words even though the character count is the same. The character-based range still applies. Chinese, Japanese, and Korean text is counted differently because each character is wider, so a line of about 25 to 40 characters is common.
- Large type. A lead paragraph set larger than body text often holds fewer characters per line at the same width. Use a narrower or proportional width so that its count stays reasonable.
- Indented or bulleted text. Indents reduce the available width. Count the lines inside the list, not the full container.
Putting it together
A good approach is to start from the type size, decide the character target, and then express the width in a unit that follows the type. After that, verify by counting real lines. The following example sets different measures for article text and captions.
.article p {
font-size: 1.125rem;
max-width: 66ch;
}
.caption {
font-size: 0.875rem;
max-width: 45ch;
}The article text is a little larger and holds about 66 characters of the "0" width. The caption is smaller and narrower. Both stay inside their own comfortable ranges.
Summary of decisions
- Use characters per line, not pixels, to describe the measure.
- Aim for 45 to 75 characters for single-column body text, with about 66 as a classic target.
- Use roughly 40 to 50 for multi-column layouts and shorter ranges for captions.
- Prefer a
ch-basedmax-width, then verify against real text. - On small screens, keep the type readable even if the line falls below 45 characters.
Exercise
A paragraph at 16px is set in a 900px-wide container with no max-width. Real lines count about 130 characters. (1) Is this inside the comfortable range? (2) Give a CSS rule that brings it into range, and say why a ch-based value is better than a fixed pixel width here.
Show answer
(1) No. 130 characters is well above the 45 to 75 range, so the eye will struggle to find the start of the next line. (2) Use p { max-width: 65ch; }. The ch unit follows the font size, so if the type later grows from 16px to 20px, the line still holds about the same number of characters. A pixel width of, say, 600px would hold fewer characters at 20px and more at 14px, which silently moves the measure out of range.
Exercise
On a phone, your body text at 16px fits about 38 characters per line. A colleague suggests dropping the font to 12px to reach 50. What do you recommend and why?
Show answer
Keep the 16px type. A line of 35 to 40 characters on a narrow screen is acceptable, and readable type size matters more than hitting the character range. A 12px font is hard to read on a small display, so the gain in line length would cost more than it gives.