| Viewed 443 times

How to create a table in HTML

How to create a table in HTML

1 Answer
Mikdam Qandeel

First of all, you have to Define an HTML Table

and we define it with the <table> tag.

Then, we know that any table consists of columns and rows, But HTML table is always based on rows, never columns.
so the row is defined with the <tr> tag.

A table header is defined with the <th> tag. And by default, the table headings are bold and centered.

A table data/cell is defined with the <td> tag.


<table style="width:100%">


Country Capital continent
Jordan Amman Asia
Palestine Al-Quds Asia

Related Questions