HTML <tfoot> tag

HTML <tfoot> tag is used to define the set of rows which represents footer of an HTML table. The <tfoot> tag must contain one or more <tr> element.

The <tfoot> tag is used as a child element of HTML table (<table>) along with <thead> and <tbody> elements, where <thead> defines table header and <tbody> defines the table body.

Tips: The <thead>, <tbody>, and <tfoot> elements do not affect the table layout, and if you want to apply the change in table layout then use CSS properties.

Syntax

Following are some specifications about the HTML <tfoot> tag

DisplayNone
Start tag/End tagStart and End tag
UsageHTML Tables

Example

Test it Now

Output:

HTML tfoot tag

Attribute:

Tag-specific attributes:

AttributeValueDescription
alignright
left
center
justify
char
It determines the alignment of the content inside the <tfoot> element. (Not Supported in HTML5)
charCharacterIt specifies the alignment of the content inside the <tfoot> element to the character. (Not Supported in HTML5)
charoffNumberIt specifies the number of characters the content will be aligned from the character specified by the char attribute. (Not Supported in HTML5)
valigntop
middle
bottom
baseline
It determines the vertical alignment of the content inside the <tfoot> element. (Not Supported in HTML5)

Global attribute:

The <tfoot> tag supports the Global attributes in HTML.

Event attribute:

The <tfoot> tag supports the Event attributes in HTML.

Supporting Browsers

Elementchrome browser Chromeie browser IEfirefox browser Firefoxopera browser Operasafari browser Safari
<tfoot>YesYesYesYesYes
Next TopicHTML th Tag




Latest Courses