Convert numbers into words in Indonesian language
Switch branches/tags
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


Build Status Latest Stable Version Total Downloads Latest Unstable Version License

Convert numbers into words in Indonesian language.


Download composer.phar if you don't have one. Then run it from terminal.

php composer.phar require "nasution/terbilang: *"

Or, you can put into your composer.json file.

"require": {
  "nasution/terbilang": "*"

Then run composer update

php composer.phar update



require 'vendor/autoload.php';

$terbilang = new Nasution\Terbilang();
echo $terbilang->convert(234);        // dua ratus tiga puluh empat

// OR with static method

echo Nasution\Terbilang::convert(42); // empat puluh dua

You can import that class to make it more simple to called


require 'vendor/autoload.php';

use Nasution\Terbilang;

$terbilang = new Terbilang();
echo $terbilang->convert(2014);    // dua ribu empat belas

// OR with static method

echo Terbilang::convert('123304'); // seratus dua puluh tiga ribu tiga ratus empat

Another example

echo Terbilang::convert('1000000');          // satu juta
echo Terbilang::convert('1000000000');       // satu milyar
echo Terbilang::convert('1000000000000');    // satu triliun
echo Terbilang::convert('1000000000000000'); // satu kuadriliun

You can also use dot notation to separate the numbers

echo Terbilang::convert('1.300.000');       // satu juta tiga ratus ribu
echo Terbilang::convert(''); // seratus milyar tiga puluh juta dua puluh ribu sepuluh