Free Currency Converter PHP using Fixer io API

Hello, Today I am gonna provide you Currency Converter API  PHP Source Code with explanation and how to use that PHP Script.

This tutorial will help you to create your own PHP Currency Converter Script using API.

Also read,

Real Time Chat Application PHP With File Transfer System  AJAX

Features of this PHP Script :

  1. You can convert one currency into another.
  2. You will have all the currency in a  list as a drop-down menu. ( All the drop-down options are being fetched from the API JSON Data)
  3. You will get the conversion result of currency exchange as well as the Reverse currency exchange result.
  4. Easy to use and easy to understand.
  5. Optimized Code and Light Weight.

You can see the live demo of this PHP Script from Here
Due to some strong reason, we are not providing the script for free anymore.
We strongly recommend you to purchase the product from the given link below

Purchase it


Pro Version Of this Currency converter PHP Script

In pro version, you don’t need to click on any convert or submit button. Just enter the amount and the currency will be converted instantly without hitting extra API usage again and again.

Live demo Of PRO Currency Converter

Buy PRO Version

To get custom design and style or modification Contact Us


How to create free currency converter PHP Script Using Fixer API

At first, go to
Create an account there to get The API key.

But I will suggest you create a free account first to test your script.

After creating an account you will get a unique API key.

Now here your Coding Starts.
At first, you need to create a PHP file to fetch all the data from Fixer JSON file.

The JSON file URL looks like this,

And the JSON File looks like this,

    ----------  //more data

If you have the API key then you can get this JSON file URL easily by accessing that URL.
The URL will also be provided in Fixer account.

You might also be interested in,

Find Out What Happened On This Day PHP Script Using Hiztory API

Movie Video Trailers And Info PHP Script That Uses TMDB API

Get the distance between two places in PHP with Google Map API

Create a PHP file to fetch all the currency rate and data from JSON File

This is your PHP file to fetch all the currency data


$api="your api key here";   ///// Provide your api key here

$string = file_get_contents("$api&format=1");
  $json = json_decode($string, true);
  foreach ($json['rates'] as $key => $value) {
$api="your api key here";

Put your API key of fixer here.

 $string = file_get_contents("$api&format=1");

Thereafter, You have to use file_get_contents function to read the contents of the JSON file into a string.

Then, json_decode is used to convert the data into an object.

So now you carefully look at the JSON file structure. We have currency names and their value. SO we can use those as array.

 foreach ($json['rates'] as $key => $value)




$i=$i+1; }

By this foreach loop, we can easily store all the currency names and their value in array variable.

$currency[] array is used to store the currency names and $rate[] array is used to store their rates. (our base currency is EUR here)

As we have used array so it is cleared that $currency[5] will be the currency name of 6th currency listed in our JSON file. (as index starts with zero)

PHP Weather Forecast Script That Uses OpenWeatherMap API


Leave a Reply

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