# Total Price of Shopping Cart

**URL:** <https://forum.wixstudio.com/t/total-price-of-shopping-cart/16103>\
**Category:** Ask the community\
**Tags:** code, question\
**Created:** [March 6, 2019, 4:53am UTC](https://forum.wixstudio.com/t/total-price-of-shopping-cart/16103 "2019-03-06T04:53:27Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![carriemittl](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/carriemittl/32/9739_2.png) [@carriemittl](https://forum.wixstudio.com/u/carriemittl)\
**Post date:** [March 6, 2019, 4:53am UTC](https://forum.wixstudio.com/t/total-price-of-shopping-cart/16103/1 "2019-03-06T04:53:27Z")

</div>

I am trying to access the total price of a shopping cart so I can calculate 60% of that total. Is there a way to easily access the total price of a shopping cart?

---

<div class="post-metadata">

**Author:** ![tony-brunsman](https://avatars.discourse-cdn.com/v4/letter/t/ea5d25/32.png) [@tony-brunsman](https://forum.wixstudio.com/u/tony-brunsman)\
**Post date:** [March 6, 2019, 3:15pm UTC](https://forum.wixstudio.com/t/total-price-of-shopping-cart/16103/2 "2019-03-06T15:15:06Z")

</div>

Carrie,

There is a way to do get the total price of the shopping cart. Be sure to scroll to the top to get a better idea what is involved.

> **[Events - Velo API Reference - Wix.com](https://www.wix.com/velo/reference/wix-stores-backend/events)**
>
> Events that are fired from a Wix Store.

---

<div class="post-metadata">

**Author:** ![carriemittl](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/carriemittl/32/9739_2.png) [@carriemittl](https://forum.wixstudio.com/u/carriemittl)\
**Post date:** [March 9, 2019, 1:28am UTC](https://forum.wixstudio.com/t/total-price-of-shopping-cart/16103/3 "2019-03-09T01:28:21Z")

</div>

It seems like the functions onCartAbandoned() and onCartRecovered() only fire under the following circumstances…

The onCartAbandoned() event handler runs when a visitor adds an item to the shopping cart, but does not complete the purchase within 1 hour.

The onCartRecovered() event handler runs when a visitor completes a purchase more than 1 hour after items have been added to a shopping cart.

How am I suppose to access the variable “totals” at any time I want instead of under the restrictions of the functions?

---

<div class="post-metadata">

**Author:** ![ulbnxt](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/ulbnxt/32/23022_2.png) [@ulbnxt](https://forum.wixstudio.com/u/ulbnxt)\
**Post date:** [August 26, 2020, 9:48pm UTC](https://forum.wixstudio.com/t/total-price-of-shopping-cart/16103/4 "2020-08-26T21:48:25Z")

</div>

@tony-brunsman hi Anthony i want to add a percentage to the total of the cart with a check box . For ex if the cart is 1500 once the person checks the box the total increases by 10% how do i do this . Thanks

---

<div class="post-metadata">

**Author:** ![manish41711](https://avatars.discourse-cdn.com/v4/letter/m/ccd318/32.png) [@manish41711](https://forum.wixstudio.com/u/manish41711)\
**Post date:** [October 9, 2020, 8:17pm UTC](https://forum.wixstudio.com/t/total-price-of-shopping-cart/16103/5 "2020-10-09T20:17:00Z")

</div>

Could not find any event related to cart totals on the page you mentioned.
