Press ESC to close

Remove VAT from a price tool. (Code included for your own website)

Remove VAT Tool

You can use the tool below to remove VAT from any price. It defaults to 20% but you can change this to any value you like. 

The code to use on your website is included. A link back would be appreciated 😉

VAT Removal Tool

					<!DOCTYPE html>
    <title>VAT Removal Tool</title>
        // Function to remove VAT from the price
        function removeVAT() {
            // Get the input price and VAT rate from the form
            var priceWithVAT = document.getElementById("priceWithVAT").value;
            var vatRate = document.getElementById("vatRate").value;

            // Calculate VAT multiplier
            var vatMultiplier = (100 + parseFloat(vatRate)) / 100;

            // Calculate and display the price without VAT
            var priceWithoutVAT = priceWithVAT / vatMultiplier;
            document.getElementById("result").innerHTML = "Price without VAT: " + priceWithoutVAT.toFixed(2);
    <h1>VAT Removal Tool</h1>

    <!-- Input form for price and VAT rate -->
        <label for="priceWithVAT">Enter price (with VAT):</label>
        <input type="number" id="priceWithVAT" name="priceWithVAT" required><br><br>

        <label for="vatRate">VAT Rate (%):</label>
        <input type="number" id="vatRate" name="vatRate" value="20" required><br><br>

        <input type="button" value="Remove VAT" onclick="removeVAT()">
    <!-- Div to display the result -->
    <div id="result"></div>


Leave a Reply

Your email address will not be published. Required fields are marked *