How to remove sidebar from wordpress

New Page

Eliminate sidebar from búsqueda results

Their OceanWP theme gives you the option to set up a separate layout for the search results page with ease.

The default page layout of the search results page is set to the sidebar.

To change the layout of the search results page:

1. Navigate to Appearance > Personalize > General Options > General Settings ,

2. Scroll down to the Search Results Page section ,

3. Choose the design you want and publish your changes.

file-CBVJET1E88

Apply other settings for the search results page according to your needs.

¡Eso that’s it!

Building a feliz website

How to remove the sidebar in WordPress

Dernière update on October 12, 2022by Editorial Team | Reader Disclosure Disclosure : Our content is endorsed by the reader. This means that if you click on some of our links, we may earn a commission. See how WPBeginner is funded, why it’s important, and how you can support us.

Share 159 Tweet Share Share Facebook Messenger WhatsApp Email

¿Quieres eliminar the sidebar of your WordPress site?

The sidebar is an area prepared for the widgets in the WordPress theme where you can display information that is not part of the content of the main page. Sans however, sidebars can be distracting and take up valuable space.

In this article, the mostraremos how to easily eliminate the sidebar in WordPress.

How to remove the sidebar in WordPress How to Remove Sidebar in WordPress

¿Por que leave the sidebar in WordPress?

Most of the WordPress themes gratuits et de pages come with multiple sidebars or widget-ready areas.

You can use the sidebars to display a list of your recent posts, advertisements, mailing list sign-up forms, or other content that is not part of the main page or post.

At WPBeginner, we use a sidebar to promote our social media pages and display our most popular posts.

An example of a WordPress sidebar An example of a WordPress sidebar

You can easily add elements to a theme’s sidebar using WordPress widgets.

Dans la plupart des thèmes WordPress, la barre latérale est différente selon que le visiteur voit votre site sur un ordinateur de bureau ou un appareil mobile. Étant donné que les smartphones et les tablettes ont des écrans plus petits, WordPress déplace généralement les barres latérales vers le bas de l’écran.

Depending on how your site is set up, this may look strange. Visitors will also need to scroll to the very bottom of the screen to see the sidebar content, which may affect the user experience and your conversion rates.

For more information, please see our guide on how to view the mobile version of WordPress sites from desktop.

Even on a desktop, there’s a chance that the sidebar may clash with your design or distract from the most important content, such as the page’s call to action.

With that being said, let’s see how you can remove the sidebar in WordPress. We’ll show you how to delete the sidebar from your entire site, and how to hide the sidebar on a specific page or post only.

Video Tutorial

Subscribe to WPBeginner

If you don’t like the video or need more instructions, then continue reading. If you prefer to jump straight to a particular method, then you can use the links below.

  • Method 1. Removing Sidebars Using Your WordPress Theme Settings
  • Method 2. Removing the Sidebar Using the Full Site Editor
  • Method 3. Removing the WordPress Sidebar Using Code
  • Method 4. Removing Sidebars From Individual Pages in WordPress
  • Method 5. Removing Sidebars from a Static Page in WordPress
  • Method 6. Remove the Sidebar from a Single Post in WordPress

Method 1. 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.

The easiest way to check whether your theme has these settings is to launch the theme customizer. In your WordPress dashboard, go to Appearance » Customize.

Lancement de la personnalisation de WordPress Lancement du personnalisateur WordPress

In the left-hand menu, look for a ‘Sidebar’ or similar setting.

In the following image, you can see the options for the popular Astra WordPress theme.

La configuración del tema para el tema Astra The theme settings for the Astra theme

If you do see a ‘Sidebar’ option, then click on it and then look for any settings that will remove the sidebar.

This might be a dropdown menu, thumbnails showing the different sidebar layouts, or some other setting.

Eliminar la barra lateral usando el Personalizador de WordPress Removing the sidebar using the WordPress Customizer

If your theme doesn’t have a ‘Sidebar’ option, then you may be able to remove the sidebar by selecting the ‘Page’ or similar section.

As you can see in the following image, Astra also has a ‘Page’ setting.

Cambiar el diseño de la página en el personalizador de WordPress Changing the page layout in the WordPress customizer

Inside this setting, you’ll see different layouts including several that remove the sidebar such as ‘No sidebar’ and ‘Full Width / Stretched.’

Simply click on the different thumbnails to apply these layouts to your site.

Eliminar la barra lateral usando el Personalizador de WordPress Deleting the sidebar using the WordPress Customizer

No matter how you remove the sidebar, don’t forget to click on ‘Publish.’

Some WordPress themes also have settings that allow you to remove the sidebar from individual posts and pages. This can be useful when designing custom pages, such as a landing page.

To see whether your theme comes with these settings, simply edit any page or post where you want to hide the sidebar. In the right-hand menu, select either ‘Post’ or ‘Page’ and then look for a ‘Post Settings’ or ‘Page Settings’ option.

La configuración de página para el tema Hestia The page settings for the Hestia theme

If your theme has this section, then click to expand. You can now look for any settings that allow you to remove the sidebar.

In the following image, you can see the post settings for the popular ThemeIsle Hestia theme.

The Post Settings section The Post Settings section

Keep in mind that some WordPress themes may not allow you to easily remove the sidebar using the customizer or page editor. If this is the case, then carry on reading and we’ll show you other ways to remove the sidebar in WordPress.

Method 2. Removing the Sidebar Using the Full Site Editor

If you’re using a block theme, then you can remove the sidebar using Full Site Editing (FSE) and the block editor.

This method is a quick and easy way to remove the sidebar across your entire site, although it won’t work with all themes.

To launch the editor, go to Appearance » Editor.

How to launch the FSE How to launch the FSE

You can now click to select the sidebar.

In the small toolbar that appears, click on the dotted icon.

Customize the sidebar using the full site editor Customize the sidebar using the full site editor

You can now delete the sidebar by clicking on the ‘Remove Column’ or similar setting.

Once you’ve done that, you can go ahead and click on the ‘Save’ button.

Removing the sidebar using the full site editor Removing the sidebar using the full site editor

Now, if you visit the front end of your WordPress website, you’ll see that the toolbar has disappeared.

Method 3. Removing the WordPress Sidebar Using Code

This method allows you to simply remove sidebars from every page and post on your WordPress site.

You will need to edit your theme files, so it’s not the most beginner-friendly option. However, this method should work for most WordPress themes, including themes that don’t have a built-in way to hide the sidebar.

Keep in mind that if you edit your WordPress theme files directly, then those changes will disappear when you update the theme.

With that being said, we recommend creating a child theme as this allows you to update your WordPress theme without losing customization.

First, you need to connect to your WordPress site using an FTP client such as FileZilla, or you can use the file manager of your WordPress hosting cPanel. Or if you’re a SiteGround user, your Site Tools dashboard.

If this is your first time using FTP, then you can see our complete guide on how to connect to your site using FTP. 

Once you’re connected, go to /wp-content/themes/ and open the folder for your current WordPress theme.

The FileZilla FTP client The FileZilla FTP client

WordPress themes are made up of different templates, so you will need to edit all the templates that include a sidebar. To work out what files you need to edit, see our guide to WordPress template hierarchy.

For example, you may need to edit index.php, page.php, single.php, archive.php, home.php, and so on.

To edit a file, open it in a text editor such as Notepad. Then, find the line that looks like this:

1

2

3

<pre class = “wp-block-syntaxhighlighter-code” >

<?php get_sidebar(); ?>

</pre>

If your theme has multiple sidebars, then the code will look slightly different and there may be multiple pieces of sidebar code. Typically, this code will have a sidebar name inside the function, for example:

1

2

3

<pre class = “wp-block-syntaxhighlighter-code” >

<?php get_sidebar( ‘footer-widget-area’ ); ?>

</pre>

You can simply delete the line for the sidebar that you want to remove.

Now, save and upload the file back to your WordPress hosting account. Simply repeat the process described above for all the template files that include a sidebar.

When you’re finished, you can visit your WordPress blog to see the change in action.

You may notice that although the sidebars are gone, your content area is still the same width, which leaves the sidebar area empty.

An empty space where the sidebar should be An empty space where the sidebar should be

This happens when the theme has a defined width for the content area. After removing the sidebar, you need to adjust the width of the content area by adding custom CSS to your WordPress theme.

To do this, go to Theme » Customize. In the left-hand menu, click on Additional CSS.

Adding CSS with the WordPress customizer Adding CSS with the WordPress customizer

You can now go ahead and paste the following code into the little code editor:

1

2

3

4

5

6

7

8

9

10

11

12

< pre class= “wp-block-syntaxhighlighter-code” >

.content-area {

     width : 100% ;

     margin : 0px ;

     border : 0px ;

     padding : 0px ;

}

 

.content-area .site {

margin : 0px ;

}

</ pre >

Don’t forget to click on the ‘Publish’ button. Now, if you visit your site you’ll see that the content area now takes up 100% of the available space.

Method 4. Removing Sidebars From Individual Pages in WordPress

You may only want to remove the sidebar on certain pages while showing the sidebar on other areas of your site. For example, many websites don’t show the sidebar on their sales pages, as this can distract from the page’s call to action.

If you just want to remove the sidebar from a specific page, then we recommend using a page builder plugin like SeedProd.

SeedProd lets you design any kind of page using a simple drag-and-drop editor. This makes it easy to add and remove the sidebar from any page.

In the SeedProd editor, simply click to select the sidebar you want to remove. Then, go ahead and click on the trash can icon.

Removing a sidebar using SeedProd Removing a sidebar using SeedProd

If you want to remove the sidebar from your entire site, then you can also use SeedProd to easily create a custom theme that doesn’t have any sidebars.

Method 5. Removing Sidebars from a Static Page in WordPress

Some WordPress themes come with multiple templates, including full-width page templates that don’t show the sidebar on either side of the content. You can use these templates to remove the sidebar from any page.

To see whether your theme has a full-width template, simply open any page. In the right-hand menu, select the ‘Page’ tab and look for a ‘Template’ section.

Changing the WordPress page template Changing the WordPress page template

If you find this section, then click on it to see all the options available.

You can now open the dropdown menu and look for a full-width template.

How to remove the sidebar with a full width template How to remove the sidebar with a full width template

If your theme doesn’t have a full-width template, then you can create one manually.

Open a plain text editor like Notepad and paste the following code in a blank file:

1

2

3

4

5

6

7

8

<pre class = “wp-block-syntaxhighlighter-code” >

<?php

/*

*

Template Name: Full-Width

*/

get_header(); ?>

</pre>

You can now save this file with the name full-width.php.

After that, connect to your site using an FTP client or the file manager supplied by your WordPress hosting provider.

Then, go to /wp-content/themes/ and open the folder for your current theme. Inside this folder, find the page.php file and open it in any text editor.

The FileZilla FTP client The FileZilla FTP client

Now, copy everything that appears after the <?php get_header(); ?> line and paste it into your full-width.php file.

Once you’ve done that, find and delete the line that looks like this:

1

2

3

<pre class = “wp-block-syntaxhighlighter-code” >

<?php get_sidebar(); ?>

</pre>

You can now save your changes and upload the full-width.php file to your theme folder.

You can now use this template with any page. Simply open the ‘Template’ dropdown in the right-hand menu and select your full-width template.

A full-width template A full-width template

Note: If you have a page open in the content editor while creating the full-width.php file, you will have to refresh the editor for the new template to appear in the dropdown menu.

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

Method 6. 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. Once you’ve done that, you can copy and paste the following code in that file:

1

2

3

4

5

6

7

8

9

<pre class = “wp-block-syntaxhighlighter-code” >

<?php

/*

  * Template Name: Featured Article

  * Template Post Type: post, page, product

  */

 

  get_header();  ?>

</pre>

This code creates a new template called ‘Featured Article’ and makes it available for any page or post, plus any product post types in your online store.

In your custom single post template, you simply need to remove the sidebar part of the code. For more information, you can follow the steps outlined in our guide on how to create custom single post templates in WordPress.

When you’re done, save this file as full-width.php.

Next, you need to upload the file to your current WordPress theme folder using an FTP client or file manager.

Once you’ve done that, you can apply this template to any post. In the right-hand menu, simply click to expand the ‘Templates’ section and then select the full-width template.

How to create a full-width template in WordPress How to create a full-width template in WordPress

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.

Shares 159 Share Tweet Share Facebook Messenger WhatsApp Email

How to Remove the Sidebar on Your WordPress Website

Shayla Price

Shayla Price

Updated: May 10, 2022

Published: March 17, 2021

Many WordPress themes are built with default sidebars. A sidebar is an area that displays information on the left side, right side, or underneath the main content space.

Grupo de especialistas en marketing y desarrolladores discutiendo cómo eliminar las barras laterales en wordpress

Depending on your WordPress website, your sidebar may include social media feeds, recent blog posts, or advertisements. However, sidebars aren’t always necessary for a particular page (or your entire website). Let’s explore how to remove sidebars on your WordPress website.

Download Now: How to Launch a WordPress Website [Free Guide + Checklist]

Why Should You Remove the Sidebar From Your WordPress Website?

The sidebar is a valuable space on your website. You can showcase related content to your visitors, like popular ebooks, your latest podcast episodes, or an email sign-up form. Many businesses find the sidebar useful for engaging their potential customers.

But the sidebar isn’t helpful for every website experience. For example, visitors landing on your website on their mobile devices may find it difficult to view your sidebar content due to the reduced screen size. You don’t want your visitors constantly zooming in and out on their smartphones just to interact with your website.

Sidebars also can distract visitors from your main page content if they’re not placed strategically. You don’t want to lead your visitors down a rabbit hole of never-ending sidebar content as it may lower conversion rates.

So, if you’re ready to ditch the sidebar (even if it’s only temporarily), continue reading.

How to Remove Sidebar in WordPress

  1. Log into your WordPress dashboard.
  2. Go to Appearance > Widgets on the left side of your dashboard.
  3. Find the Sidebar area.
  4. Expand the widget section by clicking the down arrow.
  5. Then, click Delete.
  6. Repeat these steps until you’ve deleted all the widgets under the Sidebar area.

The process for removing your sidebar will vary based on your WordPress theme. We’ll start with the easiest method first.

Remove a Sidebar in the WordPress Dashboard

  • Log into your WordPress dashboard.
  • Go to Appearance > Widgets on the left side of your dashboard.
  • Find the Sidebar area. It will look similar to this:

área de la barra lateral para saber cómo eliminar la barra lateral en WordPress: busque el área de la barra lateral

  • Expand the widget section by clicking the down arrow.
  • Then, click Delete.

eliminar widgets para saber cómo eliminar la barra lateral en WordPress - eliminar el widget

  • Repeat these steps until you’ve deleted all the widgets under the Sidebar area.

Remove Sidebar Using a Plugin

WordPress plugins make it simple to add features to your website. You can install a plugin to remove the sidebar on your website, too. Follow the steps below.

  • Go to Plugins > Add New on the left side of your dashboard.
  • Search for the Widget Disable plugin.
  • Install and activate the plugin.

complemento de desactivación de widget para eliminar una barra lateral en wordpress

  • Go to Appearance > Disable Widgets.
  • Under the Sidebar Widgets tab, click Select all to disable the sidebar widgets from your website. complemento de desactivación de widgets: desactive los widgets de la barra lateral en su sitio web
  • Click Save Changes.

 

Remove Sidebar in FTP

If you feel comfortable editing the code in your theme, then you can remove the sidebar using an FTP client. Before implementing this method, we recommend backing up your website and using a child theme to prevent losing any important changes.

  • Connect to your FTP.
  • Ouvrez le dossier : /wp-content/themes/your-current-theme/
  • You should see all model files. (For example, home.php, index.php, single.php, archive.php and page.php)
  • To remove the sidebar, remove this line of code from each template:

<?php get_sidebar(); ?>

  • It is possible that your WordPress theme has multiple sidebars. So, look for similar code and delete it:

<?php get_sidebar(‘footer-widget-area’); ?>

  • Click Save after you finish deleting all code from each template.

Vous pouvez maintenant consulter les modifications sur votre site Web. Si vous utilisez un plugin de mise en cache, assurez-vous de le désactiver pour voir vos modifications. Vous pouvez toujours réactiver le plugin de mise en cache plus tard.

Comment supprimer la barre latérale d’une page dans WordPress

  1. Accédez à Pages sur le côté gauche de votre tableau de bord.
  2. Sélectionnez la page statique souhaitée.
  3. On the right-hand side, find Page Attributes.
  4. Under Template, select Full Width.
  5. Click the blue Publish or Update button.

Removing Sidebar from Static Page

Maybe you only want to remove the sidebar from a specific page rather than from your entire website. A static page is a customized page that doesn’t change when you add blog posts to your website. Most businesses use a static page as their homepage. To make these changes to a static page, you’ll need to update the template.

Change Template in WordPress Dashboard

New WordPress themes come equipped with full-width templates that don’t have sidebars. You can use these templates as a static page on your website. Switching the template only takes a few minutes.

  • Go to Pages on the left side of your dashboard.
  • Select the desired static page.
  • On the right-hand side, find Page Attributes.
  • Under Template, select Full Width.

cambie la plantilla en el tablero de wordpress en la sección de atributos de la página y seleccione ancho completo en el menú desplegable

  • Click the blue Publish or Update button.

Change Template in FTP

If this option doesn’t appear in your settings, you can create your own full-width page template.

  • Open any text editor and create a new file.
  • Name the file full-width.php and save it on your desktop.
  • Connect to your hosting account using an FTP client.
  • Locate the folder: /wp-content/themes/your-theme
  • Select page.php file and edit it.
  • Copy all the code from this file and paste it in your full-width.php file.
  • After the opening <?php tag add this code:

/* Template name: fullwidth */

  • Dans le fichier full-width.php , recherchez : <?php get_sidebar(); ?>
  • Supprimez cette ligne de code car elle génère la barre latérale.
  • Enregistrez les modifications.
  • Téléchargez le fichier style=”font-weight: bold;”>full-width.php dans votre dossier de thème enfant via votre client FTP.
  • Lorsque vous accédez à Attributs de page , vous devriez maintenant voir l’option de modèle de page pleine largeur.

Supprimer la barre latérale de la page de publication de blog

Vous remarquerez que de nombreux thèmes WordPress affichent également des barres latérales sur la page des articles de blog. Mais ne vous inquiétez pas, vous pouvez les supprimer.

  • Go to Settings > Reading on the left side of your dashboard.
  • Next to your home page screens , go to the Posts page .
  • Select the static page template without the sidebars from the example in the previous section.

home page pants to remove the bar later in WordPress from a blog post page in the home page pants section

If there isn’t a template without sidebars available, read the previous section and follow the instructions to create a full-width template manually.

Remove single post sidebar

If you still want to remove sidebars from all your blog posts, you can customize a single post to have no sidebar.

  • Go to Posts on the left side of your dashboard.
  • Select the deseada blog post.
  • On the right side, look for Post Attributes .
  • Under Template , select Full Width .

Post Attributes on How to Remove Single Post Sidebar in WordPress : Select Full Width in Post Attributes

  • Click the blue Publish or Update button .

If you can’t find the full width option, you can create a custom page template without sidebars. The steps are similar to changing a template to a static page. The difference is that you should copy and edit the single.php file.

¿Lateral barra or sin lateral barra?

Sidebars are useful for displaying relevant content to visitors, but sometimes you need to remove them to improve the overall appearance of your website, improve conversion rates, or make it easier to navigate a page. With each of these options for removing a sidebar, you can customize your website to appear and function exactly the way you want.

Editor’s Note: This post was originally published in September 2019 and has been updated for completeness.

palaver clave

Themes: WordPress Website

Don’t forget to share this post!

Google Google translator

Google Google Translate


Video How to remove sidebar from wordpress

Related Posts

How to add seo keywords in wordpress

Contents1 Cómo agregar palabras clave de SEO en WordPress (aumentar el CTR y las clasificaciones)1.1 Post Title1.2 Headline1.3 Header Tags1.4 Introduction and Conclusion1.5 Body Copy1.6 URL1.7 Meta…

How to embed google calendar into wordpress

Contents1 How to Add a Google Calendar in WordPress (Step by Step)2 Add a Google calendar to your website3 calendario de Google3.1 Versatile plans and pricing4 Video…

How to change the logo in wordpress

Contents1 How to Add a Custom Logo to Your Site Header2 Site Logo2.1 Planes y precios versátiles3 Add, remove or edit a custom logo4 Video How to…

How to add a popup on wordpress

Contents1 Easily create a WordPress emergent form (2 forms)1.1 ¿Por qué usar un formulario emergente de WordPress?1.2 Método #1: Crear un formulario emergente con OptinMonster + WPForms1.3…

How to roll back wordpress version

Contents1 How to Revert WordPress: Undo WordPress Updates (Easy Way)2 How to Downgrade WordPress & Roll Back to a Previous Version2.1 1. A WordPress update included significant changes…

How to rollback wordpress version

Contents1 How to Downgrade WordPress and Revert to an Older Version1.1 1. A WordPress update included significant changes that are not compatible with your theme or plugins1.2…