<style> tag in HTML

The <style> tag is used to defines CSS style information in the HTML document.

Important Description

  • Open and close tag required of <style>.
  • To link an external style sheet in HTML page, then use <link> tag.
  • The <style> tag can contain the multiple <style> tags in each HTML document.

Example of <style> tag

Result Look Like

This is a heading

This is a paragraph of style tag example.

<style> Tag Browser Support

Element Chrome Edge Firefox Safari Opera
<style> Yes Yes Yes Yes Yes

Global Attributes

Event Attributes

Attributes

Attribute Value Description
media media_query Media attribute defines what media/device the media resource is optimized for
type type/css Specifies the media type of the <style> tag

Email Us: advertise@gdatamart.com

Donate Us: Support to GDATAMART

© 2023 GDATAMART.COM (All Rights Reserved)