No worries, Tuan! I just wanted you to be aware that the current formula is incorrect.
Here is the math explanation for the correct formula..
Reverse Fee Calculation:
Let
x be the price we charge to receive a specific payout
y. For Stripe, there is a transaction processing fee of 2.9%, that is, 0.029
x. There is an additional charge of $0.30 per transaction. We end up with the formula
x − 0.029
x − 0.30 =
y.
In the above example, we want the payout from Stripe to be
x − 0.029
x − 0.30 = 400. Simplify to
x − 0.029
x = 400.30, then to 0.971
x = 400.30. We find that
x = 400.30 / 0.971 = $412.2554. Rounded to two decimals = total payment of $412.26.
In other words,
(payout + transaction fee) / (1 – percentage fee).
Stripe calculates $412.26 * 2.9% = $11.96 + $0.30 transaction fee = $12.26. You get a payout of $400, and Bob’s your uncle!
Similarly, for PayPal, with 3.49% processing fee and $0.49 per transaction:
x − 0.0349
x − 0.49 = 400. Simplify to
x − 0.0349
x = 400.49, then to 0.9651
x = 400.49. We find that
x = 400.49 / 0.9651 = $414.97254, rounding to total payment of $414.97.
PayPal calculates $414.97 * 3.49% = $14.482453 + $0.49 transaction fee = $14.972453. Round to $14.97. You get a payout of $400.
The formula works for any combination of processing fee % and per transaction fee.
Screen grab from my Stripe account:
Regards,
Jay