Sometimes it is required to display a suitable, separate sidebar on certain pages on the website. Apart from the default sidebar provided by the theme, you can create a custom sidebar and display it on particular pages with display rules.
This plugin will replace the theme’s default sidebar with the custom sidebar. It also allows replacing widget areas in header or footer. If you have plugins that provide their own widget area like WooCommerce, this plugin allows replacing those widget areas as well.
Below are the steps to use Lightweight Sidebar Manager plugin –
1. Install and activate the plugin on a WordPress site.
2. Settings can be found under Appearance > Sidebars.
3. Add New sidebar and enter a title for your custom sidebar.
4. Fill sidebar settings.
- Sidebar To Replace: Select the sidebar or widget you wish to replace. All available sidebar and widget areas in the theme will be listed here.
- Description: Add description for your custom sidebar. This is optional.
- Display On: Choose whether to display the custom sidebar on the entire website or on specific pages/posts. You can even exclude a particular page/post by adding them to the Exclusion Rule.
- User Roles: You can decide a user role for which custom sidebar should be visible. For excluded users, the default sidebar set with the theme will be visible.
5. Above steps will register the custom sidebar on site. This custom sidebar will appear under Appearance > Widgets.
6. Add widgets to this custom sidebar. Drag and drop the widgets you want to add to the custom sidebar.
7. That’s it! Your custom sidebar will appear on pages/post/widget areas you selected with display rules.
Check following things if you are not able to see custom sidebar –
1. Default sidebar is enabled from the theme. As custom sidebar replaces default sidebar, it needs to be enabled from the theme.
2. If you have selected the sidebar to display on the header/ footer, check if the widget area is enabled for header/footer. Custom sidebar replaces the widget area in the header/footer so you need to enable it.
Using Lightweight Sidebar Manager plugin with Astra theme
Below is the example that shows how to add a custom sidebar to Astra primary header –
1. Install and activate the Astra theme and Lightweight Sidebar Manager plugin.
2. As we need to set a custom sidebar in the primary header, we need to add the widget area in the header. To add widget area navigate to Appearance > Customize > Header > Primary Menu > Last Item in Menu and select Widget from the list.
3. Now follow the steps that are mentioned above to use Lightweight Sidebar Manager plugin.
4. This will add a custom sidebar to Astra Header. For the demo, we have added image gallery widget to the custom sidebar as shown in the screenshot below –
5. Similarly, you can add a sidebar to the footer and other sections of Astra header.