COL (<col>) Tag

by Jai 10-Jun-19

0 262

<col> tag is used to specify common column properties for each column inside <colgroup> element in a table. if you want to apply style rules to a specific column cell, you have to go with individual style. The <col> tag is written as <col> (no end tag). You can also use the span attribute to specify the number of columns to span.

In HTML <col> tag does not require a closing tag but in XHTML it require a closing </col> tag.

Browsers Support:

Google Chrome
Internet Explorer

COL (<col>) Tag

COL (<col>) Tag

COL (<col>) Tag

COL (<col>) Tag


<!DOCTYPE html>
<title>The Col Tag</title>
table, td, th {
border: 2px solid gray;
border-collapse: collapse;}
<h2>Example of Col Tag</h2>
<p><b>Note:</b> In HTML col tag does not require closing tag but in XHTML it requires closing tag</p>
<table width="450">
<col span="2" style="background-color:red">
<col style="background-color:yellow">
<th>Sr. No.</th>


COL (<col>) Tag


Discount Coupons

SEMRush FREE Trial – PRO Account for 14 Days

FREE Pro Account worth $99.95 for 14 Days.


    Waiting for your comments

Leave a Reply