<?php echo number_format("1000000")."<br>"; // output 1,000,000 echo number_format("1000000",2)."<br>"; // 1,000,000.00 echo number_format("1000000",2,",","."); // 1.000.000,00 ?>