How to make paragraph text italic in HTML

What is HTML Italic Element?

In HTML, <i> (italic) element is used to display text in italic style in a webpage.

The italic element is purely presentational; it doesn't carry any specific semantic meaning on its own.

Example of Creating HTML Italic Text

Create an HTML <i> element in a <p> element.

Place the text 'an example of HTML italic text.' between the <i> and </i> tags as shown in the following example.

The text will be displayed in italic style in the output.

Example of HTML Italic Element


Output of the above example

Example of Italic Text


This is an example of HTML italic text.

<i> tag is used to display bold text


What is HTML Emphsis Element?

In HTML, <em> (strong) element is used to apply italic style with emphasis in related to the meaning of the text.

The emphasis element also indicates that the enclosed text is of importance from a semantic standpoint.

It is best practice to use the <em> element instead of <i> when the emphasis is related to the meaning of the text.

In the following example, the text 'consectetur adipiscing elit.' is enclosed with <em> element tag. The text will be display in italic style in the output.


Output of the above example

Example of Emphasis Text


Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla convallis, arcu et consequat condimentum

<em> tag is used to display italic text with emphasis

Live Code Playground

In the following HTML code editor, you can practice the above code by creating more new HTML italic and emphasis elements. Click on the 'Run Code' button to render the code; the rendered page will be displayed in the following HTML Code Output frame. Practice until you become comfortable and proficient with your code.

HTML logo HTML Online Editor
HTML Code Output