CSS font-style Property

The CSS font-style property defines the font style for a text.

Demo:

Click the "Try it" button to make the paragraph "italic":



This is a paragraph.



Syntax:

font-style: normal|italic|oblique;

normal (default) - the browser displays a normal font style.

italic - the browser displays an italic font style.

oblique - the browser displays an oblique font style.

Example:

<!DOCTYPE html> <html> <head> <style> .normal {   font-style: normal; }  .italic {   font-style: italic; }  .oblique {   font-style: oblique; } </style> </head> <body>  <p class="normal">This is a paragraph (normal).</p> <p class="italic">This is a paragraph (italic).</p> <p class="oblique">This is a paragraph (oblique).</p>  </body> </html>

Output:




This is a paragraph (normal).

This is a paragraph (italic).

This is a paragraph (oblique).



Read also:

CSS Fonts

CSS font-family Property

HTML Quotations