How to Change Shop Page Title In WooCommerce

WooCommerce Change Shop Page TitleAre you looking for a way to change the WooCommerce shop page title? The shop page includes all the products in your WooCommerce store. You may want to change the shop page title programmatically.

There are many plugins, which allow you to achieve this. However, it is important to note that if you have many plugins in your WooCommerce store, they can slow down your site.

We recommend using custom code to make changes. But you need to create a child theme so that your changes are not lost during an update.

WooCommerce Change Shop Page Title

By the end of this article, you will be able to change the shop page title. We will use custom PHP code to achieve this.

You will also learn how to hide the shop page title.

It is important to note that you should have some coding knowledge to implement this solution.

Let us look at how you can achieve this.

Steps to Change Shop Page Title

The default Shop page for WooCommerce online store will show the “Shop” at the top of the products row.shop page

Here are the steps you need to follow:

  1. Log into your WordPress site and access the Dashboard as the admin user.
  2. From the Dashboard menu, click on Appearance Menu > Theme Editor Menu. When the Theme Editor page is opened, look for the theme functions file where we will add the function that will change the shop page title.
  3. Add the following code to the php file:
[php] add_filter( ‘woocommerce_page_title’, ‘njengah_woocommerce_page_title’);

function njengah_woocommerce_page_title( $page_title ) {

  if( $page_title == ‘Shop’ ) {

    return "WooCommerce Demo Title";

  }

}[/php]

  1. You can add the title you prefer. This is the outcome:new title
  2. If you want to hide the title, add the following code at the bottom of the functions.php file:
[php]

add_filter( ‘woocommerce_show_page_title’, ‘njengah_hide_shop_page_title’ );

function njengah_hide_shop_page_title( $title ) {

   if ( is_shop() ) $title = false;

   return $title;

}[/php]

  1. This is the outcome:no title

Conclusion

By now, you should be able to change or hide the shop page title. It is important to add an appropriate title so that it does not affect the user experience.

However, you should be very careful when editing the functions.php file. This is because if you make any mistake it will show a critical error on your site.

If you encounter any problems or need further customization, please contact a qualified WordPress developer.

Similar Articles

  1. 100+ Tips, Tricks & Snippets Ultimate WooCommerce Hide Guide
  2. How to Customize WooCommerce Product Pages