HTML: Marquee, Scrolling Text
What is Marquee Element
Marquee Element is used to make text or images to automatically scroll, typically in a horizontal strip.
Marquee Element is invented by Microsoft Internet Explorer browser around 1995.
HTML Marquee Example
Code
<marquee>The BOSS IS ON A ROLL</marquee>
Marquee Element Attributes
loop-
integer. Number of times to loop. “-1” means forever. Default value is “-1”
direction-
left(default)rightupdown
behavior-
value is one of
scroll→ move right to left, then loop (default)slide→ slide to left then stop.alternate→ move side to side.
scrolldelay-
- update interval for scroll movement, in milliseconds.
- Default is 85.
- Smaller than 60 is ignored, 60 is used instead, unless truespeed is specified.
truespeed-
see scrolldelay. This is not well supported.
scrollamount="6"-
amount of scrolling update, in pixels.
hspace="30"-
horizontal margin
vspace="10"-
vertical margin
width="600"-
width in pixel.
height="40"-
width in pixel.
bgcolor-
CSS color value. 〔see CSS: Color Syntax〕
Browser Support
- 2025-04-24
- Supported by Google Chrome.
- Not supported by Firefox.
CSS Marquee
You can emulate marquee using CSS animation.