CSS border-block-end Property

Beginner
5 min read
Updated: Oct 2026
3 examples
Live preview

Definition and Usage

The border-block-end property is a logical shorthand that sets border-block-end-width, border-block-end-style, and border-block-end-color on the block-end edge only.

In the default horizontal writing mode, that edge is the bottom. Change writing-mode, and the same rule can map to a different physical side. For the opposite edge, use border-block-start.

Baseline · Widely available.

Not deprecated and not experimental. Logical border shorthands have been widely available across browsers since early 2020.

CSS Syntax

syntax.css
border-block-end: <line-width> || <line-style> || <color> | initial | inherit;

Same value shape as border, but for one logical edge. A style other than none is required for the line to appear.

Property Values

ValueDescriptionTry it
<line-width>Thickness of the block-end border. Default mediumTry it
solidContinuous line on the block-end edgeTry it
dashedDashed line on the block-end edgeTry it
dottedDotted line on the block-end edgeTry it
With writing-modePhysical edge changes when writing mode is verticalTry it
noneNo block-end border. Initial styleTry it
<color>Color of the block-end border. Default currentColorTry it
initialResets to the initial values (style none)Try it
inheritInherits this property from the parent elementTry it

How to Use border-block-end

Border only the end of the block axis — usually the bottom in English layouts.

  1. Choose the element that needs a line on its block-end edge.
  2. Set a style such as solid or dashed. Without a style, nothing draws.
  3. Add width and color as needed: border-block-end: 3px solid #2563eb;.
  4. If both block sides should match, prefer border-block instead.
PieceRequired?Role
StyleYes (to show a line)Initial style is none
Width and colorOptionalDefaults: medium and currentColor
One edge onlyBy designDoes not style block-start or the inline sides
writing-modeOptionalChanges which physical edge is block-end

Live Preview

Change border-block-end and the writing mode. Only the block-end edge updates.

In horizontal-tb, block-end is the bottom. In vertical-rl, block-end maps to the left edge.

Box

border-block-end: 4px solid #2563eb · writing-mode: horizontal-tb

CSS Examples

Each snippet focuses on border-block-end. Use Try It Yourself for a live editor.

Example 1 — Solid Block-End Border

In horizontal text, this draws a bottom border only.

CSS
<style>
  div {
    border-block-end: 4px solid #2563eb;
    padding: 12px;
  }
</style>

<div>Bottom border only</div>
Try It Yourself

How It Works

  1. Target one edge. border-block-end never paints the other three sides.
  2. Set a visible style. solid is required so a line appears.
  3. Set width and color. 4px and blue apply only to block-end.
  4. Map to physical bottom. With default horizontal-tb, block-end is the bottom edge.

Example 2 — Dashed Block-End Border

Same shorthand shape, different style keyword.

CSS
<style>
  div {
    border-block-end: 3px dashed #dc2626;
    padding: 12px;
  }
</style>

<div>Dashed block-end</div>
Try It Yourself

How It Works

  1. Keep the logical edge. Still only block-end.
  2. Swap the style. dashed replaces the continuous stroke.
  3. Color that edge. Red applies to the end border alone.
  4. Useful for rules. A single end border works well as a section divider under text.

Example 3 — Vertical Writing Mode

Change the writing mode and the same rule maps to a different physical edge.

CSS
<style>
  div {
    writing-mode: vertical-rl;
    border-block-end: 4px solid #0f766e;
    padding: 12px;
  }
</style>

<div>Block-end follows writing mode</div>
Try It Yourself

How It Works

  1. Flip the flow. writing-mode: vertical-rl stacks lines vertically.
  2. Keep the logical border. border-block-end still means the end of the block axis.
  3. Watch the physical map. That edge is no longer the bottom; with vertical-rl it lands on the left.
  4. Why it matters. One logical rule stays correct across writing modes, unlike hard-coded border-bottom.

Edge Cases & Pitfalls

If the border looks wrong, one of these is usually why.

style

No style means no border

border-block-end: 4px #000 still draws nothing because style defaults to none. Include solid or another style keyword.

physical

Not always the bottom

With writing-mode: vertical-rl, block-end maps to the left. border-bottom does not follow that shift.

start

Start is a different property

This shorthand never styles block-start. Use border-block-start, or border-block for both sides.

overlap

Physical and logical can fight

Setting both border-bottom and border-block-end can override each other depending on cascade order. Prefer one model in a component.

longhands

Shorthand resets all three parts

border-block-end: solid also resets width and color to their initial values for that edge. Set color after the shorthand if you need a custom color.

Browser Support

border-block-end is a browser CSS property for logical borders. Node.js, Deno, and Bun do not apply it.

✓ Baseline · Widely available

border-block-end

Chrome 69+, Edge 79+, Firefox 41+, Safari 12.1+. Internet Explorer has no support.

97% Modern browser support
Google Chrome 69+
Full support
Mozilla Firefox 41+
Full support
Apple Safari 12.1+
Full support
Microsoft Edge 79+
Full support
Opera 56+
Full support
Samsung Internet 10+
Full support
Internet Explorer No support
Not supported
border-block-end Widely supported

Bottom line: Safe for modern browsers. Fall back to border-bottom only when you must support Internet Explorer and stay in horizontal writing modes. It is not a runtime API.

Key Takeaways

  • Role: one shorthand for width, style, and color on the block-end edge only.
  • Logical mapping: usually the bottom; can move with vertical writing modes.
  • Not border-bottom: physical bottom never follows writing mode.
  • Style required. Not inherited. Pair with border-block-start when both ends differ.

One line: border-block-end: 4px solid blue; draws a matching rule on the block-end edge — wherever that edge points.

Frequently Asked Questions

It is a shorthand that sets border-block-end-width, border-block-end-style, and border-block-end-color on the logical block-end edge only.
A border needs a visible style. The initial style is none, so width or color alone will not draw a line. Use solid, dashed, or another style.
border-bottom always means the physical bottom edge. border-block-end follows writing-mode, so in horizontal text it is usually the bottom, and in vertical text it can map to a different physical side.
It sets border-block-end-width, border-block-end-style, and border-block-end-color in one declaration.
Use border-block-start for the block-start side, or border-block to style both block sides the same.
It is Baseline Widely available. Chrome 69+, Edge 79+, Firefox 41+, and Safari 12.1+ support it. Internet Explorer does not. It is a browser CSS property, not a Node.js feature.

Next: border-block-end-color

Set only the color of the block-end border without touching width or style.

border-block-end-color tutorial →

CODETOFUN NEWS

Stay Ahead in Tech

Get the latest IT news, programming updates, and technology trends directly on your phone.

Your daily dose of tech, straight to your feed.

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

8 people found this page helpful