Motorrijtuigenbelasting: Dutch Road Tax Calculator
Motorrijtuigenbelasting is a Python library designed to calculate Dutch road taxes (motorrijtuigenbelasting, MRB) for passenger cars, motorcycles, and other vehicle types. It provides tools for determining taxes based on weight, fuel type, and provincial rates between 2015 and 2024. Future years will be added once the inflation numbers are in from the Belastingdienst.
Features
- Support for multiple energy sources (benzine, diesel, LPG, electric, etc.)
- Handles tax calculations based on weight brackets and provincial multipliers.
- Adjustable tax parameters for future tax years.
- Lightweight and extensible for different vehicle types like cars and motorcycles.
Table of Contents
Installation
Requirements
- Python 3.7 or higher.
pip install motorrijtuigenbelasting
or clone the repository and install dependencies:
git clone https://github.com/VitoMinheere/motorrijtuigenbelasting.git
cd motorrijtuigenbelasting
pip install -r requirements.txt
Usage
Example
Here’s how to use MRB-Py to calculate road tax for a passenger car:
from motorrijtuigenbelasting import Car, EnergySource
# Define car details
car = Car(weight=1200, energy_source=EnergySource.BENZINE, manufacturing_year=2024)
# Calculate total tax for Noord-Holland province in 2024
province = "noord-holland"
year = 2024
tax = car.calculate_total_tax(province, year)
print(f"Total tax for your car: €{tax}")
Supported Vehicle Types
Passenger Cars
Supports fuel types like benzine, diesel, LPG, LPG G3, and electric vehicles.
Oldtimer & kwarttarief ruling
Added the oldtimer & kwarttarief rulings and their maximum amounts.
Motorcycles
Rules for base tax and opcenten added. Added sources to the information in the docstring.
Other
Other vehicles types are being worked on in the following order:
- Diesel
- Benzine with low emissions
- Business Van
- Camper
- Trucks
Contributing
We welcome contributions! Please follow these steps:
- Fork the repository.
- Create a new branch for your feature or bugfix.
- Write clear code and include tests.
- Submit a pull request with a detailed description of your changes.
Issues and Feature Requests
Found a bug or have an idea for a new feature? We’d love to hear from you!
- Go to the Issues tab of the repository.
- Click New Issue.
- Provide a detailed description, including steps to reproduce the issue or a clear explanation of your feature idea.
Running Tests
Use unittest to run tests:
python -m unittest discover -s tests
License
This project is licensed under the MIT License. See the LICENSE file for details.
Contact
Feel free to reach out for support or feedback:
Metadata
Release files for motorrijtuigenbelasting 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| motorrijtuigenbelasting-0.1.0.tar.gz | 10.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| motorrijtuigenbelasting-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 23.4 kB
Release files / motorrijtuigenbelasting-0.1.0.tar.gz
| Download URL | motorrijtuigenbelasting-0.1.0.tar.gz |
|---|---|
| Size | 10.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b5bc9fd28530bc489506dc84aa977330e48bc53f579575391dfe4e75230e7507
|
|
BLAKE2b-256 checksum How to use checksums |
14612bbf68fd28d436b6f8fa909d9798e526dc34e9a9c4a8bb10e216b51997e4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.0.1 CPython/3.12.3
|
Release files / motorrijtuigenbelasting-0.1.0-py3-none-any.whl
| Download URL | motorrijtuigenbelasting-0.1.0-py3-none-any.whl |
|---|---|
| Size | 12.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5553ef1d7785281d10799d289347edbd82fee351248fcc0abd0eb3d53c17214b
|
|
BLAKE2b-256 checksum How to use checksums |
52953d86e37f3f397e70c8894fba057ec50f99471fa272c6aef32767287bced9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.0.1 CPython/3.12.3
|