FPT Tax: How to Add and Import Fixed Product Tax in Magento 2

- E-Commerce, Magento 2

FPT tax in Magento 2: create, configure, import

Today, we are going to talk about the FPT tax. You will learn what FPT or Fixed Product Tax is and how it helps Magento 2 merchants sell products to different countries and different states adhering to local tax regulations. This tax is added in a bit of a peculiar way which may not be as obvious at first glance as it seems. In this post, we cover everything you need to know about the FPT tax and describe how to import fixed product tax to Magento 2.

What Is FPT Tax?

So what is the difference between the default tax and fixed product tax (FPT)? Regular Magento 2 taxes are calculated based on the order price. The FPT tax on the other hand provides customers with a fixed tax price, that is applied at the checkout depending on the shipping destination.

FPT tax at Magento checkout

As you can see in the screenshot above, the FPT for the bag is $15. This additional tax can also be subject to taxes, meaning that regular taxes can be also applied to it.

How to Create FPT Tax in Magento 2

Now that you have understood when the FPT tax is added and what it is, let’s dive into the admin to find where the FPT is set up and what options are available.

Step 1: Enable Fixed Product Tax in Magento Admin

The FPT Tax can be enabled under the Stores > Configuration screen. Next, using the left menu you need to navigate to Sales > Tax to find the Fixed Product Taxes section.

Enable FPT tax in Magento 2

By default, every option of the FPT section is set to ‘Use system values’ so to get manual control over every option you need to untick the checkboxes. The options available are self-explanatory. The only options you need to pay close attention to are:

  • Enable FPT – this is the main reason we have navigated here, this option allows adding fixed product taxes to products;
  • Apply Tax to FPT – defines whether regular taxes set up at your Magento 2 store should also be applied to the FPT;
  • Include FPT in Subtotal – defines whether the FPT should be added to the order subtotal, meaning that it can be subject to discounts.

Configure these options carefully per tax regulations applied in your country.

Step 2: Create FPT Product Attribute

Activating the FPT tax in Magento 2 is not enough to have its options available for all products in your catalog. Enabling FPT allows the store owner to create a fixed product tax product attribute that can be added to the selected products. Let’s see how the FPT Tax attribute is created.

Navigate to Stores > Attributes > Product and add a new attribute there.

FPT tax attribute properties

The new FPT tax attribute acts as any other Magento 2 product attribute – it is added to the product details where you can edit it. For the fixed product tax attribute you need to specify:

  • Default Label – a label of the attribute that is also the attribute’s name;
  • Catalog Input Type for Store Owner – here you need to select the ‘Fixed Product Tax’ value, which will not be available if you haven’t completed Step 1;
  • Attribute Code – the code will be used for internal Magento 2 purposes and for importing fixed product taxes;
  • Add to Column Options and Use in Filter Options – allows you to add this attribute to filters at the storefront making it available to customers.

When you are done setting up properties and advanced attribute properties, you may want to manage attribute labels for different store views. Click the ‘Save’ button when finished and proceed to the next step.

Step 3: Add FPT Tax Attribute to Attribute Set

As you know, in Magento 2 product attributes should be added to the attribute sets to be available for configuration in product details. The pattern is the following.

Create attribute > Add attribute to the attribute set > Assign the attribute set to products > Configure attribute

To add a fixed product tax attribute to the attribute set navigate to Stores > Attributes > Attribute Sets.

add FPT tax attribute to attribute set

Here you need to select either an existing attribute set or create a new one depending on your goal. For the guide purposes, let’s add the FPT Tax attribute to the Default attribute set.

add FPT tax to attribute sets

To add the created attribute to the attribute set find it in the Unassigned Attributes list and drag & drop it to the Groups list. When you are done click the ‘Save’ button.

That’s it, now every product belonging to the Default attribute set has a fixed product tax attribute. Let’s proceed to the product catalog to find a product with the Default attribute set to configure it.

Step 4: Configure FPT Tax per Product

In the product catalog, find a product belonging to the product set you have added the FPT tax attribute to and proceed to editing.

FPT tax per product

The options are pretty simple: you select a country and a state where the FPT tax is applicable and specify the flat tax value. Remember, the tax is not a percent value, meaning that specifying ‘10’ will charge a customer $10.

That’s it. You have enabled and configured the FPT tax in Magento 2. Now, whenever a customer purchases a product, the fixed tax value will be added to the order.

How to Import Fixed Product Tax (FPT) to Magento 2

Let’s see, how to import the FPT data to Magento 2.

FPT Import Attribute

As with any other product attribute, the fixed product taxes can be imported to your Magento 2 store. The attribute for fixed product tax is:

wee_tax_variations

This attribute can be added to any product import table you are using.

Sample FPT CSV Table

If you do not have an import table, you can:

In the Master Table, you can find all product attributes with their description. You can also get sample import tables that cover complex product data import, taxes, tier prices, and country and state codes.

FPT tax import CSV

wee_tax_variations Column Values Described

In the screenshot above, you can see an example of the fixed product tax import table with values filled in it. Let’s break down what values are expected. wee_tax_variations attribute responsible for the FPT tax has the following value structure:

name=attribute_code,country=country_code_ISO-3166,state=country_state_magento2_code,value=tax_value||name=attribute_code…

Note that sub-values are separated by a comma and values are separated by a DOUBLE pipe symbol.

For example, if you want to add a fixed product tax of $20.5 for Alabama, United States, and $5 for Barcelona, Spain your wee_tax_variations value looks as follows:

name=fixed_product_tax,country=US,state=1,value=20.5000||name=fixed_product_tax,country=ES,state=139,value=5.0000

Note, that the value for Alabama is ‘1’ and for Barcelona – ‘139’. You can find all country codes and state codes in a separate sheet of Master Table.

FPT Tax Import to Magento 2

When you are done with the table proceed to System > Import, or System > Import Jobs if you are using the Improved Import and Export extension by FireBear studio.

  • Select import entity ‘Products’;
    import FPT tax to Magento 2 with Products
  • Upload the composed CSV table, or copy the Google Sheets link if you are using the Improved Import and Export extension;
    FPT tax import source
  • Hit the ‘Import’ button.
    Magento 2 FPT tax import

You have just imported fixed product taxes to your Magento 2 store. If you still have any questions on fixed product taxes feel free to post comments below.

Final Words

Magento 2 supports the FPT tax by default. You can easily create the corresponding attribute, add it to products, and specify different fixed product taxes per country or even state or region. If you don’t want to bother yourself with lots of manual work, it is possible to import the FPT tax to Magento 2 in a couple of clicks. Create a CSV file, and use the wee_tax_variations attribute to provide all the necessary fixed product tax data.