
- HTML - Home
- HTML - Roadmap
- HTML - Introduction
- HTML - History & Evolution
- HTML - Editors
- HTML - Basic Tags
- HTML - Elements
- HTML - Attributes
- HTML - Headings
- HTML - Paragraphs
- HTML - Fonts
- HTML - Blocks
- HTML - Style Sheet
- HTML - Formatting
- HTML - Quotations
- HTML - Comments
- HTML - Colors
- HTML - Images
- HTML - Image Map
- HTML - Frames
- HTML - Iframes
- HTML - Phrase Elements
- HTML - Code Elements
- HTML - Meta Tags
- HTML - Classes
- HTML - IDs
- HTML - Backgrounds
- HTML Tables
- HTML - Tables
- HTML - Table Headers & Captions
- HTML - Table Styling
- HTML - Table Colgroup
- HTML - Nested Tables
- HTML Lists
- HTML - Lists
- HTML - Unordered Lists
- HTML - Ordered Lists
- HTML - Definition Lists
- HTML Links
- HTML - Text Links
- HTML - Image Links
- HTML - Email Links
- HTML Color Names & Values
- HTML - Color Names
- HTML - RGB & RGBA Colors
- HTML - HEX Colors
- HTML - HSL & HSLA Colors
- HTML - HSL Color Picker
- HTML Forms
- HTML - Forms
- HTML - Form Attributes
- HTML - Form Control
- HTML - Input Attributes
- HTML Media
- HTML - Video Element
- HTML - Audio Element
- HTML - Embed Multimedia
- HTML Header
- HTML - Head Element
- HTML - Adding Favicon
- HTML - Javascript
- HTML Layouts
- HTML - Layouts
- HTML - Layout Elements
- HTML - Layout using CSS
- HTML - Responsiveness
- HTML - Symbols
- HTML - Emojis
- HTML - Style Guide
- HTML Graphics
- HTML - SVG
- HTML - Canvas
- HTML APIs
- HTML - Geolocation API
- HTML - Drag & Drop API
- HTML - Web Workers API
- HTML - WebSocket
- HTML - Web Storage
- HTML - Server Sent Events
- HTML Miscellaneous
- HTML - Document Object Model (DOM)
- HTML - MathML
- HTML - Microdata
- HTML - IndexedDB
- HTML - Web Messaging
- HTML - Web CORS
- HTML - Web RTC
- HTML Demo
- HTML - Audio Player
- HTML - Video Player
- HTML - Web slide Desk
- HTML Tools
- HTML - Velocity Draw
- HTML - QR Code
- HTML - Modernizer
- HTML - Validation
- HTML - Color Picker
- HTML References
- HTML - Cheat Sheet
- HTML - Tags Reference
- HTML - Attributes Reference
- HTML - Events Reference
- HTML - Fonts Reference
- HTML - ASCII Codes
- ASCII Table Lookup
- HTML - Color Names
- HTML - Character Entities
- MIME Media Types
- HTML - URL Encoding
- Language ISO Codes
- HTML - Character Encodings
- HTML - Deprecated Tags
- HTML Resources
- HTML - Quick Guide
- HTML - Useful Resources
- HTML - Color Code Builder
- HTML - Online Editor
HTML - <footer> Tag
Introduction to the <footer> Tag
The HTML <footer> tag is used to specify the footer for its nearest preceding document or section. Generally, the footer element contains information about the author of the section or document, copyright data, or links to related documents
The <footer> element does not divide content and therefore does not introduce a new section in the outline. We can also use the <img> and <video> elements within the <footer> tag to specify the footer images and videos.
Syntax
Following is the syntax of <footer> tag −
<footer>.....</footer>
Attributes
The HTML <footer> tag supports both Global and Event attributes.
Example: Creating a Footer Section
In following example showing the usages the HTML <footer> tag to create a website's footer section. This HTML code lists fronted technologies and includes a footer with copyright information for "fronted technologies" in 2023.
<!DOCTYPE html> <html lang="en"> <head> <title>HTML footer tag</title> </head> <body> <h1>Following are list of the frontend technologies.</h1> <ul> <li>HTML</li> <li>CSS</li> <li>JavaScript</li> <li>Bootstarp</li> <li>Angular</li> <li>React</li> </ul> <footer> <small>Copyright © frontend technologies 2023.</small> </footer> </body> </html>
Example: Styling Footer using CSS
Consider the following example, where we use the <footer> tag and apply CSS properties. This HTML code styles a footer and a navigation with the list items, links, and a centered, styled footer section.
<!DOCTYPE html> <html lang="en"> <head> <title>HTML footer tag</title> <style> footer { width: 92%; margin: auto; background-color: rgb(7, 7, 114); color: white; text-align: center; padding: 10px; border-radius: 10px; position: relative; top: 100px; } ol li { list-style: none; display: inline; width: 100px; } ol li a { text-decoration: none; background-color: aquamarine; padding: 10px; border-radius: 5px; } </style> </head> <body> <nav> <ol> <li> <a href="">HOME</a> </li> <li> <a href="">BLOG</a> </li> <li> <a href="">ContactUs</a> </li> <li> <a href="">About</a> </li> </ol> </nav> <footer> copyright © 2023. </footer> </body> </html>
Example: Adding Image to a Footer
In this example, the <img> tag is used within the <footer> tag to include an image in the footer of the HTML code creates a centered footer containing a logo image and copyright text.
<!DOCTYPE html> <html lang="en"> <head> <title>HTML footer tag</title> <style> footer { width: 90%; margin: auto; padding: 5px; height: 50px; border: 2px solid black; text-align: center; } footer>img { width: 200px; position: relative; top: 15px; } </style> </head> <body> <h2>'footer' tag with the img element example</h2> </nav> <footer> Copyright <img src= "https://www.tutorialspoint.com/static/images/logo.png?v3" alt="logo"> © 2023 </footer> </body> </html>
Example: Adding a GIF to a Footer
Let's consider another scenario, where we use the <img> tag within the <footer> tag to include a GIF in the footer of an HTML document or section.
<!DOCTYPE html> <html lang="en"> <head> <title>HTML footer tag</title> <style> footer { width: 90%; margin: auto; height: 50px; border: 2px solid black; text-align: center; } footer>img { width: 10px; height: 10px; position: relative; top: 5px; border: 5px solid black; } </style> </head> <body> <h2>'footer' tag with the img(type GIF) element example</h2> </nav> <footer> Copyright <img src="/html/images/rotate.gif" alt=""> © 2023 </footer> </body> </html>
Supported Browsers
Tag | ![]() |
![]() |
![]() |
![]() |
![]() |
---|---|---|---|---|---|
footer | Yes 5.0 | Yes 9.0 | Yes 4.0 | Yes 5.0 | Yes 11.1 |