HTML <tbody> valignAttributes
Examples
Align the content in the <tbody> element vertically to the bottom:
<table border="1"
width="100%">
<tr>
<th>Month</th>
<th>Savings</th>
</tr>
<tbody valign="bottom">
<tr>
<td>January</td>
<td>$100</td>
</tr>
<tr>
<td>February</td>
<td>$80</td>
</tr>
</tbody>
</table>
<tr>
<th>Month</th>
<th>Savings</th>
</tr>
<tbody valign="bottom">
<tr>
<td>January</td>
<td>$100</td>
</tr>
<tr>
<td>February</td>
<td>$80</td>
</tr>
</tbody>
</table>
Try it yourself »
Browser Support
![]()
![]()
![]()
![]()
![]()
All major browsers support the valign attribute.
Definition and Usage
HTML5 does not support the <tbody> valign attribute. Please use CSS instead.
The valign attribute specifies the vertical alignment of the content in the <tbody> element.
Syntax
<tbody valign="top|middle|bottom|baseline">
Attribute Values
| Value | Description |
|---|---|
| top | Aligns the content to the top. |
| middle | Aligns the content to the middle (default value). |
| bottom | Aligns the content to the bottom. |
| baseline | Aligns with the baseline. The baseline is an imaginary line. In a line of text, most letters are based on the baseline. The baseline value sets all table data in the row to share the same baseline. The effect of this value is often the same as the bottom value. However, if the font sizes of the text differ, the baseline effect will be better. See the illustration below. |
Illustration of bottom vs. baseline when text font sizes differ:
valign="bottom"
valign="baseline"
HTML <tbody> tag Other Extensions