Remove the Sidebar in WordPress
Whether you select a free or premium theme, the default layout almost always includes a sidebar. Unfortunately, removing the sidebar from WordPress isn’t as simple as it seems.
Check out how Kinsta compares against the competition.
Choose a service provider.
Compare
However, there are various approaches you can use to get the look you desire for your website. It’s feasible to remove the sidebar from your entire site or just specific content in WordPress with a little effort.
We’ll start with why you could be better off without a sidebar on your WordPress site in this piece. Then we’ll teach you how to get rid of yours using various approaches. Let’s get started!
Contents Table of Contents
Why You May Want to Remove the Sidebar from Your WordPress Site?
How to Remove the WordPress Sidebar (4 Methods)
Do you like to watch the video?
Why Might You Want to Get Rid of Your WordPress Site’s Sidebar?
In WordPress design, sidebars are extremely frequent. They’re usually found to the right or left of the main page text, although they can also be found at the bottom of the page.
Widgets, which are little content spaces that appear on every page of your website, are commonly found in WordPress sidebars. As a result, sidebars are a common location for CTAs like email signup forms and search bars:
An example of a sidebar widget
Some websites even offer navigation menus in their sidebars. Users will always be able to find their way around, which can be incredibly beneficial:
an example of a sidebar navigation
An example of navigation in the sidebar
In addition, sidebars are a popular spot for advertisements. It’s simple to make a sidebar advertisement stand out while keeping the rest of the page legible:
Example of a sidebar ad
It may seem weird that some users would desire to get rid of sidebars, given how useful they can be. Despite the numerous forms of converting material you may include in your sidebar widgets, they do offer certain disadvantages.
Above all, everything outside the main content section detracts from the primary goal of your website. If you have a sidebar on your blog, for example, having eye-catching widgets in your sidebar may unintentionally detract from your postings.
Furthermore, a sidebar can be aesthetic overkill in some circumstances. When you add a sidebar to a content-heavy site like a news aggregator or an online magazine, it might feel cluttered and unsettling. Removing it, on the other hand, makes your design simple and straightforward.
Finally, it’s worth noting that sidebars on mobile sites aren’t really beneficial. For mobile users, most responsive themes shift the sidebar to the bottom of the page. Because mobile internet usage is on the rise, a sidebar-based design may no longer be the best option.
How to Remove the Sidebar in WordPress (4 Methods)?
Despite the various reasons why users may prefer not to have a sidebar on their WordPress blogs, most themes still include it as a default feature. Furthermore, if you don’t know what you’re doing, removing the sidebar can be difficult. Here are four strategies you can employ, depending on your situation and tastes, to make the process easier.
1. Remove the sidebar from your WordPress site entirely.
You’ll need to update your theme if you want to completely remove your website’s sidebar. Before you begin, you should make a backup of your site in case something goes wrong. You might also want to use a child theme so that you don’t have to worry about making permanent modifications to the theme.
You’ll need to access your theme’s files directly once you’ve safeguarded your site and are ready to start changing. If you want, you can use an FTP software like FileZilla to perform this via Secure File Transfer Protocol (SFTP). You can also make changes to files directly from your WordPress dashboard.
To utilize the latter method, go to Appearance > Theme Editor on your site’s back end. You’ll notice anything like this as a warning:
Warning from the template editor
Warning from the template editor
Click the I Understand option, and keep in mind that any modifications you make should be done with caution. After that, you must locate each of your theme’s template files. These are the files that your theme uses to keep track of how different sorts of content, such as posts, pages, and goods, should be displayed.
Your theme most likely has numerous templates. Index.php, single.php, archive.php, and so forth are likely to be among them. You’ll have to edit each one individually. Look for a line of code that looks like this once you’ve opened the first file:
get sidebar (‘sidebar-name’); php get sidebar (‘sidebar-name’); php get sidebar (‘sidebar-name’); php get side
To remove the sidebar from that template, simply delete the code in the parenthesis – in this case, “sidebar-name.” Then repeat the process until you’ve removed all of the code from your theme.
Unfortunately, your theme will most likely leave a large blank space where the sidebar was supposed to be once you complete this step. This can make your site appear unbalanced and unnatural, like in:
for instance, no sidebar
Example in the sidebar was removed.
This is because, despite the absence of the sidebar, the design does not specify that the page should utilize a full-width layout. To adjust the defined width of the content section, you’ll need to apply custom CSS, which varies from theme to theme. Fortunately, for popular themes like Divi and Avada, you can typically find instructions online or hire a developer to do it for you.
2. Remove a WordPress Static Page’s Sidebar
You may want to use a sidebar in some portions of your site but not others in some circumstances. If you wish to eliminate your sidebar from a single static page, such as your Home, About, or Blog page, check to see if your theme has a full-width template.
Do you want to discover how we grew our traffic by over 1000%?
Join the 20,000+ people who receive our weekly email with WordPress insider secrets!
Now is the time to subscribe.
To do so, go to the page where you want to remove the sidebar. Look for a full-width option in the Template drop-down menu in the Page Attributes section:
fullwidth design
Examining the available templates
Select a full-width template and alter the page to remove the sidebar if one is present. If your theme doesn’t have this feature, you can make your own template.
Begin by naming your new file fullwidth.php or something similar in your choice text editor.
Then go to your page.php file and open it. Copy and paste the whole contents of this file into your new fullwidth.php file. Add the file name after the opening PHP tag, like follows:
Fullwidth is the name of the template.
Then look for and delete any instances of the following code:
? get sidebar (‘side-name’) php?>
Save your modifications, then FTP your new template to the folder of your theme or child theme. Your site’s pages should now have a full-width template choice.
3. Disable the sidebar on individual blog posts.
Whether you wish to generate single blog posts without sidebars, check to see if your theme has a full-width template option, similar to how you would for pages. This feature is also available in some page builders:
full-width template for posts
A full-width post is an example.
If your theme doesn’t have such a template and you don’t utilize a page builder, you can still make posts without a sidebar by developing your own single post template.
Are you tired of having problems with your WordPress site? With Kinsta, you’ll get the best and fastest hosting support! Take a look at our plans.
Creating a page template is quite similar to this method. Create a new text file and paste the following code into it:
<?php
/*
Featured Article is the name of the template.
* Post Type Templates: post, page, and product
*/
?> get header();
Then, using FTP or the WordPress Theme Editor, get to your theme’s single.php file. Copy everything below the get header line and paste it into the text file for your new template.
You can now customize your post template now that you have a basis to work with.
Begin by eliminating the sidebar code, as we did with the other techniques in this post. If you need to make other modifications, you can utilize custom CSS or simply save the file. Make sure the file is named something memorable and descriptive so you can find it again.
Finally, use SFTP to upload your new template to the folder of your theme or child theme. The template option will appear in the Template drop-down box in the Post Attributes section of each of your posts with the name you’ve given it (for example, “Featured Article” in the example above).
4. Remove Your WordPress Sidebar Using a Plugin
If custom coding isn’t your thing or you’re just terrified about the thought of modifying your theme’s files, you can use a plugin to eliminate your WordPress sidebar instead. There are various options available to assist you in completing this activity.
Content Aware Sidebars is a useful option:
sidebar that is aware of the content
WordPress plugin for a content-aware sidebar
This plugin offers you complete control over the widgets in your sidebar. You can, for example, establish separate sidebars for different sections of your website. You can also hide and expose your sidebars on any post or page.
Simple Page Sidebars, on the other hand, takes a more straightforward approach:
sidebar for a simple page
Content Aware Sidebars, a WordPress plugin for removing the WordPress sidebar from some pages and incorporating custom sidebars on others, includes a lot of bells and whistles. Simple Page Sidebars, on the other hand, allows you similar power without any possibly superfluous features.
If you want a truly simple solution to eliminate your WordPress site’s sidebar, Widget Disable is definitely a better option for you:
plugin deactivate widget
WordPress Plugin Disable Widget
Using this plugin, you may remove sidebars and dashboard widgets with only a few clicks. It’s easy and simplified, and it’s a good quick fix if you don’t need to modify anything about your sidebars other than getting rid of them.
Want to make your page or blog layout less cluttered so that your users can focus on your content? Try one of these strategies to get rid of your sidebar… it’s incredibly simple! 🔨🔬
TO TWEET, CLICK HERE
Summary Despite their many benefits, WordPress sidebars can sometimes detract from your content, clutter your pages, and degrade the quality of your mobile site. However, they’re still present in many WordPress themes, so knowing how to get rid of them is essential if you want to obtain your perfect layout.
Here are four options for getting rid of your WordPress sidebar:
By modifying your theme’s files, you can completely remove the sidebar from your WordPress site.
Create a template to remove the sidebar from a static page.
Using a custom post template, create single posts without sidebars.
To get rid of your WordPress sidebar, use a plugin.
Save time, money, and improve site performance by using:
Expert WordPress hosting assistance is available 24 hours a day, 7 days a week.
Integration with Cloudflare Enterprise.
With 29 data centers across the world, we can reach a global audience.
With our built-in Application Performance Monitoring, you can improve your performance.
All of this and more is included in a single plan that includes no long-term obligations, aided migrations, and a 30-day money-back guarantee. Check out our plans or speak with a sales representative to find the ideal plan for you.