Configuring Taxes in Magento 2 is an important process that needs to be paid much attention to, especially in eCommerce. Different countries have different taxing systems. Correspondingly before setting up tax rules, tax rates or tax classes in Magento 2 you need to be well-aware of the tax requirements of your country. 

In this article, you'll learn everything you need to know about taxes in Magento 2, how to manage tax rates, set up tax classes, create tax rules and calculations.

In Magento 2 taxes are auto-calculated based on tax rules. Tax rules, on the other hand, depend on customer, product tax classes as well as customers' shipping and billing addresses, and store location.

Confused already?

No worries. We'll walk you through the Magento 2 tax configuration step-by-step, so you can configure taxes in your Magento 2 store easily.

Post Contents [hide]

    Create Tax Rates in Magento 2

    As it was already mentioned, every country has its own tax system so tax rates depend on the customer geographical area. So, the first step you have to take is to configure tax rates.

    Since every tax zone and rate has its own identifier you can have multiple tax rates for one geographical area (in case a place has taxes only on some items).

    To configure tax rates in Magento 2:

    1. Go to Stores > Taxes > Tax Zones and Rates. Here you'll be able to edit the current Tax Rate or Add New Tax Rate.

    Magento 2 Tax Rates

    2. Fill out the Tax Rate Information on the tax rate page.

    • Set the Tax Identifier.
    • Check the Zip/Post is Range to be able to set the tax rates for a range of ZIP or Postal Codes.

    Note: once you check this option you will have to set Range From and Range To to define range by first and last ZIP or postal code.

    • Enter the Zip Code/Post Code to apply a tax to a single ZIP code or postal code.

    Note: the asterisk (*) is used to match up to ten characters in the code. 

    • Choose the State and Country to apply the Tax Rate for.
    • Set up the Rate Percent.

    Magento 2 New Tax Rate

    Remember to Save the new tax rate.

    Configure Tax Classes in Magento 2

    Magento offers you to set up 3 different tax classes by default: customer, product and shipping. Tax class together with the tax rate define the final tax amount that is calculated while product purchase.

    Follow these steps to set up tax classes in Magento 2:

    1. Navigate to Stores > Configuration > Sales > Tax and find the Tax Classes section.

    Magento 2 Sales Configuration

    2. Set up Tax Class for Shipping and Default Tax Class for Product. Both of them have similar options to choose from.

    • Taxable Goods
    • Refund Adjustments
    • Gift Options
    • Order Gift Wrapping 
    • Item Gift Wrapping
    • Printed Gift Card
    • Reward Points

    Except for the default tax class in the configuration, you can set different tax classes when creating a product.

    3. Set the Default Tax Class for Customers

    Retail Customer is the default option Magento provides. However, you can create different customer tax classes in your store and assign them to customer groups. Then, correspondingly, each customer will belong to some specific tax class.

    Note: you can add tax classes in Magento 2 when creating tax rules.

    Magento 2 Tax Classes

    Set Up Tax Rules in Magento 

    Once you finish setting up tax rates and tax classes you can create the tax rules to define what conditions will taxes be calculated under.

    To create tax rules in Magento 2:

    1. Go to Stores > Taxes > Tax Rules and press the Add New Tax Rule button.

    2. Set the Tax Rule Information.

    • Give the tax tule a Name.
    • Choose the Tax Rate from the list of available rates or Add New Tax Rate manually.

    Magento 2 New Tax Rule

    Magento also provides you an option to Import and Export Tax Rates directly on the tax rule page.

    Magento 2 Import Tax Rates

    3. Fill out Additional Settings.

    • Choose the Customer and Product Tax Classes or Add New Tax Classes by simply entering the tax name.
    • Set up the Tax Class Priority. It defines the priority of the tax if there are 2 or more applicable taxes.

    Note: if two tax rules have the same priority and can be applied, the taxes are added together and if two taxes apply but have different priorities taxes are compounded.

    • Check the Calculate off Subtotal Only, if you want taxes to be based on the order subtotal.
    • Set the Sort Order, which defines the tax rule's place in the tax rules grid.

    Magento 2 Tax Rates  Additional Settings

    Don't forget to Save the tax rule after you finish.

    Tax Calculation Settings

    Once you set up tax rates, classes and rules you are almost there. However, you also have to configure how taxes will be calculated: on all products in cart or single item, shipping address or shipping origin, before or after discounts.

    Taxes are location-based. So, the tax calculation settings will also depend on where your store is located.

    To configure tax calculation:

    1. Define how you want the tax to be calculated in the Tax Calculation Method Based On field. You can choose to calculate taxes based on:

    • Unit Price - separate product price
    • Row Total - sum of products in cart without discounts
    • Total - order total

    2. In Tax Calculation Based On field set the address tax will be calculated based on. You can base tax calculation based on Billing, Shipping Address or Shipping Origin.

    3. Choose whether prices entered from the Admin Panel include taxes in Catalog Prices.

    4. Set whether shipping amounts entered from admin panel include taxes in Shipping Prices.

    5. Select when to Apply Customer Tax: Before or After Discount.

    6. Choose if you want to Apply Discount On Prices Excluding or Including Tax.

    7. Set whether you want to Apply Tax On custom price if available, or only on the original price.

    8.  Select whether to Enable Cross Border Trade.

    Magento Tax Calculation Settings

    Default Tax Destination Calculation

    In this section, you configure the Default Country, State and Post Code tax calculations will be based upon.

    Default Tag Destination Calculation

    Tax Display Settings

    When you finish with the tax calculations, rates and classes, taxes will be calculated as per your settings. However, there is the customer experience part left. You have to configure tax displaying in the catalog, shopping cart, orders, invoices and credit memos.

    We'd recommend displaying prices including taxes or both including and excluding taxes so customers are aware of the amount they will be changed with before checkout. 

    If you display taxes only on checkout or shopping cart, it can lead to increased cart abandonment. No one likes to be charged with more than is expected.

    Catalog Prices

    In this field, you have to decide how taxes will be displayed on product catalog prices and shipping.

    Choose whether to Display Product Prices in Catalog and Shipping Prices excluding or including taxes. You can also display prices with and without taxes simultaneously.

    Tax Display Price Settings

    If you decide to display both prices (with and without tax), it will look like the following:

    Prices with Tax in Magento 2

    Shopping Cart, Order, Invoice and Credit Memo

    For shopping cart and orders sales documents in Magento 2 you also have to configure the tax displaying. So, you have to choose whether to Display Prices, Subtotal, Shipping Amounts with or without tax.

    This is how price with and without tax will look like:

    • In the shopping cart

    Magento Shopping Cart with Taxes

    • On checkout

    Prices with Tax on Magento Checkout

    Besides, you have to select if you want to Include Tax in Order Total, Display Full Tax Summary or Zero Tax Subtotal.

    Once set up taxes are automatically applied to the order total (based on your settings, customer&product classes, rules and location, and others). And now, it shouldn't be too hard for you to navigate through the Magento tax configuration.

    However, if you do need some help configuring taxes, contact us and we'll set them up together:)