How to make the page full-width in Hestia

Most of the pages in Hestia, blog/archive, single page, single post, has an option for displaying a sidebar. When this one is hidden, the content is just centered and not full width.

Page without sidebar

Full-width content

For changing this behavior, just download a ready-made child theme from this guide and add the following code at the end of the functions.php file within the child theme.

function single_post_full_width() {
   return 'col-md-12 page-content-wrap ';
function single_page_full_wdith() {
   return 'col-md-12 single-post-container';
function index_page_full_width() {
   return 'col-md-12 blog-posts-wrap';

function make_pages_full_width() {

   /* Blog/Archive pages */
   add_filter( 'hestia_filter_index_search_content_classes', 'index_page_full_width' );

   /* Single page */
   add_filter( 'hestia_filter_page_content_classes', 'single_page_full_wdith' );

   /* Single post */
   add_filter( 'hestia_filter_single_post_content_classes', 'single_post_full_width' );
add_action( 'after_setup_theme', 'make_pages_full_width' );

That's it!

Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us