-webkit-text-stroke-color

Sets the color of the outline (stroke) around text characters. Best used with a large font size to ensure the text remains readable.

It is documented as part of the WebKit Extensions specification.

/* Usage Example */
h1 {
  -webkit-text-stroke-color: #7c3aed;
  -webkit-text-stroke-width: 2px;
  color: transparent;
  font-size: 4rem;
}

/* Global values */
-webkit-text-stroke-color: inherit;
-webkit-text-stroke-color: initial;
-webkit-text-stroke-color: revert;
-webkit-text-stroke-color: revert-layer;
-webkit-text-stroke-color: unset;
Widely available Since 2017 96% global usage

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

1+
49+
3+
15+
Kinsta

Your first month is free

Managed WordPress hosting for faster sites.

Learn more

New CSS drops.

Join 600+ readers who've survived clearfix hacks.

ESC