Title: WP_Customize_Sidebar_Section
Published: December 18, 2014
Last modified: February 24, 2026

---

# class WP_Customize_Sidebar_Section {}

## In this article

 * [Description](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#description)
    - [See also](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#see-also)
 * [Methods](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#methods)
 * [Source](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#source)
 * [Related](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#related)
 * [Changelog](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#changelog)

[ Back to top](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#wp--skip-link--target)

Customizer section representing widget area (sidebar).

## 󠀁[Description](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#description)󠁿

### 󠀁[See also](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#see-also)󠁿

 * [WP_Customize_Section](https://developer.wordpress.org/reference/classes/wp_customize_section/)

## 󠀁[Methods](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#methods)󠁿

| Name | Description | 
| [WP_Customize_Sidebar_Section::active_callback](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/active_callback/) | Whether the current sidebar is rendered on the page. | 
| [WP_Customize_Sidebar_Section::json](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/json/) | Gather the parameters passed to client JavaScript via JSON. |

## 󠀁[Source](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#source)󠁿

    ```php
    class WP_Customize_Sidebar_Section extends WP_Customize_Section {

    	/**
    	 * Type of this section.
    	 *
    	 * @since 4.1.0
    	 * @var string
    	 */
    	public $type = 'sidebar';

    	/**
    	 * Unique identifier.
    	 *
    	 * @since 4.1.0
    	 * @var string
    	 */
    	public $sidebar_id;

    	/**
    	 * Gather the parameters passed to client JavaScript via JSON.
    	 *
    	 * @since 4.1.0
    	 *
    	 * @return array The array to be exported to the client as JSON.
    	 */
    	public function json() {
    		$json              = parent::json();
    		$json['sidebarId'] = $this->sidebar_id;
    		return $json;
    	}

    	/**
    	 * Whether the current sidebar is rendered on the page.
    	 *
    	 * @since 4.1.0
    	 *
    	 * @return bool Whether sidebar is rendered.
    	 */
    	public function active_callback() {
    		return $this->manager->widgets->is_sidebar_rendered( $this->sidebar_id );
    	}
    }
    ```

[View all references](https://developer.wordpress.org/reference/files/wp-includes/customize/class-wp-customize-sidebar-section.php/)
[View on Trac](https://core.trac.wordpress.org/browser/tags/6.9.4/src/wp-includes/customize/class-wp-customize-sidebar-section.php#L17)
[View on GitHub](https://github.com/WordPress/wordpress-develop/blob/6.9.4/src/wp-includes/customize/class-wp-customize-sidebar-section.php#L17-L58)

## 󠀁[Related](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#related)󠁿

| Uses | Description | 
| [WP_Customize_Section](https://developer.wordpress.org/reference/classes/wp_customize_section/)`wp-includes/class-wp-customize-section.php` |

Customize Section class.

  |

## 󠀁[Changelog](https://developer.wordpress.org/reference/classes/wp_customize_sidebar_section/?output_format=md#changelog)󠁿

| Version | Description | 
| [4.1.0](https://developer.wordpress.org/reference/since/4.1.0/) | Introduced. |

## User Contributed Notes

You must [log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fdeveloper.wordpress.org%2Freference%2Fclasses%2Fwp_customize_sidebar_section%2F)
before being able to contribute a note or feedback.