The text-justify property sets how justification works when text-align: justify is set. It chooses whether extra space goes mainly between words or between characters.
It is inherited. The initial value is auto. Without text-align: justify, this property has no visible effect.
Limited availability Not Baseline
Supported in Firefox and recent Chromium. Safari does not support it. Treat it as progressive enhancement, not a hard layout requirement.
Deprecated Prefer inter-character over distribute
distribute matches inter-character and exists only for older content. Use inter-character in new CSS.
Justify the text first, then choose the spacing method.
Set text-align: justify on the block.
Choose inter-word for space-separated languages, or inter-character for character-based scripts.
Leave auto when you want the browser to decide.
Tag the language with lang so auto can pick better rules.
Piece
Required?
Role
text-align: justify
Yes
Turns justification on
text-justify keyword
Yes (to choose method)
How extra space is distributed
Language tag
Recommended
Helps auto pick a suitable algorithm
Fallback plan
Recommended
Safari and older Chromium may ignore the method
Try it
Live Preview
The sample is already justified. Change the method and compare spacing. In unsupported browsers, values may look the same.
Requires text-align: justify (already set). Differences are clearest in Firefox and recent Chromium.
Justification preview
An example of justified English text used to compare spacing methods for the text-justify property.
text-justify: auto
Code
CSS Examples
Each snippet focuses on text-justify and includes text-align: justify so the method can apply. Use Try It Yourself for a live editor.
Example 1 — Space Between Words
Best default for English and other space-separated languages.
CSS
<style>
p {
text-align: justify;
text-justify: inter-word;
}
</style>
<p>An example of justified English text used to compare spacing methods for the text-justify property.</p>
Justification opportunities are turned off for this paragraph.
Useful in user stylesheets for readability or accessibility tweaks.
How It Works
Keep the align value. You do not have to remove justify from the cascade.
Set none. No justification opportunities are used.
Effectively left-aligned lines. Full lines no longer stretch with extra gaps.
Toggle friendly. Handy when a parent sets justify and a child must opt out.
Edge Cases & Pitfalls
If nothing changes, one of these is usually why.
align
Needs text-align: justify
Without justified alignment, text-justify does not create stretched lines.
support
Safari ignores it today
Layout must still look fine with the browser’s default justify behavior alone.
lang
Language tags help auto
Mark content with lang. Justification quality is language-sensitive.
legacy
Skip distribute in new CSS
It is a deprecated alias of inter-character. Prefer the modern keyword.
last
Last line is separate
Control the final line with text-align-last. text-justify does not replace that.
Compatibility
Browser Support
text-justify is a browser layout property. Node.js, Deno, and Bun do not apply it.
✓ Limited availability · Not Baseline
text-justify
Firefox has long supported it. Chromium enabled it around version 145. Safari still lacks support.
71%Global support (approx.)
Google Chrome145+
Full
Mozilla Firefox55+
Full
Apple SafariNo
None
Microsoft Edge145+
Full
Opera131+
Full
Samsung InternetLimited
Partial
Internet ExplorerPartial
Partial
text-justifyLimited
Bottom line: Use as progressive enhancement. Justified text with text-align: justify still works everywhere; the method keyword may not.
Remember
Key Takeaways
Role: choose the justification method when text is justified.
Common values:auto, inter-word, inter-character, none.
Requires:text-align: justify. Initial value is auto. Inherited.
Support: limited. Not Baseline. Avoid depending on it for critical layout.
One line:text-justify decides whether justified lines stretch between words or between characters.
Frequently Asked Questions
It chooses how space is distributed when text is justified. It only applies when text-align is set to justify.
The initial value is auto. The browser picks a method based on language and quality versus performance.
Yes. Without text-align: justify, changing text-justify has no visible effect.
inter-word adds space between words and suits languages that use spaces, such as English. inter-character adds space between characters and suits languages such as Japanese.
distribute is a deprecated alias of inter-character, kept for older content. Prefer inter-character in new CSS.
Support is limited: Firefox 55+, Chrome/Edge 145+, and Opera around 131+. Safari does not support it. It is a browser layout property, not a Node.js feature.