WordPress footer always at the bottom of the screen-page


I’m having a problem in fixing the footer always to the bottom of the page, also when there is not enough content in the page to fill it.

I found a lot of similar questions online and all of them suggested as solution to add code similar to the following:

footer {
position: fixed;
bottom: 0;
left: 0;
right: 0;

Here you can see the initial situation (footer in the middle of the page for empty content page):
enter image description here

And after applying the code, it seems correct. Indeed the footer is going to the bottom of the page, but not the way I want it.

The problem is that when the page is full of content (i.e. homepage), the footer is covering the content!

I want the footer to be ALWAYS to the end of the page and, if the page is empty, to the end of the screen.

Do you know how to achieve that?

Note: I’m using Astra theme and Elementor Pro as theme builder. My footer is created with Elementor.

Many thanks in advance to everyone who would help!

Gio Bact 2 years 2020-12-23T05:10:29-05:00 0 Answers 7 views 0

Leave an answer