Your English UI fits perfectly. The button says "Download", the card title sits on one line, and the sidebar looks tidy.
Then someone switches the language.
German turns "Download" into "Herunterladen". A short settings label becomes a full sentence. Chinese may take less horizontal space, but it breaks lines by different rules — and if your font falls back mid-sentence, the whole paragraph suddenly changes height.
This is not a translation problem. It is a layout and font problem, and you can test for it before your users find it.
Why translated text changes size
A useful rule of thumb: expect many European languages to expand English strings by roughly 30–40%, especially for short UI labels. Short strings expand the most, because there is no room to abbreviate.
Three things change at once:
- Length — words get longer, or a compact English phrase needs several words in another language.
- Line breaking — Chinese and Japanese do not break lines at spaces the way English does, and some words in German or Finnish resist breaking at all.
- Font metrics — if a character is missing from your first font, the browser quietly substitutes another font for just that character. The substitute may be taller, wider, or heavier, so one line grows while its neighbours do not.
That third point is the one developers miss. The layout did not break because the translation was long. It broke because two fonts with different metrics ended up sharing one line.
Rule 1: Never give UI text a fixed height
Fixed heights are where expansion goes to die.
/* Fragile */ .button { height: 36px; overflow: hidden; } /* Resilient */ .button { min-height: 36px; padding-block: 0.5rem; white-space: normal; } Let buttons, tabs, chips, and table headers grow vertically. A two-line button in German looks far better than a one-line button with the end of the word cut off.
The same applies to cards: design for the tallest plausible content, not the English content you happen to have today.
Rule 2: Test with pseudo-localization, not hope
You do not need finished translations to find expansion bugs. Pseudo-localization stretches your existing strings and wraps them in markers, so long text and missing characters show up immediately.
A simple version in JavaScript:
const pseudo = (str) => `[${str.replace(/[aeiou]/gi, (c) => c + c)} ${"·".repeat(Math.ceil(str.length / 3))}]`; console.log(pseudo("Download report")); // [Doownlooaad reepoort ·····] Run your app in this mode and click through the main flows. Anywhere text is clipped, overlaps, or pushes an icon off-screen is a bug you just found for free — before paying for a single translated word.
Rule 3: Check your font stack per language, not per page
A font stack that works for English may silently fail for another script. Before shipping a language, test three strings in your actual UI font:
- A long, unbreakable word (German compound nouns are a good stress test)
- A mixed string: Latin brand names inside a Chinese or Japanese sentence
- Punctuation and numbers in the target language, not copied from English
Preview candidate fonts side by side with your own test strings — a font comparison tool makes this quick — and look specifically at line height and character width, not just whether the font "looks nice". If the fallback font is noticeably taller, your paragraphs will ripple every time the script changes.
Also set lang attributes correctly. Browsers use them to pick line-breaking rules and font fallbacks:
<p lang="de">Die Datei wurde heruntergeladen.</p> <p lang="zh-CN">文件已下载完成。</p> Without lang, the browser guesses — and it guesses using your page's default language, not the string's.
Rule 4: Let text wrap the way the language wants
Two CSS properties prevent most of the ugly cases:
.label { overflow-wrap: anywhere; /* last resort for unbreakable strings */ } .prose:lang(zh), .prose:lang(ja) { line-break: strict; word-break: normal; } Use overflow-wrap: anywhere sparingly — on labels, URLs, and table cells — not on body copy, where it can split words in places readers find jarring.
And never justify CJK body text the way you justify English. Justification stretches the spaces between characters, and in a script without word spaces it produces uneven, gappy lines that are harder to read.
A 10-minute pre-launch checklist
Before adding any new language, run through this list:
- [ ] Pseudo-localize the top 5 screens and fix every clipped label
- [ ] Remove fixed heights from buttons, tabs, and nav items
- [ ] Confirm your font actually covers every script you ship — no silent fallbacks mid-sentence
- [ ] Set
langon every translated block, including mixed-language pages - [ ] Test one long German string, one Chinese paragraph, and one mixed-script sentence at mobile width
- [ ] Check numbers, dates, and punctuation in the target language's own format
The takeaway
Internationalization bugs rarely look like internationalization bugs. They look like a button that wraps, a card that overflows, or a paragraph where one line is mysteriously taller than the rest.
Design for expansion, test with pseudo-localization, and treat your font stack as part of the layout system — not decoration added at the end. Your German and Chinese users will never notice. That is exactly the point.
Have a favourite pseudo-localization horror story — a label that overflowed in exactly the wrong place? I'd love to hear it in the comments.