Non-standard
This feature is non-standard and is not on a standards track. Do not use it on production sites facing the Web: it will not work for every user. There may also be large incompatibilities between implementations and the behavior may change in the future.
Obsolete This feature is obsolete. Although it may still work in some browsers, its use is discouraged since it could be removed at any time. Try to avoid using it.
<spacer> is an obsolete HTML element which allowed insertion of empty spaces on pages. It was devised by Netscape to accomplish the same effect as a single-pixel layout image, which was something web designers used to use to add white spaces to web pages without actually using an image. However, <spacer> no longer supported by any major browser and the same effects can now be achieved using simple CSS.
Firefox, which is the descendant of Netscape's browsers, removed support for <spacer> in version 4.
Attributes
Like all other HTML elements, this element supports the global attributes.
type
This attribute determines type of spacer. Possible values are horizontal, vertical and block.
size
This attribute can be used for defining size of spacer in pixels when type is horizontal or vertical.
width
This attribute can be used for defining width of spacer in pixels when type is block.
height
This attribute can be used for defining height of spacer in pixels when type is block.
align
This attribute determines alignment of spacer. Possible values are left, right and center.
Example
<span>Just a text node</span><spacertype="horizontal"size="10"></spacer><span>Just another text node</span><spacertype="block"width="10"height="10"></spacer>1234
Specification
Not part of any specification.
Browser compatibility
The compatibility table in this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request.
Our goal is to provide accurate, real values for all our compatibility data tables. Notifying MDN of inaccurate data or supplying new data pushes us further towards our goal of providing 100% real values to the developer community. Thank you for helping.
1Which browsers are affected?
Please select the browser or browsers which are affected.
Chrome
Edge
Firefox
Internet Explorer
Opera
Safari
Android webview
Chrome for Android
Firefox for Android
Opera for Android
Safari on iOS
Samsung Internet
2Which table row is affected?
3Can you provide a brief explanation?
Briefly outline the issue you are highlighting. Minimum 10 and maximum 1,000 characters.
4Do you have any supporting material?
Optional
Browser documentation and release notes are good supporting items to accompany your message. A demo hosted on services like Codepen or JSBin are perfect for providing real examples of your findings.
Connection error:Sorry, we can’t seem to reach the server. We are working to fix the problem. Please try again later.