How to Remove the Sidebar in WordPress

Do you want to remove the sidebar from your WordPress site? The sidebar is a widget-ready area in your WordPress theme.

It often appears on the right or left side on every page.

In this article, we will show you how to easily remove the sidebar in WordPress.

How to Remove the Sidebar in WordPress

Why Remove the Sidebar in WordPress?

Most free and paid WordPress themes come with multiple sidebars or widget-ready areas.

The purpose of sidebars in WordPress is to display items that are not part of the post or page content. Usually, these are links to different areas of your website, advertisements, email list signup forms, social media profiles, or any other links you want people to see.

These items can be easily added to the sidebar of a theme using WordPress widgets.

Sidebar on a WordPress powered website

In most WordPress themes, the sidebar appears differently when a user is viewing your site from a mobile device. Due to the reduced width of the screen size, sidebars that appear on right or left on the desktop are moved to the bottom on mobile screens.

Sidebars are immensely helpful and can help you grow your business. See these WordPress sidebar tricks for maximum results.

However, some website owners feel that removing the sidebar helps improve user experience. If you’re looking to remove the sidebar on your WordPress site, then this tutorial is for you.

Video Tutorial

Subscribe to joinsessions

If you don’t like the video or need more instructions, then continue reading.

Removing Sidebars Using Your WordPress Theme Settings

Many of the best WordPress themes come with built-in settings to remove sidebars. Depending on your theme, you can remove them site-wide, or simply remove them from individual posts or pages.

You can find out if your theme has this option by editing a single post or page.

In the right column, you will be able to see the option to remove sidebars. For instance, here is what you would see if you were using the Astra WordPress theme.

Removing sidebar using theme settings

Some themes may have an option to choose a single post or page template including a full-width template. You will find the option to select the template under page attributes section on the right column.

Full width page template

Some themes would also allow you to select a sidebar layout from theme options. You can find these options under Appearance » Customize page.

Removing WordPress sidebar using theme settings

Depending on your theme, the location and appearance of these options may vary. Once you have located the settings, you will be able to instantly see your changes appear in the live preview.

Don’t forget to publish your changes before exiting theme customizer.

Keep in mind that some WordPress themes may not have this feature at all. In that case, continue reading and we’ll show you other ways to remove the sidebar in WordPress.

Removing Sidebars From Everywhere in WordPress

This method allows you to simply remove sidebars from every page and post on your WordPress site. It also requires you to edit WordPress theme files. So, if you haven’t done this before, see our guide on how to copy and paste code in WordPress.

Keeping in mind that if you edit your WordPress theme files directly, then those changes will disappear when you update your theme. This is why you would need to create a child theme to save your changes.

First, you need to connect to your WordPress site using an FTP client and then go to /wp-content/themes/your-current-theme/ folder.

WordPress themes are made up of different templates, so you will need to edit all the templates where a sidebar is displayed. To locate the file, see our guide to WordPress template hierarchy.

For example, in a typical WordPress theme, you may need to edit index.php, page.php, single.php, archive.php, home.php and so on.

Open a template file to edit it and then locate the line that looks like this:

If your theme comes with multiple sidebars, then you will see different instances of this code with a sidebar name inside the function. For example:

Delete the line that represents the sidebar that you don’t want to display.

Now, save and upload the file back to your WordPress hosting account. Repeat the process for all template files responsible for displaying different pages on your website.

Once finished, you can go to your website and see it in action.

You may notice that while the sidebars are gone, your content area is still showing up with the same width, leaving the sidebar area empty.

Blank sidebar area in a WordPress theme

That’s because your theme has a defined width for the content area. Now that the sidebar is gone, you need to adjust the width of the content area by adding custom CSS to your theme.

First, you will need to figure out the CSS class used by your theme to define the width of the content area. You can do that by using the Inspect tool in your browser.

Here’s the sample CSS we used on our demo site using the Twenty Sixteen theme.

.content-area {
    width: 100%;
    margin: 0px;
    border: 0px;
    padding: 0px;

.content-area .site {

Here’s how it looks without sidebars:

Sidebars removed from a WordPress theme

Removing Sidebars From Individual Pages in WordPress

It’s possible that you only want to remove the sidebars on certain pages while displaying them on other sections of your website.

For example, a lot of websites display sidebars on their blog page but not on individual blog posts. Some prefer to show sidebars everywhere except static pages.

If you’re looking to create a custom landing page or sales page, then we recommend using a WordPress landing page plugin like SeedProd because it lets you create custom landing pages without writing any code (using a drag & drop interface).

Having that said, let’s take a look at different scenarios and how to remove sidebars from different areas.

Removing Sidebars from a Static Page in WordPress

As we mentioned earlier, many WordPress themes come with ready-to-use full-width page templates. These templates can be used with any static page in WordPress and do not display sidebars on either side of the content.

You will just need to edit the page where you want to remove the sidebar and then select the full-width template under ‘Page Attributes’ meta box.

Full width page template

If you do not see an option to select a template, then this means that your theme does not come with a full-width page template.

In that case, you will need to create a full-width page template manually. Open a plain text editor like Notepad and paste the following code in a blank file:

Now save this file as full-width.php on your desktop.

Connect to your WordPress site using an FTP client and then go to /wp-content/themes/your-current-theme/ folder. Edit the file called page.php and copy every thing that appears after line.

Now paste this code in your full-width.php file. After that you need to locate and delete the line that looks like this:

Save your changes and upload the full-width.php file to your current theme folder.

You can now edit any page on your WordPress site and you will be able to select your full-width page template.

For more details, see our guide on how to create a full width page template in WordPress.

Remove the Sidebar from a Single Post in WordPress

Just like pages, WordPress also comes with built-in support for post templates.

If you want to remove the sidebar from certain single posts, then you can create a custom single post template. It is similar to creating a full-width page template.

First, you’ll need to create a new template file using a text editor like Notepad. Next, you need to copy and paste the following code in that file:

This code defines a new template called Featured Article and makes it available for post, page, and product post types.

You can save this file as wpb-single-post.php on your desktop.

Next, you need to upload it to your current WordPress theme folder using an FTP client.

You can now edit any single post on your website and you will notice the new Post Attributes meta box with an option to select the template.

Single post template

You can follow the steps outlined in our guide on how to create custom single post templates in WordPress.

In your custom single post template, all you need to do is make sure to remove the sidebar part of the code.

If you want more control over your site’s layout, there are some great page builders available.

Remove Sidebars using a Page Builder Plugin

If you only want to remove sidebars from a few pages, then you can use a WordPress page builder plugin like Beaver Builder or Divi.

These drag and drop page builders come with ready to use templates that you can use to create custom page layouts. You can also use a blank template and design one from scratch.

For the sake of this tutorial we’ll be using Beaver Builder but it is pretty much the same with most page builders.

First, you need to install and activate the Beaver Builder plugin. For a step-by-step tutorial, see our guide on how to install a WordPress plugin.

Upon activation, simply edit the post or page that you want to edit and on launch the Beaver Builder editor.

Launch Beaver Builder

Beaver Builder comes with several templates that you can use. You can also make your own layout by simply adding modules, rows, and elements to your page.

Choose a template

For more detailed instructions, see our tutorial on how to create custom WordPress layouts with Beaver Builder.

We hope this article helped you learn how to easily remove the sidebar in your WordPress theme. You may also want to see our step by step guide on how to boost WordPress speed and performance, and our comparison of the best email marketing services to grow your traffic & sales.

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.