WordPress filter hook

woocommerce_continue_shopping_redirect

Defined by WooCommerce and fired by 14 plugins in total, running on 7.2M+ sites between them.

How to use woocommerce_continue_shopping_redirect

It's a filter: your callback receives the value, and must return the (changed) value. Add this to your theme's functions.php or a small custom plugin:

functions.php
add_filter( 'woocommerce_continue_shopping_redirect', function( $value ) {
	// Change $value here.
	return $value;
}, 10, 1 );

Argument names come from Woo Continue Shopping's source. Other plugins may pass different values: check the call in the plugin you're targeting below.

14 plugins that fire woocommerce_continue_shopping_redirect

Sorted by active installs. Each entry shows where the plugin calls the hook and what it passes.

  1. WooCommerce icon WooCommerce7+ million installs apply_filters( 'woocommerce_continue_shopping_redirect', wc_get_raw_referer() ? wp_validate_redirect( wc_get_raw_referer(), false ) : wc_get_page_permalink( 'shop' ) ) includes/wc-cart-functions.php:136
  2. CartFlows icon CartFlows200,000+ installs apply_filters( 'woocommerce_continue_shopping_redirect', wc_get_page_permalink( 'shop' ) ) modules/thankyou/templates/instant-thankyou.php:20
  3. Booster for WooCommerce icon Booster for WooCommerce30,000+ installs apply_filters( 'woocommerce_continue_shopping_redirect', wc_get_raw_referer() ? wp_validate_redirect( wc_get_raw_referer(), false ) : wc_get_page_permalink( 'shop' ) ) includes/class-wcj-product-add-to-cart.php:231
  4. ATUM WooCommerce Inventory Management and Stock Tracking icon ATUM WooCommerce Inventory Management and Stock Tracking10,000+ installs apply_filters( 'woocommerce_continue_shopping_redirect', wc_get_raw_referer() ? wp_validate_redirect( wc_get_raw_referer(), FALSE ) : wc_get_page_permalink( 'shop' ) ) classes/Components/AtumStockDecimals.php:233
  5. WPC Product Quantity for WooCommerce icon WPC Product Quantity for WooCommerce2,000+ installs apply_filters( 'woocommerce_continue_shopping_redirect', wc_get_raw_referer() ? wp_validate_redirect( wc_get_raw_referer(), false ) : wc_get_page_permalink( 'shop' ) ) wpc-product-quantity.php:899
  6. Direct Checkout icon Direct Checkout1,000+ installs apply_filters( 'woocommerce_continue_shopping_redirect', wc_get_raw_referer() ? wp_validate_redirect( wc_get_raw_referer(), false ) : wc_get_page_permalink( 'shop' ) ) includes/AddToCart.php:606
  7. Decimal Product Quantity for WooCommerce icon Decimal Product Quantity for WooCommerce900+ installs apply_filters( 'woocommerce_continue_shopping_redirect', wc_get_raw_referer() ? wp_validate_redirect( wc_get_raw_referer(), false ) : wc_get_page_permalink('shop') ) decimal-product-quantity-for-woocommerce.php:363
  8. FooSales icon FooSales700+ installs apply_filters( 'woocommerce_continue_shopping_redirect', wc_get_raw_referer() ? wp_validate_redirect( wc_get_raw_referer(), false ) : wc_get_page_permalink( 'shop' ) ) admin/class-foosales-admin.php:3430
  9. Boopis WooCommerce RFQ icon Boopis WooCommerce RFQ50+ installs apply_filters( 'woocommerce_continue_shopping_redirect', wc_get_raw_referer() ? wp_validate_redirect( wc_get_raw_referer(), false ) : wc_get_page_permalink( 'shop' ) ) includes/class-boopis-rfq-front.php:554
  10. ShopExtra icon ShopExtra10+ installs apply_filters( 'woocommerce_continue_shopping_redirect', wc_get_raw_referer() ? wp_validate_redirect( wc_get_raw_referer(), false ) : wc_get_page_permalink( 'shop' ) ) includes/classes/Translations.php:339
  11. Woo Continue Shopping icon Woo Continue Shopping10+ installs apply_filters( 'woocommerce_continue_shopping_redirect', $store_url ? $store_url : get_permalink( wc_get_page_id( 'shop' ) ) ) views/continue_shopping_button.php:6
  12. GNA Miscellaneous icon GNA Miscellaneous10+ installs apply_filters( 'woocommerce_continue_shopping_redirect', wp_get_referer() ? wp_get_referer() : home_url() ) gna-miscellaneous-core.php:177
  13. Quote Requests for WooCommerce icon Quote Requests for WooCommerce10+ installs apply_filters( 'woocommerce_continue_shopping_redirect', $default_redirect ) src/functions/woocommerce.php:50
  14. Aiolos Checkout for WooCommerce icon Aiolos Checkout for WooCommerceFewer than 10 installs apply_filters( 'woocommerce_continue_shopping_redirect', $shop ? $shop : home_url( '/' ) ) src/Checkout/ThankYou.php:42

Need a customisation built on this hook?

Tell us what you want to change and which plugin it's for. We'll write it, test it and send it back as a small plugin.