This Flutter-based Currency Converter App allows users to convert between different currencies using the ExchangeRate-API. The app supports live conversion rates and includes a clear, user-friendly interface. Users can select currencies from dropdowns, input amounts, and receive real-time conversion results.
- Real-time currency conversion using ExchangeRate-API
- Supports a wide variety of currencies
- Easy-to-use dropdowns for selecting base and target currencies
- Clear input and result display
- Swap feature to easily switch between currencies
- Clear button to reset inputs and results
- Error handling for failed API requests
- Responsive design for mobile
- Flutter SDK (>= 2.10.0)
- Android Studio / Xcode for running the app on an emulator or physical device
- A free API key from ExchangeRate-API
-
Clone the repository to your local machine:
git clone https://github.com/yourusername/currency-converter-app.git
-
Navigate into the project directory:
cd currency-converter-app -
Install dependencies:
flutter pub get
-
Add your ExchangeRate-API key in the
api_client.dartfile:final String apiKey = 'YOUR_API_KEY'; // Replace with your actual API key
-
Run the app on your emulator or physical device:
flutter run
-
API Client:
api_client.darthandles the API requests using theExchangeRate-APIto fetch live exchange rates and a list of currencies.
-
Dropdowns:
drop_down.dartcontains a custom dropdown widget allowing users to select currencies. It updates as soon as the list of currencies is fetched.
-
Main App:
main.dartcontains the app's UI, including a text field for user input, buttons for conversion and clearing results, and live conversion display.
This app uses the following dependencies:
The app integrates with the ExchangeRate-API to fetch real-time conversion rates. You will need to replace the placeholder YOUR_API_KEY in the api_client.dart file with your actual API key.
The app includes error handling for failed API requests. If the app is unable to connect to the API, an error message will be logged to the console.
This project is licensed under the MIT License and free to use.
Contributions are welcome! Please follow these steps to contribute:
- Fork the repository
- Create your feature branch (
git checkout -b feature/awesome-feature) - Commit your changes (
git commit -m 'Add some awesome feature') - Push to the branch (
git push origin feature/awesome-feature) - Open a pull request


