Find The Right SEO Service For Your Business

We cover the full spectrum of SEO services from local SEO to international SEO. Choose the SEO service right for you and call us today for a free confidential chat about your digital marketing.

SEO

SEO Services →

Digital Marketing Service →

Digital PR Service →

Ecommerce SEO →

Organic SEO Services →

Image Optimisation →

URL Structure Optimisation →

Internal Linking →

Page Speed Optimisation →

User Experience Optimisation →

Free SEO Audit

Find out why your website isn't ranking on the top of Google and what actionable steps you can take, with our free no obligation SEO audit.

Free SEO Audit →

Get Rid of White Space Under Header

By Paul - SEO Consultant
Categories: Divi

Are you frustrated by unsightly white space under the header when using the Divi theme?

Is this spacing issue throwing off the visual balance of your website? Is it just appearing on mobile, or across all devices? 

If so, follow this quick and straightforward fix to eliminate the white space under the header in Divi, ensuring your site looks polished and professional.

Easy Solution on How to Fix White Space Under Header in Divi

 

The fix that seems to get rid of white space under header in Divi nearly every time is to go to your backend on word press and click Divi, then Theme Options then scroll down to custom CSS and copy and paste this CSS code and click save.then clear your cache to see the changes. (I’ve attached a screenshot at the bottom of this quick “how to article”. So if your still lost have a look at the image)

@media all and (max-width: 768px){
div#page-container{
margin-top: -2px !important;
}
}

 Change the negative margin or the max width to suit your needs and good luck with the success of your website. 

 Other ways that can eliminate the white space under the header are as follows; 

Navigate to the Divi Theme Customizer by accessing Appearance > Customize in your WordPress dashboard. Once you’re in, here’s a simple tweak you can apply:

In the Header & Navigation section, find the Header Format settings. If the current format of your header introduces extra space (like some vertical headers might), consider changing it to a more traditional horizontal layout.

Next, adjust the Header Padding settings within the same section. Set the top and bottom padding values to 0px. This should snugly align the header with the content below, eliminating any unwanted space.

Additional CSS for Precision

If the white space still lingers, it’s time to dive into the Additional CSS section of the customizer. Look for any CSS entries that might be adding margin or padding around the header (header, #main-header, .et_pb_section). Modify these values as needed—often, setting margins to 0 can resolve unexpected spacing.

Preview, Publish, and Perfect

Utilize the live preview feature to instantly see the effects of your changes. If the header now looks as expected, without any white space, hit Publish to apply the changes across your site.

Don’t Forget to Clear the Cache

To ensure all your visitors see the update without delay, clear any cache that might be in place, whether from a plugin or your web hosting service.

By following these steps, you can swiftly fix the white space under the header in your Divi theme, enhancing the overall aesthetic of your site. If you ever need more help with website design, technical tweaks, or if you have other questions about using Divi, don’t hesitate to reach out for professional advice!

If none of that works then your screwed…. 🙂 only joking, there is a work around by adding a shadow to the bottom of your header to mask the white space underneath if. You can pick the colour of the shadow and its intensity so your website can still look professional with a unique header and shadow. Good luck and keep positive. 

Get Rid of White Space Under Header - Divi
Tags:

First Place SEO, International House, 4 Maddox St, London W1S 1QP

02071128794

First Place SEO Agency London

How To Find Local SEO Keywords - First Place SEO
Apr 23 2025

How to Find Local SEO Keywords

Learn how to find the right local SEO keywords using real strategies that boost visibility, attract local traffic and turn searchers into customers.

How Much Does SEO Cost In London - First Place SEO
Apr 23 2025

How Much Does SEO Cost in London?

Learn what SEO costs in London in 2025. From freelancers to agencies, this guide by First Place SEO breaks down pricing models, services and what you should expect for...
How to find seo content ideas for any website in the uk - First Place SEO
Apr 22 2025

How to Find SEO Content Ideas for Any Website in the UK

Discover proven methods to find SEO content ideas that rank. Use keyword tools, Google Search Console, and customer insights to grow your site organically.

Are SEO Keywords Case Sensitive - First Place SEO
Apr 22 2025

Are SEO Keywords Case Sensitive?

Are SEO Keywords Case Sensitive in Google and Search Engines? No, SEO keywords are not case sensitive in search queries or indexing by major search engines like Google...
On page SEO Checklist - First Place SEO
Apr 20 2025

On Page SEO Checklist

Boost your rankings with this complete 2024 on page SEO checklist. Learn how to optimise titles, content, internal links, schema markup, and site speed.

Why is seo friendly content important - First Place SEO
Apr 20 2025

Why is SEO Friendly Content Important?

Learn why SEO friendly content matters for higher Google rankings, organic traffic and building trust. Simple, clear guidance from First Place SEO.

How to Remove a Link from Google Search - First Place SEO
Apr 20 2025

How to Remove a Link from Google Search

Learn how to remove URLs from Google search results using Google Search Console, noindex tags, and permanent deindexing. Protect your SEO visibility now

How to Become an SEO Expert - First Place SEO
Apr 18 2025

How to Become an SEO Expert

Learn how to become an SEO expert in the UK with this step-by-step guide. Build practical skills in content, technical SEO, tools, and ranking strategies.

Do Tags on Shopify Help with SEO - First Place SEO
Apr 18 2025

Do Tags on Shopify Help with SEO?

Wondering if Shopify tags help SEO? Learn how product tags improve internal linking, user experience, and search visibility. A complete guide for better Shopify...
Is an FAQ page good for SEO - First Place SEO
Apr 18 2025

Are FAQ Pages Good for SEO?

Do FAQ pages help SEO? Learn how to use FAQs to boost search rankings, improve user experience, and increase leads for your SEO or web design business.

Schedule a Chat About Your Website

International House, 4 Maddox St, London W1S 1QP

Fill out the form to book your free SEO consultation. Get a tailored strategy to improve rankings, drive traffic, and grow your business.

Consent To Contact You Regarding Your Enquiry

End To End Digital Agency

Digital Marketing Services We Offer

  • Organic SEO
  • Local & Google My Business SEO

  • Content & Keyword Optimisation

  • PPC (Google Ads)

  • Web Design and Web Development

Customer Reviews

⭐️⭐️⭐️⭐️⭐️
"Since working with this team, our website traffic has doubled, and we’re now ranking on page one for competitive keywords!"

Sarah James  - London UK