{"id":45,"date":"2018-05-11T06:29:49","date_gmt":"2018-05-11T06:29:49","guid":{"rendered":"https:\/\/meetanshi.com\/blog\/2018\/05\/11\/apply-indian-gst-in-magento-2\/"},"modified":"2025-04-23T12:53:17","modified_gmt":"2025-04-23T07:23:17","slug":"apply-indian-gst-in-magento-2","status":"publish","type":"post","link":"https:\/\/meetanshi.com\/blog\/apply-indian-gst-in-magento-2\/","title":{"rendered":"How to Apply Indian GST in Magento 2"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/www.gst.gov.in\/\" target=\"_blank\" rel=\"noreferrer noopener\">Goods and Service Tax<\/a>&nbsp;(GST) is a value-added tax levied at all points in the supply chain on products and services. It was introduced in India on 1 July, 2017 which put an end to multiple taxes charged by Central and State Government.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Being the most popular platform, Magento 2 store owners are in a race to implement GST in their stores at the rate of knots. They need to develop and implement a system which integrates Indian GST to their Tax Calculation in Magento 2. Here I\u2019m sharing the detailed guide to&nbsp;<strong><em>apply Indian GST in Magento 2<\/em><\/strong>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Before starting to create GST rules and rates, store owners need to find GST rate under which their products fall. The GST rates for all the products can be found under&nbsp;<a href=\"https:\/\/www.taxmann.com\/research\/gst\" target=\"_blank\" rel=\"noreferrer noopener\">GST Rate Finder<\/a>&nbsp;website objectively created by the Indian government. Once you find GST rates for your store products, you can start creating GST tax rules and rates in Magento 2.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In the below steps, we are considering the GST rate as 5%, origin of the business i.e state as Gujarat. Here, the business location plays vital role in calculating CGST-SGST or IGST. If the selling is performed Intra-state, CGST (2.5%) and SGST (2.5%) will be applied and equally divided to make GST. But if the selling is performed Inter-State, IGST (5%) will be applied. Let\u2019s have a look at detailed steps to apply Indian GST in Magento 2.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Steps to Apply Indian GST in Magento 2<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">1.  First of all, you need to create 3 new tax rules named SGST, CGST and IGST. Go to&nbsp;<strong>Stores &gt; Taxes &gt; Tax Rules<\/strong>&nbsp;and click on \u201c<strong>Add New Tax Rule<\/strong>\u201d. Name it and click add new tax rate to add tax rate for the rule you are creating.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2018\/02\/1_Create-new-tax-rule.png\" alt=\"Create a new ta rule\" class=\"wp-image-2997\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">2. While creating SGST and CGST, you have to set the rate to 2.5% and state as Gujarat as we are considering as the business origin. But for IGST, you have to set the tax rate to 5% and you have to create as many rules for it as many states are there in India i.e 29 rather than Gujarat. Click save once done.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2018\/02\/2_Create-Tax-rate.png\" alt=\"2_Create-Tax-rate\" class=\"wp-image-2998\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">3. Now from Additional Settings, create product tax class named GST and select the same for all 3 CGST, SGST and IGST Rules.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2018\/05\/3_Additional-Settings.png\" alt=\"3_Additional-Settings\" class=\"wp-image-3001\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">4. Create tax rules and rates for SGST and IGST as explained. Once done, the saved rules can be seen enlisted under&nbsp;<strong>Tax Rules<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2018\/05\/4_Saved-tax-rules.png\" alt=\"4_Saved-tax-rules\" class=\"wp-image-3002\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">5. Tax Rates for CGST, SGST and IGST can be seen under&nbsp;<strong>Stores &gt; Taxes &gt; Manage Tax Zones &amp; Rates<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2018\/05\/5_Saved-tax-rates.png\" alt=\"5_Saved-tax-rates\" class=\"wp-image-3004\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">6. Now, SGST and CGST are equally divided in two halves of the amount of tax rates, i.e., 5%. According to the government rule, sellers have to split and bifurcate CGST and SGST taxes separately in order details and invoices for every single order.To bifurcate GST taxes to show separately in all the order related documents, you have to custom code as default Magento 2 doesn\u2019t provide the facility.Copy file from<strong>&nbsp;Magento_Root\/vendor\/magento\/module-tax\/view\/frontend\/web\/js\/view\/checkout\/summary\/tax.js&nbsp;<\/strong>and paste it in&nbsp;<strong>Magento_Root\/app\/design\/frontend\/[Your_Theme]\/Magento_Tax\/view\/frontend\/web\/js\/view\/checkout\/summary\/tax.js<br><\/strong><br>Add following code in the copied file at line no. 99<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">var taxSegment = totals.getSegment('tax');\n    amount = amount \/ taxSegment['extension_attributes']['tax_grandtotal_details']['0']['rates']['length'];<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">After adding, the whole code will look as<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">formatPrice: function (amount) {\n            var taxSegment = totals.getSegment('tax');\n            amount = amount \/ taxSegment['extension_attributes']['tax_grandtotal_details']['0']['rates']['length'];\n            return this.getFormattedPrice(amount);\n        },<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">7. Now&nbsp;assign tax class as GST to all the&nbsp;products in&nbsp;<strong>Products &gt; Catalog&nbsp;<\/strong>using update attributes action<strong>.&nbsp;<\/strong>Simply go to&nbsp;<strong>Product &gt; Catalog<\/strong>, select products, select&nbsp;<strong>Update Attributes<\/strong>&nbsp;action from the dropdown, go to&nbsp;<strong>Tax Class<\/strong>, tick&nbsp;<strong>Change<\/strong>&nbsp;and set&nbsp;<strong>GST<\/strong>&nbsp;from the dropdown.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2018\/05\/6_update-attributes.png\" alt=\"6_update-attributes\" class=\"wp-image-3005\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">8. To display the tax summary in detail, set Yes to \u201c<strong>Display Full Tax Summary<\/strong>\u201d in&nbsp;<strong>Stores &gt; Configuration &gt; Sales &gt; Tax &gt; Shopping Cart Display Settings<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2018\/05\/7_Shopping-cart-display-settings.png\" alt=\"7_Shopping-cart-display-settings\" class=\"wp-image-3006\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">9. Now when you have followed all the steps above, you are ready to see the GST applied on Magento 2 products. Simply add products to cart, select country and state. Here, set Gujarat state to check CGST-SGST applied on order.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2018\/05\/8_SGST-CGST-applied-on-order.png\" alt=\"8_SGST-CGST-applied-on-order\" class=\"wp-image-3008\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">10. Now to check the application of IGST, select states other than Gujarat for which you have created rules and rates. Here, we have selected Karnataka to get you&nbsp;an&nbsp;idea on how IGST will be applied.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2018\/05\/9_IGST-applied-on-order.png\" alt=\"9_IGST-applied-on-order\" class=\"wp-image-3009\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">The above steps are enough to apply GST in Magento 2. But it needs you to create 29 tax rates for IGST, don\u2019t you think it takes your much time and efforts?! Also, what if you have products which belong to multiple tax rate slabs? You have to create as many rules and rates for each.  <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If you want to be out of this hassle and have an automated system to apply GST in Magento 2 store products, take a look at our&nbsp;<a href=\"https:\/\/meetanshi.com\/magento-2-indian-gst.html\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Magento 2 GST India<\/strong><\/a>&nbsp;extension which has oh so wow! features to add GST with ease. Try our Free&nbsp;<a href=\"https:\/\/meetanshi.com\/gst-calculator\" target=\"_blank\" rel=\"noreferrer noopener\">GST Calculator<\/a>&nbsp;to calculate the GST rates more accurately in a precise way.&nbsp;Adding GST in Magento 2 was never easy before, take a look at the detailed features and give a try using the&nbsp;<a href=\"https:\/\/meetanshi.in\/m2d7\/index.php\/admin\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>live demo<\/strong><\/a>. I\u2019m sure you will love using automation rather the above manual steps!<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Let me know how much time did it take to apply GST in Magento 2 manually? Also, if you stuck somewhere, have queries or want to give feedback, comment down below, I\u2019m always ready to welcome your words! Don\u2019t forget to hit the 5 stars to appreciate our tutorial.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Goods and Service Tax&nbsp;(GST) is a value-added tax levied at all points in the supply chain on products and services. It was introduced in India&#8230;<\/p>\n","protected":false},"author":5,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[34],"tags":[],"class_list":["post-45","post","type-post","status-publish","format-standard","hentry","category-magento"],"acf":[],"_links":{"self":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/45","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/comments?post=45"}],"version-history":[{"count":3,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/45\/revisions"}],"predecessor-version":[{"id":12583,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/45\/revisions\/12583"}],"wp:attachment":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/media?parent=45"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/categories?post=45"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/tags?post=45"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}