Use the style attribute in HTML to set the CSS style. It is used to set the inline CSS. You can try to run the following code to implement style attribute in HTML −
Example
<!DOCTYPE html> <html> <body> <h2>Tutorialspoint</h2> <p>We provide tutorials.</p> <p style = "color:green">We provide learning videos.</p> </body> </html>