Learn HTML Coding, Web page Designing using HTML, HTML5 Tags, HTML Tutorial for Beginners

How to use Paragraph <p> tag in html

In this tutorial we learn how o use <p> p tag for creating paragraph in html page.

Conceptually <p> works just like how we consider paragraph, it takes the width of container, but we can do lot more with p tag in html page designing.

Html P Tag Example

Let's learn using example

This is an example of paragraph in html, we are learning p tag in html document.  This is an example of paragraph in html, we are learning p tag in html document

Now if you notice where line break happens in paragraph, take full with of container, so if you need a line break in particular position use <br> tag

How to set paragraph font size and line height

Paragraph has a default font size, color and line height, but you can change all defaults value in your web application just by setting standard properties value in your css style sheet file.

You can write something like this in your application CSS file, Note: this is not a class, default property of all paragraph in your application, this is how we can set css property on any html element, here for paragraph p element.


Alternatively you also can write a class and call them in any p tag you want like this
<p class="className"> here is para content</p>

Now let's see some example where you can use p tag in web page designing, so following post may help you to understand better.


Web Designing Tutorials
HTML Coding Tutorial
digital marketing software

Paragraph p element in html: how to use p tag in html page designing

HTML Tutorial | Join Web Designing Course | HTML5 Introduction