1. Knowledge Base
  2. Woocommerce
  3. Snippets
  4. Add conversion tracking script to Woocommerce thank-you page

You may find yourself wanting to add some conversion tracking script into the thank-you page for woocommerce. Here is an example for how to do that:

add_action( 'woocommerce_thankyou', 'custom_script_for_thankyou');
function custom_script_for_thankyou() {

The above should be added to your child themes functions.php file.

Was this article helpful?