
Cash-on-Delivery Fee / Prepayment Discount for OpenCart 2.3, 3.x and 4.x
COD fee and prepayment discount for OpenCart 3 and 4: a separate line in the order total, % or fixed amount, VAT-aware. Pro adds conditional rules.
- Compatibility
- OpenCart 2.3.0.0 – 2.3.0.2 · 3.0.2 – 3.0.5.0 · 4.0.2 – 4.1.x
- PHP
- 7.4 or newer
- Version
-
v1.1.3 (OpenCart 4)
v1.1.3 (OpenCart 3.x)
v1.0.3 (OpenCart 2.3) - Licence
- two sites, lifetime
- Trial
- 7 days, no card, one per site
- Updated
- 26 October 2026
The module in action — 35 sec
Clear even without sound: Ukrainian subtitles
What Free has,
and what Pro adds
The free version works with no time limit. Pro adds the rest of the features in the table.
What it looks like

The trial starts when you ask
A fresh install is the free version, nothing switches on by itself. The “Try Pro for 7 days” button → e-mail → the key right in the window and by e-mail.

One key — two sites
Moving the store? Unbind the licence on the old domain and activate it on the new one yourself. For studios — keys for 5 or 25 sites, or unlimited.
Technical requirements
OpenCart 4.0.2–4.1.x — build cc_codfee.ocmod.zip v1.1.3
OpenCart 3.0.2–3.0.5.0 — a separate build, cc_codfee-oc3.ocmod.zip v1.1.1
OpenCart 2.3.0.0–2.3.0.2 — a separate build, cc_codfee-oc2.ocmod.zip v1.0.2
PHP 7.4+ for the OC3 and OC4 builds (tested on 8.1–8.3); the 2.3 build already runs on PHP 5.6 and 7.0
No external services: the calculation happens entirely on your server
Version history
A purchased licence for OpenCart now works without expiry.
Fixed the link to the module page in the admin.
The payment and shipping method pickers in the settings show real names again.
All versions (9)
A purchased OpenCart licence works with no time limit.
The OpenCart 3.0.x build has moved to a server-side licence.
A rule restricted by customer group didn’t fire on a guest order.
A separate build for OpenCart 2.3.0.0–2.3.0.2, PHP 5.6 and 7.0.
OpenCart 4.x.
Of both builds.
Frequently bought with Cash-on-Delivery Fee / Prepayment Discount for OpenCart 2.3, 3.x and 4.x
4 modules in one order — 40% cheaper than separately


Nova Poshta Premium — a Nova Poshta module for OpenCart 2.3, 3.x and 4.x

LiqPay — Card Payments for OpenCart 2.3, 3.x and 4.x

Telegram notifications and Viber/SMS for customers for OpenCart
Full module description
Cash on delivery costs a store money: the carrier’s fee, return shipping for refused parcels, tied-up cash and a percentage of unclaimed orders. COD Fee / Prepayment Discount lets you shift that difference into the checkout: the chosen payment method adds a separate line to the order total — a surcharge or a discount. The customer sees it before confirming the order, and the amount recalculates every time they switch payment method.
How it works, step by step
- You create a rule: choose a payment method (for example “Cash on delivery”), a mode — surcharge or discount — and an amount type — fixed or a percentage of the base.
- Set the limits. For a percentage, you set a min and a max: 5% of 499 UAH gives 30 UAH if the minimum is 30; 5% of a large order hits the maximum.
0means no limit. - Restrict the cart range — “from / to”. The fee won’t apply to orders cheaper or more expensive than the given amounts.
- Choose a tax class for the line, if the fee needs to be subject to VAT. The line’s sort order must be lower than the sort order of the “Tax” total (5 by default) — the recommended value is 4.
- At checkout, the customer selects a payment method — the line appears or disappears, the total recalculates, and the same value is written into the order.
- With Pro you can have as many rules as you like: they’re checked by priority (a lower number means higher priority), and the conditions also include shipping method, product category in the cart, customer group and a date range.
Under the hood
- The standard totals mechanism. This is a full-fledged
total-type extension — the line sits alongside “Sub-Total”, “Shipping” and “Tax”, so it lands in the order, emails and reports without any separate workarounds. - Different signatures in OC3 and OC4. In OpenCart 3.0.5 the total method takes
getTotal($total)with atotals / taxes / totalarray, while OpenCart 4 uses three separate references. The port handles both, so the same calculator gives the same result on both branches. - Normalising the payment method code. OpenCart 3 stores
codin the session, OpenCart 4 storescod.cod. The module reduces both formats to the base code, so a rule set up once works on any version. - No tax surprises. The line can be assigned a tax class, and VAT is calculated from the fee itself — provided the sort order relative to the “Tax” total is correct.
How to install
- OpenCart 4.x: download cc_codfee.ocmod.zip, install it via “Extensions → Installer”, then “Extensions → Order Totals” → “COD Fee” → “Install” → “Edit”.
- OpenCart 3.0.x: download cc_codfee-oc3.ocmod.zip, install it via “Extensions → Installer”, refresh the cache in “Extensions → Modifications”, then go to “Extensions → Order Totals”.
- OpenCart 2.3.x: download cc_codfee-oc2.ocmod.zip, unpack it and upload the contents of the
upload/folder to the store root via FTP or your hosting file manager. The standard 2.3 Installer only copies files over FTP and doesn’t work on most hosting, so installation is manual. Then go to “Extensions → Order Totals” → “Install” → “Edit”. The core isn’t patched:install.xmlin the archive only registers the extension in the modifications list. - Enable the status, enter the line name (for example “COD Fee”), choose a payment method and set an amount or percentage.
- Check that the payment method you need is actually installed under “Extensions → Payment” — otherwise it won’t appear in the list.
- If the fee should be subject to VAT, choose a tax class and set the sort order to 4 (lower than the sort order of the “Tax” line).
- For Pro: click “Try Pro” — in the window, either take the 7-day trial by email or paste a purchased key on the “I have a key” tab. Once activated, all rules take part in the calculation, not just the basic one; the first matching rule by priority applies.
Questions
about the module
Didn't find the answer? Message us on Telegram and we'll reply within a business day.
Why isn't the fee line visible in the cart?
The payment method is chosen at checkout, so it isn't known yet in the cart. The line appears in the total once the customer has selected a payment method.
Can I charge a percentage but not less than a fixed amount?
Yes. Choose the “percentage” type and set the lower bound in the “min” field. “Max” works the same way: 5% of a large order won't exceed the ceiling you set. 0 in both fields means no limits.
How do I set up a prepayment or pickup discount?
Create a rule with “Discount” mode and select the online payment methods in it. A pickup discount is a Pro rule with a shipping-method condition.
Is the fee subject to VAT?
If needed, yes — assign the line a tax class. One nuance to note: the fee line's sort order must be lower than the sort order of the “Tax” total (5 by default), otherwise tax won't be calculated on the fee. The recommended value is 4.
Why isn't the payment method I need in the list?
The module only shows methods that are actually installed under “Extensions → Payment”. Install the method you need and it will appear in the selection.
Is it one build for OpenCart 3 and 4?
No, it's two separate ports in one package: cc_codfee.ocmod.zip for 4.0.2–4.1.x and cc_codfee-oc3.ocmod.zip for 3.0.2–3.0.5.0. The settings and calculation logic are identical.
Does the licence need renewing?
No. For OpenCart the licence is perpetual, so all rules keep applying. Only the 7-day trial ends: after it the extra rules stay saved, and only the first (basic) free-version rule applies.
No reviews yet. Be the first.
No questions yet. Ask one — we answer within 24 hours.
Not quite what you are looking for?
We build custom modules for WordPress, WooCommerce, OpenCart and Shopify. Tell us about the task and we'll prepare an estimate.
Order a custom module
Buying the module
—
