View Categories

Add Payment Gateway Costs to Order Profit

Adding payment gateway costs lets you record the transaction fee each gateway charges you, so your WooCommerce profit figures reflect what a payment method really costs. Cost of Goods: Product Cost & Profit Calculator for WooCommerce lets you set a fixed and/or percentage cost per gateway, and it is free.

Payment gateway cost settings in Cost of Goods

Important: these are internal cost figures used only to calculate order cost and profit. They are not added to the order total the customer pays and do not appear at checkout.

Step-by-step #

  1. Go to WPFactory > Cost of Goods (also reachable at WooCommerce > Settings > Cost of Goods).
  2. Open the Payment Gateways sub-tab.
  3. Tick Enable Payment Gateways section.
  4. Click Save changes so the per-gateway fields appear.
  5. For each gateway, set a Fixed cost, a Percent cost (and optional Max value cap), and/or a Fixed profit.
  6. Click Save changes again.

Options reference #

Label Option ID Default
Enable Payment Gateways section alg_wc_cog_gateways_values_enabled no
Fixed cost (per gateway) alg_wc_cog_gateway_costs_fixed[{gateway}] 0
Percent cost (per gateway) alg_wc_cog_gateway_costs_percent[{gateway}] 0
Max value (percent cap) alg_wc_cog_gateway_costs_percent_max_value[{gateway}] 0
Fixed profit (per gateway) alg_wc_cog_gateway_profit_fixed[{gateway}] 0

Fields appear for every active gateway, including default ones (Direct bank transfer, Check payments, Cash on delivery) and any custom gateway. The Percent cost is taken from the order total base set in Orders > Calculations > Order total.

After changing costs #

New settings apply to new orders. To update existing orders, recalculate with the Tools > Orders recalculation tool (Pro).

Get more from Cost of Goods #

Gateway costs are free. Cost of Goods: Product Cost & Profit Calculator for WooCommerce Pro adds the orders recalculation tool and cost and profit inside WooCommerce Analytics. See what Pro unlocks.

 

Cost of Goods Sold (COGS): Cost & Profit Calculator for WooCommerce