# Merx::calculateTax()

> Calculates tax amount from gross price and tax rate

- Source: `src/Merx.php#L93` <https://github.com/wagnerwagner/merx/blob/2.0.0-alpha.11/src/Merx.php#L93>

```php
Merx::calculateTax(float $grossPrice, float $taxRate): float
```

## Parameters

| Name | Type | Default |
| --- | --- | --- |
| `$grossPrice` | `float` | `–` |
| `$taxRate` | `float` | `–` |

## Return type

`float`

## Description

E.g. calculateTax(200, 0.19) → 31.932773109243698

## Parent class

`Wagnerwagner\Merx\Merx`
