How to Make a Sticky Footer

You can make the footer stick to the bottom no matter how big the screen resolution is. All you have to do is just follow the HTML mark up as shown in the code snippet.  It works in all the major browsers. IE 5 up, Mozilla, Chrome, Safari, Opera.


<link rel="stylesheet" href="layout.css" ... />
<div class="wrapper">
<p>Your website content here.</p>
<div class="push"></div>
<div class="footer">
<p>Copyright (c) 2008</p>


* {
margin: 0;
html, body {
height: 100%;
.wrapper {
min-height: 100%;
height: auto !important;
height: 100%;
margin: 0 auto -4em;
.footer, .push {
height: 4em;

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s