Title: Zero Total Order and process_payment method
Last modified: July 10, 2024

---

# Zero Total Order and process_payment method

 *  Resolved [miroslavps](https://wordpress.org/support/users/miroslavps/)
 * (@miroslavps)
 * [1 year, 11 months ago](https://wordpress.org/support/topic/zero-total-order-and-process_payment-method/)
 * Hi guys!
 * I am testing a third party payment plugin on WC 9.0.2 and looks like the Zero
   Total orders do not go throw process_payment method (overridden from WC_Payment_Gateway
   class).
 * Is this the new normal behavior? Any directions how to avoid this “problem” are
   welcome.
 * Regards!

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [carolm29 (woo-hc)](https://wordpress.org/support/users/carolm29/)
 * (@carolm29)
 * [1 year, 11 months ago](https://wordpress.org/support/topic/zero-total-order-and-process_payment-method/#post-17880893)
 * Hey there, [@miroslavps](https://wordpress.org/support/users/miroslavps/)! Thanks
   for contacting us.
 * Do you mind sharing more details about the issue you are facing?
 * What steps do you take that trigger the issue?
 * Also, which payment plugin are you testing? Have you contacted their support 
   regarding this? 🙂
 * Looking forward to your reply.
 * Have a wonderful day!
 *  Thread Starter [miroslavps](https://wordpress.org/support/users/miroslavps/)
 * (@miroslavps)
 * [1 year, 11 months ago](https://wordpress.org/support/topic/zero-total-order-and-process_payment-method/#post-17880975)
 * Thanks for the answer!
 * I am not sure what other details to provide. I test with same product. First 
   I put some price bigger than 0, so the Total is also bigger. I finish the order
   and the process goes go through process_payment(). There is a logger function
   in the method.
 * Then change the price of the same product to 0, use free shipping, so the Order
   total is 0, finish the order and there is no logged message from process_payment().
   I mark this as failed test because I save some custom data in the Order in process_payment(),
   which I use later.
 * Same test passed may be a month or less ago with WC 8.9.*. So instead of guessing
   I decide to ask directly is there any change in WC 9.0.1 or 9.0.2 who skip process_payment()
   when the order has total 0.
 * Regards!
 *  Plugin Support [Shameem – a11n](https://wordpress.org/support/users/shameemreza/)
 * (@shameemreza)
 * [1 year, 11 months ago](https://wordpress.org/support/topic/zero-total-order-and-process_payment-method/#post-17882233)
 * Hi [@miroslavps](https://wordpress.org/support/users/miroslavps/)
 * The `process_payment()` method is not triggered for orders with a total of 0 
   because there’s no actual payment to process.
 * If you need to save some custom data in the order when the total is 0, I would
   recommend using the `woocommerce_new_order` action hook. This hook is triggered
   whenever a new order is created, regardless of the total.
 * Please note that writing or providing custom code is not within the scope of 
   [our support policy](https://woocommerce.com/support-policy/). If you are still
   having problems, we recommend asking development questions on the #developers
   channel of the [WooCommerce Community Slack](https://woocommerce.com/community-slack/).
   Many of our developers hang out there and will be able to offer insights into
   your question. You can also seek help from the following:
    - A local web developer
    - [Codeable.io](https://woocommerce.com/codeable/)
    - [WooExperts](https://partners.woocommerce.com/English/marketplace/)
 * I wish I could help more, but hopefully, this gets you going in the right direction
   to get the job done.
 *  Thread Starter [miroslavps](https://wordpress.org/support/users/miroslavps/)
 * (@miroslavps)
 * [1 year, 11 months ago](https://wordpress.org/support/topic/zero-total-order-and-process_payment-method/#post-17882628)
 * Thank you!
 * I just needed to know if my observations are correct.
 * Regards!

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Zero Total Order and process_payment method’ is closed to new replies.

 * ![](https://ps.w.org/woocommerce/assets/icon.svg?rev=3234504)
 * [WooCommerce](https://wordpress.org/plugins/woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woocommerce/reviews/)

## Tags

 * [payment gateway](https://wordpress.org/support/topic-tag/payment-gateway/)
 * [third party plugins](https://wordpress.org/support/topic-tag/third-party-plugins/)
 * [woocommerce blocks](https://wordpress.org/support/topic-tag/woocommerce-blocks/)

 * 4 replies
 * 3 participants
 * Last reply from: [miroslavps](https://wordpress.org/support/users/miroslavps/)
 * Last activity: [1 year, 11 months ago](https://wordpress.org/support/topic/zero-total-order-and-process_payment-method/#post-17882628)
 * Status: resolved