How to apply inline CSS ? Last Updated : 09 May, 2023 Comments Improve Suggest changes Like Article Like Report In this article we will learn how to apply inline CSS, Inline CSS contains the CSS property in the body section attached to the element is known as inline CSS. This kind of style is specified within an HTML tag using the style attribute. It is used to apply a unique style to a single HTML element. Syntax: <tag style = " "></tag> Example 1: Here is the basic example of using inline CSS. HTML <!DOCTYPE html> <html> <body> <p style="color: #009900; font-size: 50px; font-style: italic; text-align: center;"> GeeksForGeeks </p> </body> </html> Output: Example 2: Here is the demonstration of inline CSS. HTML <!DOCTYPE html> <html> <body> <h2 style="color: green; background: yellow"> Geeks For Geeks </h2> <p style="color: black"> Happy Preparation!!. </p> </body> </html> Output: Comment K knockpit Follow Improve K knockpit Follow Improve Article Tags : Web Technologies CSS CSS-Basics CSS-Questions Explore CSS Introduction 3 min read CSS Syntax 2 min read CSS Selectors 6 min read CSS Comments 2 min read CSS Colors 5 min read CSS Borders 5 min read CSS Margins 4 min read CSS Height and Width 4 min read CSS Outline 4 min read CSS Fonts 4 min read Like