Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

HTML table cellpadding attribute

HTML

HTML table Tag Reference HTML

The cellpadding attribute
tag

Example

Set the spacing between the cell edges and the cell content to 10 pixels:

Month Savings
January $100

Try it »


Browser support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the cellpadding attribute.


Definition and Usage

HTML5 does not support

The cellpadding attribute specifies the space between the cell edges and the cell content, in pixels.

**Note:** Do not confuse this attribute with cellspacing the attribute; the cellspacing attribute specifies the space between cells.

**Tip:** From a practical standpoint, it is best not to specify cellpadding, but to use CSS to add padding (inner spacing).


Syntax

the cellpadding attribute. Please use CSS instead.
HTML

tag