text-align-last

Determines how the very last line of a block or a line right before a forced line break should be aligned. This is often used to ensure the last line of a justified paragraph is centered or left-aligned.

Quick example

p {
  text-align: justify;
  /* Explicitly centers the last line of the paragraph */
  text-align-last: center;
}

Quick facts

Initial value
auto
Inherited
Yes
Applies to
block containers
Animation type
discrete

Values

autostartendleftrightcenterjustify

text-align-last Browser Support

Widely available Since 2022 95% global usage

This feature is well established and works across many devices and browser versions. It has been available across browsers since 2022.

Safe to use without fallbacks.

47+
49+
16+
12+
ESC