What Is HSN Code In Tally and Why It Matters

Pranav Anand · June 13, 2026

HSN code in Tally is a 6 or 8-digit product classification system required for GST reporting and e-invoicing. It identifies goods for tax purposes, ensures compliance, and is mandatory in GSTR-1 if turnover exceeds Rs 5 crore.

Understanding HSN Code Basics

HSN stands for Harmonised System of Nomenclature. It is an international standard classification system used globally to identify and categorize products. In Tally, HSN codes serve as the bridge between your inventory and tax compliance. Every product you sell or purchase must be classified under a specific HSN code to ensure accurate GST calculation, proper tax reporting, and e-invoicing compliance.

The HSN code system is maintained by the World Customs Organization and adopted by India's tax authorities. In TallyPrime, HSN codes are linked directly to stock items, making it easier to generate compliant invoices and tax returns automatically.

HSN Code Structure and Format

HSN codes in India follow a standardized format:

  • 6-digit HSN code - used for goods with turnover below Rs 5 crore
  • 8-digit HSN code - used for goods with turnover of Rs 5 crore or above

The structure breaks down as follows: the first 2 digits represent the chapter, the next 2 digits the heading, the next 2 digits the subheading, and (if applicable) the last 2 digits represent further subdivisions. For example, HSN code 8471 represents automatic data processing machines, while 8517 covers telecommunications equipment.

In TallyPrime, you can enter either 6 or 8-digit codes depending on your business turnover. The system validates the format and ensures consistency across all invoices and tax reports.

Why HSN Codes Matter in Tally

HSN codes are not just administrative details, they are critical for compliance and operational efficiency. Here is why they matter:

  1. GST Compliance: HSN codes determine the correct GST rate applicable to each product. Incorrect codes can lead to wrong tax calculations and penalties.
  2. GSTR-1 Filing: If your annual turnover exceeds Rs 5 crore, you must report HSN codes in your GSTR-1 return. Tally auto-populates these from your invoices.
  3. E-Invoicing: HSN codes are mandatory for e-invoicing under the IRP (Invoice Registration Portal). Without them, you cannot generate IRN (Invoice Reference Number).
  4. Audit Trail: HSN codes create a transparent record of what you sold and at what tax rate, making audits smoother.
  5. Supply Chain Tracking: For e-way bills and goods tracking, HSN codes help identify products accurately.

Setting Up HSN Codes in TallyPrime

To set up HSN codes in TallyPrime, follow these steps:

  1. Open TallyPrime and go to Gateway of Tally > Inventory Info > Stock Items > Create
  2. Enter the stock item name (e.g., "Cotton Fabric - 100%")
  3. In the HSN/SAC Code field, enter the 6 or 8-digit code (e.g., 5208)
  4. Set the Opening Balance, Unit, and Rate
  5. Assign the appropriate GST Rate (5%, 12%, 18%, 28%, or 0%)
  6. Link the item to a Godown (warehouse) if needed
  7. Save by pressing Ctrl+S

Once saved, this HSN code is now linked to the item and will automatically appear in all sales and purchase invoices involving this product.

Linking HSN Codes to Stock Items

The power of Tally lies in its ability to link HSN codes directly to stock items. This ensures consistency and eliminates manual entry errors. When you create a stock item with an HSN code, every time you use that item in a voucher, the HSN code flows through automatically.

For example, if you create an item "Steel Pipes - 2 inch" with HSN code 7305 and assign it 18% GST, then every sales invoice using this item will automatically show HSN 7305 and apply 18% GST. This reduces errors and speeds up invoice creation.

You can also edit HSN codes for existing items. Go to Gateway of Tally > Inventory Info > Stock Items > Alter, select the item, modify the HSN code, and save. The change applies to future invoices.

HSN Codes vs. SAC Codes in Tally

While HSN codes classify goods, SAC (Service Accounting Code) codes classify services. Both are 8-digit codes, but they serve different purposes:

Feature HSN Code SAC Code
Type Goods classification Service classification
Digits 6 or 8 digits 8 digits
Example 8471 (Computers) 998961 (Accounting services)
Used in Sales/Purchase of goods Service invoices
Tally Entry Stock Items Ledger items or service invoices

In TallyPrime, if you are selling services (e.g., consulting, repairs, transportation), you use SAC codes instead of HSN codes. The system allows you to choose the appropriate code type based on whether you are dealing with goods or services.

HSN Code and GST Rate Mapping

Each HSN code corresponds to a specific GST rate set by the government. In Tally, you must ensure that the GST rate you assign to an item matches the official HST-GST rate mapping. Here are common examples:

  • HSN 1001 (Wheat) - 0% GST
  • HSN 2208 (Alcoholic beverages) - 28% GST
  • HSN 3004 (Medicaments) - 5% or 12% GST (depends on type)
  • HSN 6204 (Women's clothing) - 5% or 12% GST
  • HSN 8471 (Computers) - 18% GST
  • HSN 9406 (Prefabricated buildings) - 5% or 12% GST

TallyPrime includes a built-in HSN code database with standard GST rates. When you select an HSN code, Tally often suggests the correct rate, but you should verify it against the official GST rate schedule to avoid compliance issues.

HSN Codes in GSTR-1 and e-Invoicing

HSN codes play a central role in two critical compliance areas: GSTR-1 filing and e-invoicing.

GSTR-1 Filing: If your annual turnover exceeds Rs 5 crore, you must report HSN codes in your GSTR-1 return. In TallyPrime, go to Gateway of Tally > Display More Reports > GST Reports > GSTR-1. Tally automatically extracts HSN codes from your sales invoices and populates the report. Ensure all items have HSN codes assigned before filing.

E-Invoicing: Under the e-invoicing scheme, HSN codes are mandatory for all invoices. When you enable e-invoicing in TallyPrime and generate an invoice, the system sends the HSN code to the IRP (Invoice Registration Portal) to generate an IRN (Invoice Reference Number) and QR code. Without HSN codes, e-invoicing will fail.

Practical Example: HSN Code Setup in Tally

Let us walk through a real-world example. Suppose you run a textile business selling cotton fabric.

Scenario: You want to create a stock item "Premium Cotton Fabric" with the following details:

  • HSN Code: 5208 (Cotton fabrics)
  • Unit: Meter
  • Rate: Rs 500 per meter
  • GST Rate: 5%

Steps in TallyPrime:

  1. Go to Gateway of Tally > Inventory Info > Stock Items > Create
  2. Name: "Premium Cotton Fabric"
  3. HSN/SAC Code: "5208"
  4. Unit: "Meter"
  5. Opening Balance: (set as needed, e.g., 1000 meters)
  6. Rate: "500"
  7. GST Rate: "5%"
  8. Press Ctrl+S to save

Now, whenever you create a sales invoice and add this item, Tally will automatically populate HSN code 5208 and apply 5% GST. When you file GSTR-1 or generate an e-invoice, HSN 5208 will appear in the report with the correct tax classification.

Common HSN Code Mistakes to Avoid

Many businesses make errors with HSN codes in Tally. Here are the most common ones and how to avoid them:

  • Wrong HSN Code: Assigning an incorrect code (e.g., using 8471 for a printer instead of a computer). Always verify against the official HSN schedule.
  • Mismatched GST Rate: Assigning a 12% GST rate to an item that should be 5%. Check the HSN-GST rate mapping before saving.
  • Missing HSN Codes: Creating items without HSN codes. This causes GSTR-1 and e-invoicing failures. Always fill this field.
  • Inconsistent Codes: Using different HSN codes for the same product across invoices. Link the code to the item to ensure consistency.
  • Forgetting to Update: Not updating HSN codes when government changes the classification. Stay informed about GST rate changes.

Managing HSN Codes for Multiple Items

If you have a large inventory, managing HSN codes can be challenging. TallyPrime offers features to simplify this:

  • Bulk Import: Use the import feature to load multiple items with HSN codes at once via Excel or CSV.
  • Search and Edit: Use Alt+F1 to search for items and edit their HSN codes in batch.
  • Reports: Generate stock item reports to verify all items have HSN codes assigned.
  • Godown Tracking: Link items to specific godowns and track HSN codes by location.

HSN Code Updates and Government Changes

The government periodically updates HSN codes and GST rates. TallyPrime users with active TSS (Tally Support Services) receive automatic updates to the HSN code database. This ensures your system always reflects the latest classifications and tax rates.

If your TSS is active, TallyPrime will notify you of updates. If your TSS has expired, you can still use Tally, but you won't receive automatic updates. To renew TSS for Silver, it costs approximately Rs 4,500 per year; for Gold, approximately Rs 13,500 per year (plus 18% GST). Early renewal adds about one free month.

Troubleshooting HSN Code Issues in Tally

If you encounter issues with HSN codes in Tally, here are some solutions:

  • HSN Code Not Appearing in Invoice: Ensure the stock item has the HSN code assigned. Edit the item and verify the code is saved.
  • E-Invoicing Fails Due to HSN: Check that the HSN code is valid and matches the product type. Invalid codes will cause IRN generation to fail.
  • GSTR-1 Shows Incorrect HSN: Verify the item's HSN code and GST rate. Run a voucher report to confirm the code is being used correctly.
  • Data Corruption: If HSN codes are missing or corrupted, go to F1 (Help) > Troubleshooting > Repair or use Alt+Y (Data) > Repair. Always back up your data first.

HSN Codes and Tally Cloud

If you use Tally on Cloud, HSN codes work exactly the same way as on-premise Tally. You can access TallyVault for secure backup and recovery of your HSN code configurations. Tally Cloud offers bring-your-own-licence hosting from approximately Rs 175-290 per user per month, or with licence included from approximately Rs 899-1,299 per month. You can access Tally Cloud securely from Windows, Mac, Linux, Android, and iOS devices with approximately 99.9% uptime and daily backups.

Key Takeaways on HSN Codes in Tally

HSN codes are essential for tax compliance, e-invoicing, and accurate GST reporting in Tally. They classify products, ensure correct tax rates, and automate compliance processes. Whether you are a small business or a large enterprise, setting up HSN codes correctly in TallyPrime is non-negotiable. Always verify codes against the official schedule, link them to stock items, and keep them updated with government changes. With proper HSN code management, you can file GSTR-1, generate e-invoices, and maintain audit compliance effortlessly.

If you need expert guidance on HSN code setup, Tally configuration, or GST compliance in TallyPrime, contact Global IT Care, a Tally 3 Star Certified Partner in Purnea, Bihar, serving businesses since 2010. We offer training, implementation, and support for all Tally modules. Reach out to us at +91 75469 00951 via WhatsApp or visit our office in Purnea to discuss your Tally needs. Let us help you master HSN codes and ensure seamless tax compliance.

Frequently asked questions

What does HSN code mean in Tally?

HSN (Harmonised System of Nomenclature) code is a 6 or 8-digit classification used in Tally to identify products for GST, e-invoicing, and tax calculation purposes.

Is HSN code mandatory in Tally?

HSN codes are mandatory in GSTR-1 if your turnover exceeds Rs 5 crore. For e-invoicing, they are always required. TallyPrime makes entry automatic once configured.

How do I add HSN codes to items in Tally?

Go to Gateway of Tally > Inventory Info > Stock Items > Create. Enter the item name, select HSN code from the dropdown, set rate and tax. Save.

Can I change HSN code after creating an item?

Yes. Open the item in edit mode (Alt+E), modify the HSN code field, and save. It won't affect past transactions but applies to future ones.

What's the difference between HSN and SAC codes?

HSN codes classify goods (6-8 digits). SAC codes classify services (8 digits). Tally supports both; use SAC for service invoices instead of HSN.

Does Tally auto-fill HSN in invoices?

Yes. Once you link HSN to a stock item, Tally auto-populates it in sales/purchase vouchers. For e-invoicing, it flows directly to IRN generation.