stroke-width
Widely available across major browsers

Chrome 80, Chrome Android 80, Edge 80, Firefox 1, Firefox Android 4, Opera 67, Safari 13.1, Safari iOS 13.4

Baseline since 2020

The stroke-width attribute is a presentation attribute defining the width of the stroke to be applied to the shape. It applies to any SVG shape or text-content element, but as an inherited property, it may be applied to elements such as <g> and still have the intended effect on descendant elements' strokes.

Note: As a presentation attribute, stroke-width also has a CSS property counterpart: stroke-width. When both are specified, the CSS property takes priority.

You can use this attribute with the following SVG elements:

By Mozilla Contributors, CC BY-SA 2.5