GST-Compliant Invoices in WooCommerce: GSTIN & HSN Setup
If you're running a WooCommerce store in India, the invoice WooCommerce emails your customers by default won't hold up if a GST officer ever asks to see it. No GSTIN, no HSN code, no CGST/SGST split — just a generic order summary. Here's how to fix that properly, without breaking your checkout or your existing order numbers.
Symptom: Your WooCommerce Invoice Isn't Actually a Tax Invoice
Customers ask for a "GST bill" and you send them the order confirmation PDF — and their accountant bounces it back. Common complaints we see from Indian merchants:
- No GSTIN printed anywhere on the invoice or order email
- No HSN/SAC code against line items, so B2B buyers can't claim input tax credit
- Tax shown as one lump "Tax" line instead of split CGST + SGST (or IGST for inter-state orders)
- Invoice numbers that jump around, restart randomly, or match the WooCommerce order ID (which isn't sequential once you factor in abandoned/failed orders)
None of this breaks your store technically. It just means the paperwork won't survive an audit, and your B2B customers will keep emailing you for a "proper invoice."
Cause: WooCommerce Was Never Built for GST
WooCommerce is a US/EU-origin plugin. Its core invoice/order-email template has no concept of GSTIN, HSN codes, or India's dual-tax (CGST+SGST vs IGST) structure. Everything you need for a compliant invoice under Rule 46 of the CGST Rules has to be added on top — through settings, product data, and usually one plugin dedicated to invoice generation.
What a GST Invoice Legally Needs
Before touching WooCommerce, know what you're building toward. A valid tax invoice needs:
- Your business name, address, and GSTIN
- A unique, sequential invoice number for the financial year, with no gaps
- Invoice date
- Customer's name, address, and GSTIN (if they're a registered business)
- HSN or SAC code for each product/service line
- Taxable value per line item
- Tax rate and amount, split as CGST + SGST (same state) or IGST (different state)
- Place of supply
Fix: Set It Up in the Right Order
Step 1 — Add Your GST Details to WooCommerce
Go to WooCommerce → Settings → General and make sure your store address exactly matches your GST registration certificate — the state field especially, since it drives the CGST/SGST vs IGST decision later. There's no native GSTIN field in core WooCommerce, so this gets added by your invoice plugin in Step 4 — but get the address right first, everything downstream depends on it.
Step 2 — Tag Every Product With an HSN/SAC Code
WooCommerce doesn't ship an HSN field either. You'll add one of two ways:
- A custom field/attribute on each product (works for a small catalog)
- A bulk CSV import/export through Products → All Products → Export, adding an HSN column, then re-importing (much faster for 100+ SKUs)
Group products by category first — most catalogs only use a handful of distinct HSN codes, so you can bulk-assign by category instead of doing it one product at a time.
Step 3 — Configure Tax Classes for CGST/SGST and IGST
Under WooCommerce → Settings → Tax, you need two rate tables, not one:
| Scenario | Tax split | Example (18% GST) |
|---|---|---|
| Buyer in the same state as your business | CGST + SGST | 9% + 9% |
| Buyer in a different state | IGST | 18% |
Create separate tax rate rows for each, and make sure Enable Tax Rates → Calculate tax based on is set to Customer shipping address — if it's set to shop base address, every order gets CGST+SGST even for out-of-state buyers, and your invoices will be wrong on every inter-state sale.
Step 4 — Install a Dedicated GST Invoice Plugin
Core WooCommerce simply won't print GSTIN, HSN codes, or a CGST/SGST breakdown on a PDF no matter how you configure it — you need a plugin built for this (WooCommerce PDF Invoices & Packing Slips is the most common base, paired with a GST/India add-on, or a dedicated India-GST invoicing plugin). Once installed:
- Enter your GSTIN and business PAN in the plugin's settings, not WooCommerce's
- Map the HSN field you created in Step 2 to the plugin's invoice template
- Enable the CGST/SGST/IGST columns in the template — most plugins auto-detect which to show based on the tax rate names from Step 3, so name your tax rates consistently (e.g. "CGST", "SGST", "IGST", not "Tax 1")
Step 5 — Fix Sequential Invoice Numbering
This is the step people skip and the one that actually gets flagged in an audit. GST law requires invoice numbers to be sequential with no gaps, reset at the start of each financial year (April 1). WooCommerce order IDs are not this — they increment across abandoned carts, test orders, and failed payments, so gaps are guaranteed.
Your invoice plugin should have its own independent invoice-number counter, separate from the order ID. Set it to reset (or configure a new prefix, e.g. INV-2526-0001) on April 1 each year, and don't manually edit or delete invoice numbers once issued — void and reissue instead if you need to correct one.
Step 6 — Place a Test Order and Check the PDF
Before this goes live, place one test order from an address in your own state and one from a different state. Download both invoices and confirm:
- GSTIN appears for both your business and the customer (if provided)
- HSN code shows against each line item
- Same-state order shows CGST+SGST; different-state order shows IGST
- Invoice number follows your sequence, not the order ID
Prevention: Keep It Compliant Going Forward
- Never let two products go live without an HSN code — add it as a required field in your product creation checklist
- Re-check your tax rate rows whenever you register in a new state or your GST rate slab changes
- Back up the invoice sequence counter before any plugin update — a bad update resetting it mid-year is the most common way stores end up with duplicate invoice numbers
- If you sell B2B, add a GSTIN field at checkout (most GST plugins offer this) so it lands on the invoice automatically instead of customers emailing you to add it after the fact
Frequently asked questions
Does core WooCommerce support GST invoices out of the box?
No. Core WooCommerce has no GSTIN field, no HSN/SAC field, and no CGST/SGST/IGST split — it only calculates a flat tax total. You need a PDF invoice plugin with GST support layered on top to generate a compliant invoice.
Why does my invoice show IGST for a customer in my own state?
Check WooCommerce → Settings → Tax → 'Calculate tax based on'. If it's set to shop base address instead of customer shipping address, every order gets taxed as if the buyer is in your state, which breaks the split the other way for out-of-state orders. Set it to customer shipping address.
Can I just use the WooCommerce order number as my invoice number?
You can, but it's risky under GST rules, which require sequential numbering with no gaps. WooCommerce order IDs increment across failed and abandoned orders, so you'll end up with gaps. Use your invoice plugin's independent, GST-compliant numbering sequence instead.
Do I need different HSN codes for physical products vs services?
Yes — HSN codes are for goods, SAC (Services Accounting Code) codes are for services. If you sell both, make sure your invoice template pulls the correct code type per product/service line, not a single HSN field for everything.
What happens if I change my GST rate mid-year?
Update the tax rate value in WooCommerce → Settings → Tax immediately, but don't touch already-issued invoices. Orders placed before the change keep the old rate; only new orders after the update should reflect the new one. Test with a live order after any rate change to confirm the split still splits correctly.