Table Border

The HTML Table Border attribute sets the width of Border around the table and table cells. We can set the Border attributes in pixels.

In the above HTML code we set the Border attribute to 2, this applies a border to each cell, and to the table as a whole. But whatever values you to set in the Border attribute, only the size of the border around the table will change, the border of the table cells remain 1 pixel width.


HTML Source Code :

In the above HTML code we set border=5 , you can see only the Border around the table will change the size to 5 , but cells border inside the table will remain 1 pixel.

HTML Table Bordercolor

The bordercolor attribute will change the color of the border around your table. You can directly type the color names or you can use hexadecimal codes of colors to Boardercolor attribute.


You can set additional two border color attributes to HTML Table, they are bordercolorlight and bordercolordark attributes. It will give you a 3D effect to your HTML Table.


Table with no Border

By default there is no border around HTML Table and Table Cells. If you want to hide (No Border) Border permanently, you can set this property to either 0 or -1 .