CSS Property outline-width

outline-width sets the width for the overall outline of an element.


Initial value medium
Inherited No.
Version CSS2
JavaScript syntax object.style.outlineWidth="thin"
Applies to All elements.

CSS Syntax

outline-width: length | medium | thick | thin | inherit 

Property Values

The property values are listed in the following table.

Value Description
thin thin outline
mediumdefault value. a medium width outline.
thick a thick outline
length set the thickness of the outline
inherit inherit the width of the outline from the parent element

Browser compatibility

outline-width Yes 8.0 Yes Yes Yes


An example showing how to use outline-width CSS property.

<!DOCTYPE html>
p.one{<!--  w w  w  .  j a  va  2  s. co  m-->
    border:1px solid red;
   <p class="one">This is some text in a paragraph.</p>


Click to view the demo