Creating a Sticky Footer in CSS


Keep the footer at the bottom of the page, even on short pages, with the position: sticky property.

Source Code

.footer {
    position: sticky;
    bottom: 0;
    background-color: #ccc;
}
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments