Do you want to customize the destination URL when customers click on the button “Return to Shop”? A simple code snippet will make it easy for you!
add_filter( 'woocommerce_return_to_shop_redirect', 'ts_change_return_shop_url' ); function ts_change_return_shop_url() { return home_url(); }
Output
When your shopping cart is empty, it typically displays the “Return to Shop” button. Clicking on this button redirects you to the home page, as specified in the code.
Clicking on the ‘Return to shop’ button redirects users to the home page.
Customization of redirecting a button to the specific URL that you want is one easy way to make your customers land on the page you wish. Similarly, you can also customize the proceed to checkout redirect link in WooCommerce that will skip the entire cart page when view cart button is clicked.