The COD form can take a discount code, but the field is hidden on a new install. Open COD Form → Form customization and switch on the Discount Codes row in Manage form fields, then click it to open its settings.
The card gives you Discount code field label, Apply button text and Discount line text. Two error messages are editable too: Invalid discount code error text and Limit to 1 code error text. All of them are translatable on the Translations tab.
Limit to 1 discount code per order is on by default and is the setting most stores want. Turn it off only if you genuinely intend codes to stack.
The form reads discount codes that take a percentage off or a fixed amount off. Those reduce the order total, and the discount shows in the totals block. A free shipping code does not reduce the price: the customer is charged the full amount, and the code is recorded on the order. A buy X get Y code is worse. The form accepts it, shows the customer a discount taken off the whole subtotal, and then creates the order with no discount at all, so the customer is billed more than the form promised. Do not advertise a buy X get Y code alongside the form until we have fixed that. An automatic discount has no code, so anything the customer types for it is rejected as invalid.
If you also charge a COD fee, using a discount code moves that fee onto the shipping line of the order. This keeps a percentage discount off the fee, so the order total matches the figure the customer agreed to. Nothing changes for the customer, but the order looks slightly different in Shopify admin.
Create the codes themselves in Shopify admin, under Discounts, as ordinary code discounts.
Test each code you plan to advertise: a code that quietly does nothing is worse than no code at all.
Stuck on any of this? Open the chat in the bottom right corner of the app and we will help you set it up.