Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7617409
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T03:08:39+00:00 2026-05-31T03:08:39+00:00

I have a fluid layout but as a consequence, when there is no enough

  • 0

I have a fluid layout but as a consequence, when there is no enough content in the page, my footer keeps moving up as in this example.

enter image description here

A popular solution to keep the footer at the bottom of the page is using position: fixed or position: absolute, however, when I do that, the content can collide with the footer on resizing (you can see what I mean here. Try to resize your window to the point in which the text is hiding behind the footer).

enter image description here

So how can I get a footer at the bottom but moving accordingly with the rest of the page in a fluid layout?

Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T03:08:40+00:00Added an answer on May 31, 2026 at 3:08 am

    There’s a CSS way to do this. Or at least there’s one that works for all the browsers I support (back to IE7).

    I use the negative margin-top trick to stick the footer to the bottom of the page. That DIV is wrapped around the entire page contents instead of just the header, which suffices for most people. Let’s say that DIV has a class “everything-but-the-footer”. I then force the page to be at least window height. Full version that works on most browsers:

    html, body, .everything-but-the-footer {
        height: 100%;
    }
    
    .everything-but-the-footer {
        margin-top: -21px; // footer height + border * -1
        min-height: 100%
    }
    
    .footer {
        height: 20px;
        border-top-width: 1px;
    }
    
    .header {
        padding-top: 21px; // footer height + border
    }
    

    Note that the JSFiddle technique listed in the comments doesn’t work on IE at all and on Chrome doesn’t solve the stated problem (footer and contents overlapping).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a fluid page (100% width) with this inside: [image-fixed-width] | [text-fluid-width -----------------------------------]
I have a fluid layout, but if the browser window is stretched too much,
I'm having trouble finding the right solution for this fully fluid layout. I want
I know how to make a fixed+fluid column layout (and there are many examples
This simple HTML5 layout is intended to have a navigation bar on the left
I have a fluid layout with DIV's of different heights and widths, and I'd
I know there must be a simple way to do this but for the
I'm trying to create a website with fluid layout, but im having some problems
I am designing a fluid layout (no fixed px, all in %) I have
I have two divs as follows: fluid width content fixed width content I'm trying

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.