What It Does
Generates credit notes for eligible WHMCS invoices, with PDF downloads and a Net/VAT/Total breakdown. Review the accounting treatment and document requirements with your accountant; negative amounts alone do not establish legal compliance.
Features
- Automatic credit note generation on invoice refund
- Professional PDFs matching WHMCS invoice style
- Diagonal "CREDIT NOTE" watermark
- Negative amounts on the credit note PDF
- Net/VAT/Total breakdown with VAT rate
- Client self-service portal
- CSV and Excel export
- Optional Nextcloud integration
- 7 languages included
Check the financial effect first
Generating a credit note also adds account credit equal to the full invoice total. It is not a PDF-only action and does not calculate a partial credit from the refunded transaction amount. This applies to manual generation as well as automatic generation.
Before enabling automatic generation, test your refund workflow and check whether it already returns money or adds account credit. Do not use this module for partial-refund documentation without confirming that its full-invoice credit behavior is appropriate. After an error, check the client's balance and activity log before retrying generation.
Requirements
- WHMCS 8.9+
- A PHP version supported by your WHMCS release and the supplied module package, with the matching ionCube Loader for encoded files.
- MySQL 5.7+
Installation
- Upload files to
/modules/addons/credit_notes/ - Go to Setup → Addon Modules
- Activate "Credit Notes"
- Enter your license key
- Configure settings (or leave defaults)
Review numbering, allowed invoice statuses and the financial effect above, then test a controlled refund before enabling automatic processing for customers.
How It Works
- Invoice gets refunded in WHMCS
- With automatic generation enabled and the invoice status allowed, the module generates the credit note and adds full-invoice account credit
- PDF is generated and stored
- Client can view/download in their billing area
- Optional: PDF uploads to Nextcloud automatically
Admin Features
- View all credit notes with statistics
- VAT breakdown columns: Net (excl. VAT), VAT %, VAT amount, Total (incl. VAT)
- Export to CSV or Excel
- Manual generation for invoices in the configured allowed statuses, subject to the existing-credit-note check
- Resend credit note emails
- View and download PDFs
- Bulk export all PDFs to ZIP
- Upload to Nextcloud (individual or bulk)
Client Features
- "My Credit Notes" link in Billing sidebar
- View credit notes online
- Download PDFs
- See credit amount and linked invoice
PDF Output
Generated PDFs include:
- A WHMCS-style layout with module PDF styling settings
- Diagonal "CREDIT NOTE" watermark (blue)
- Company logo and address
- VAT/Tax ID
- Client billing info
- Net/VAT/Total breakdown with VAT rate
- Negative amounts
- Generation timestamp
Configuration
Auto Generate: Enable/disable automatic generation (default: on)
Auto Email: Send PDF to client automatically (default: off)
Credit Note Format: The default is CN{NUMBER}. Available tokens are {NUMBER}, {YEAR} and {MONTH}.
Number Padding: Controls the digits in the number portion; the default is 5.
Next Credit Note Number: A one-shot override for the next document, cleared after use. Check existing numbers before changing it.
Reset Numbering Yearly: Optional annual counter reset. Agree the numbering policy with your accountant before enabling it.
PDF Settings: Configure document styling in the addon. PDF labels use the language files, with Unicode font support.
Create To-Do on Error: Admin notification if generation fails (default: on)
Description Template: Customize credit description text
Email template: Customize the Credit Note Generated template under WHMCS Email Templates. The email hook attaches the generated PDF.
Allowed Invoice Statuses: Comma-separated list of invoice statuses eligible for credit note generation (default: Refunded). Useful if WHMCS sets invoices to "Collections" instead of "Refunded" after a refund transaction.
Language Support
Included translations:
- English
- Dutch
- French
- German
- Italian
- Russian
- Spanish
Add more by creating lang/[language].php following the existing format.
Nextcloud Integration
Optional feature requires Nextcloud Invoice Feeder module.
How it works
With Nextcloud Invoice Feeder active and configured, generated credit-note PDFs upload to its configured folder hierarchy under CreditNotes. Test the integration with a document before relying on automatic delivery.
Features
- Automatic upload on generation
- Duplicate detection (won't overwrite unless forced)
- Retroactive upload for existing credit notes
- Bulk upload capability
- Same folder structure as invoices
Troubleshooting
Credit notes not generating:
- Check module is activated
- Verify "Enable Auto Generate" is on
- Check invoice status matches "Allowed Invoice Statuses" setting
- Review WHMCS activity log
Client can't see credit notes:
- Verify they have refunded invoices
- Check module is active
- Clear template cache
PDF not generating:
- Check WHMCS can write to temp directory
- Verify TCPDF library exists (included in WHMCS)
- Check error logs
Nextcloud upload failing:
- Check Nextcloud Invoice Feeder module is active
- Verify WebDAV credentials in Nextcloud Invoice Feeder settings
- Test Nextcloud Invoice Feeder with invoices first
- Check activity log for specific errors
- Try manual upload to see specific error
Database
Creates one table: mod_credit_notes_mapping
Stores invoice/credit linkage, credit note numbers, client info, amounts, status tracking, and email sent status.
License
Licensed per WHMCS installation.
Purchase: Credit Notes for WHMCS
Invalid license? Module shows warning and disables credit note generation until valid key is entered.