HTML <wbr> tag

Updated: 11/13/2018 by Computer Hope

HTML wbr tagWhen writing in HTML, the <wbr> tag is an inline element that gives the browser an option to break a line in a block of text. It is useful for creating breaks in long words or addresses when a window is resized. The following sections contain information about this tag, including an example of it in use, as well as related attributes and browser compatibility.

Note: The <wbr> element is usually nested within opening and closing <nobr> tags.

Example of <wbr> code

<p>If you shrink the window enough, you should see the following
line break into smaller sections.</p>
<p>Thisisasupersuper<wbr>longword<wbr>thatwillbreak<wbr>ifyou<wbr> justkeepon<wbr>shrinking<wbr>thebrowserwindowuntil<wbr>itgets

Example result

If you shrink the window enough, you should see the followingline break into smaller sections.



Within an HTML tag, an attribute dictates certain aspects of an HTML element. Attributes are made up of a name and value pair. While the <wbr> tag does not have any unique attributes, it does utilize all of the standard attributes.


Edge Internet Explorer Firefox Safari Opera Chrome
All versions Not supported All versions 4.0+ 11.6+ All versions

Address, <br>, Browser, Compatibility, Line break, Web design terms