> ## Documentation Index
> Fetch the complete documentation index at: https://vr-it-services-pro.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

> Widget areas, and the three settings that control when the sidebar appears.

# Sidebars and widgets

# Sidebars and widgets

Widget areas in Vara SaaS, where they are, and how to control when the sidebar appears.

![Screenshot: a single post showing content on the left and the sidebar on the right](https://mintlify.s3.us-west-1.amazonaws.com/vr-it-services-pro/images/screenshots/sidebars-and-widgets-single-post.png)

## Widget areas

Vara SaaS registers one sidebar and four footer widget areas.

| Area | ID | Where it appears |
| - | - | - |
| **Primary Sidebar** | `sidebar-1` | Beside post content when a sidebar is enabled |
| **Footer 1–4** | `footer-1` … `footer-4` | Registered for widget use in the footer |

> [!NOTE]
>
> **The footer you see is not built from widgets.** It is rendered by theme template code from the Customizer settings. The `footer-1` through `footer-4` areas are registered so plugins that expect a footer widget area can place content there, but the visible footer columns come from **Customize → Vara SaaS → Footer**. Configure the footer there, not under **Appearance → Widgets**.

## Adding widgets to the sidebar

**1. Open Appearance → Widgets**

**2. Find Primary Sidebar**

On desktop the widget screen has the sidebar on the right.

**3. Drag a widget in**

Blocks, Search, Recent Posts, Categories, Archives, Custom HTML, and anything your plugins register.

**4. Save**

![Screenshot: Appearance → Widgets showing the Primary Sidebar area with widgets added](https://mintlify.s3.us-west-1.amazonaws.com/vr-it-services-pro/images/screenshots/sidebars-and-widgets-admin.png)

**The block editor works here**

Widget areas accept the block editor, so you can compose a sidebar with blocks rather than legacy
widgets.

## Controlling when the sidebar appears

Three things combine.

### 1. The site-wide switch

**Customize → Vara SaaS → General → Enable sidebar**

| Value | Effect |
| - | - |
| **On** *(default)* | Sidebar areas can render |
| **Off** | No sidebar renders anywhere |

### 2. The post layout

**Customize → Vara SaaS → Single Post → Single post layout**

| Layout | Sidebar position |
| - | - |
| `sidebar-right` *(default)* | Right of the content |
| `sidebar-left` | Left of the content |
| `fullwidth` | No sidebar |
| `boxed` | No sidebar |

### 3. The per-page override

Each **page** has a **Sidebar Settings** box in the page editor, below the content and excerpt fields.

| Page setting | Result |
| - | - |
| **Show** *(default is Hide)* | Sidebar renders if the site-wide switch is on |
| **Hide** | No sidebar, regardless of the site-wide switch |

![Screenshot: the Sidebar Settings box in the page editor with Show and Hide options](https://mintlify.s3.us-west-1.amazonaws.com/vr-it-services-pro/images/screenshots/sidebars-and-widgets-page-setting.png)

> [!NOTE]
>
> **Pages default to hidden**, which is the right default for landing and marketing pages. If you want the sidebar on a specific page, set it to *Show* in that page's box.

## The sidebar table

| Page type | Sidebar behaviour |
| - | - |
| Single post | Follows the Single post layout setting |
| Page | Follows the page's Sidebar Settings box |
| Blog index | Never |
| Archive | Never |
| Search results | Never |
| Builder-owned page | Never — the theme steps aside entirely |
| 404 page | Never |

## What is in the sidebar by default

Nothing. The sidebar is empty until you add widgets.

> [!WARNING]
>
> **An empty sidebar still reserves its column** on wide screens, which can look like a broken layout. If you are not using widgets, turn **Enable sidebar** off. Alternatively add a Search widget and a Recent Posts widget — both are genuinely useful beside an article.

### Widgets worth considering

> **Search**
>
> Practical on a blog with many posts.

> **Recent Posts**
>
> Good companion to a table of contents.

> **Categories**
>
> Aligns with the category filtering already on the blog hero.

> **Custom HTML**
>
> A newsletter signup, a CTA, or an ad slot.

## Registering your own widget area

If you need an extra sidebar in a child theme:

```php theme={null}
add_action( 'widgets_init', function () {
    register_sidebar( array(
        'name'          => __( 'Product Sidebar', 'vara-saas' ),
        'id'            => 'product-sidebar',
        'description'   => __( 'Shown beside product pages.', 'vara-saas' ),
        'before_widget' => '<section id="%1$s" class="widget %2$s">',
        'after_widget'  => '</section>',
        'before_title'  => '<h2 class="widget-title">',
        'after_title'   => '</h2>',
    ) );
} );
```

**Match the theme's markup**

The theme wraps every widget in a `<section>` with an `<h2>` title. Copying that wrapper keeps
your area visually and semantically consistent.

To render it, add a sidebar to a child theme's `page.php`, or use a template part. See [Template files](/developers/template-files.md).

## Accessibility

> [!NOTE]
>
> The sidebar renders as an `<aside role="complementary">` landmark, which is correct. Widget titles are wrapped in `<h2>` so they are announced properly rather than being unlabelled decorative text.

> [!WARNING]
>
> **Widget titles are headings.** Ten widgets means ten more headings on the page, which affects your heading outline. If your articles use `h2` sections, widget titles at `h2` sit alongside them — which is correct. Avoid promoting them to `h1`.

## Troubleshooting

> **My widgets aren't showing**
>
> Work through it in order: is **Enable sidebar** on? Is the single post layout a sidebar layout? Is the page's Sidebar Settings set to *Show*? Are widgets actually in **Primary Sidebar**?

> **The sidebar appears on the wrong side**
>
> Change **Single post layout** between `sidebar-right` and `sidebar-left`.

> **There's an empty gap beside my content**
>
> The sidebar area is rendering with no widgets. Either add widgets or turn the switch off.

> **Footer widgets don't appear**
>
> Expected. The footer is built from the Customizer, not from widgets. See [Footer settings](/customization/footer-settings.md).

## Related

> **[Single post settings](/customization/single-post-settings.md)**
>
> The layout dropdown that positions the sidebar.

> **[Blog and archives](/customization/blog-and-archives.md)**
>
> The layouts that never show a sidebar.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.