Controlling cell spacing

To add space among a table cells, use the cellspacing property. The following examples show some effects of different cellspacing values:

Examples showing different cell spacing values
0 0
0 0
0 Pixel
1 1
1 1
1 Pixel
5 5
5 5
5 Pixels
10 10
10 10
10 Pixel

To create a table to separate cells by ten pixels, use the following code:

<table width="40" border="1" cellspacing="10">
<tr>
<td>10</td>
<td>10</td>
</tr>
<tr>
<td>10</td>
<td>10</td>
</tr>
</table>