Pakistan - Formatting standards & code snippets

Here is a complete list of standards and formats used in Pakistan. It includes a full list of ISO codes, number, date, currency, telephone and address formats. You will also get code examples on how to perform the most common formatting operations in Java, C#, JavaScript and PHP. Multiple resource files are made available, mainly the complete list of states, in different formats such as CSV, XML, JSON, HTML and SQL.

What are the ISO-3166-1 codes for Pakistan?

  • Alpha-2: PK
  • Alpha-3: PAK
  • Numeric: 586
  • Java Locale Code: ur_PK and en_PK
  • .Net CultureInfo Code: ur-PK and en-PK
  • PHP Locale Code: ur_PK and en_PK

What is the official language in Pakistan?

  • Urdu and English

What is the date format in Pakistan?

The date format in Pakistan is little-endian:

  • Format: dd/mm/yyyy
    Ex: 03/12/2014 for December 3rd 2014
Formatting a date in Java:
Locale locale = new Locale("ur", "PK"); // or en_PK
SimpleDateFormat sdf = new SimpleDateFormat("dd/MM/yyyy", locale);
sdf.format(new Date());
Formatting a date in C#:
CultureInfo ci = CultureInfo.GetCultureInfo("ur-PK"); // or en-PK
DateTime.Now.ToString("dd/MM/yyyy", ci);
Formatting a date in JavaScript:
let date = new Date();
date.toLocaleDateString('ur-PK'); // or en-PK
Formatting a date in PHP:
date("d/m/Y");

What is the time format in Pakistan?

The time format in Pakistan is 12-hour notation in most cases.

  • Format: hh:mm[:ss] AM | PM
    Ex: 09:00 AM for 09:00AM, and 09:00 PM for 09:00PM
Formatting time in Java:
Locale locale = new Locale("ur", "PK"); // en_PK
SimpleDateFormat sdf = new SimpleDateFormat("hh:mm:ss aa", locale);
sdf.format(new Date());
Formatting time in C#:
CultureInfo ci = CultureInfo.GetCultureInfo("ur-PK"); // or en-PK
DateTime.Now.ToString("hh:mm:ss tt", ci);
Formatting time in JavaScript:
let time = new Date();
date.toLocaleTimeString('ur-PK', {hour12: true}); // or en-PK
Formatting time in PHP:
date("g:i:s a");

What is the numeric format in Pakistan?

  • Format: 999,999,999.99
    • Group Size: 3
    • Grouping Character: , (comma)
    • Decimal Character: . (dot)
Formatting numbers in Java:
Locale locale = new Locale("ur", "PK"); // or en_PK
NumberFormat numberFormat = NumberFormat.getNumberInstance(locale);
numberFormat.format(999999999.99d);
Formatting numbers in C#:
double d = 999999999.99d;
d.ToString("n", CultureInfo.GetCultureInfo("ur-PK"))); // or en-PK
Formatting numbers in JavaScript:
let number = 999999999.99;
number.toLocaleString('ur-PK'); // or en-PK
Formatting numbers in PHP:
$fmt = new NumberFormatter($locale = 'ur_PK', NumberFormatter::DECIMAL); // or en_PK
$fmt->format(999999999.99);

What is the currency format in Pakistan?

  • Format: Rs999,999,999
    • Group Size: 3
    • Grouping Character: , (Comma)
    • Decimal Character: Not supported
    • Currency Symbol: Rs
    • Currency Symbol Position: Before number
    • Currency Name: Pakistane Rupee (PKR)
Formatting currency in Java:
Locale locale = new Locale("ur", "PK"); // or en_PK
NumberFormat numberFormat = NumberFormat.getCurrencyInstance(locale);
numberFormat.format(999999999d);
Formatting currency in C#:
double d = 999999999d;
d.ToString("c", CultureInfo.GetCultureInfo("ur-PK"))); // or en-PK
Formatting currency in JavaScript:
let number = 999999999;
number.toLocaleString('ur-PK', {currency: 'PKR', style: 'currency'}); // or en-PK
Formatting currency in PHP:
$fmt = new NumberFormatter($locale = 'ur_PK', NumberFormatter::CURRENCY); // or en_PK
$fmt->format(999999999.99);

Download list of regions for Pakistan in CSV, JSON, HTML, SQL and XML


List of regions: HTML - Select Control

----------------------------------
 ISO_3166-2 code + name - English
----------------------------------
<select>
	<option value="PK-JK">Azad Kashmir</option>
	<option value="PK-BA">Balochistan</option>
	<option value="PK-TA">Federally Administered Tribal Areas</option>
	<option value="PK-GB">Gilgit-Baltistan</option>
	<option value="PK-IS">Islamabad</option>
	<option value="PK-KP">Khyber Pakhtunkhwa</option>
	<option value="PK-PB">Punjab</option>
	<option value="PK-SD">Sindh</option>
</select>

----------------------------------
 ISO_3166-2 code + name - Urdu
----------------------------------
<select>
	<option value="PK-IS">اسلام آباد</option>
	<option value="PK-BA">بلوچستان</option>
	<option value="PK-KP">خیبر پختونخوا</option>
	<option value="PK-PB">پنجاب</option>
	<option value="PK-SD">سندھ</option>
	<option value="PK-TA">وفاق کے زیر انتظام قبائلی علاقہ جات</option>
	<option value="PK-JK">آزاد کشمیر</option>
	<option value="PK-GB">گلگت بلتستان</option>
</select>

List of regions: CSV

/ English
code,name
PK-JK,"Azad Kashmir"
PK-BA,"Balochistan"
PK-TA,"Federally Administered Tribal Areas"
PK-GB,"Gilgit-Baltistan"
PK-IS,"Islamabad"
PK-KP,"Khyber Pakhtunkhwa"
PK-PB,"Punjab"
PK-SD,"Sindh"

// Urdu
PK-IS,"اسلام آباد"
PK-BA,"بلوچستان"
PK-KP,"خیبر پختونخوا"
PK-PB,"پنجاب"
PK-SD,"سندھ"
PK-TA,"وفاق کے زیر انتظام قبائلی علاقہ جات"
PK-JK,"آزاد کشمیر"
PK-GB,"گلگت بلتستان"

List of regions: JSON

----------------------------------
 ISO-3166-2 code + Name - English
----------------------------------
[
	{code: "PK-JK", name: "Azad Kashmir"},
	{code: "PK-BA", name: "Balochistan"},
	{code: "PK-TA", name: "Federally Administered Tribal Areas"},
	{code: "PK-GB", name: "Gilgit-Baltistan"},
	{code: "PK-IS", name: "Islamabad"},
	{code: "PK-KP", name: "Khyber Pakhtunkhwa"},
	{code: "PK-PB", name: "Punjab"},
	{code: "PK-SD", name: "Sindh"}
]

-------------------------------
 ISO-3166-2 code + Name - Urdu
-------------------------------
[
	{code: "PK-IS", name: "اسلام آباد"},
	{code: "PK-BA", name: "بلوچستان"},
	{code: "PK-KP", name: "خیبر پختونخوا"},
	{code: "PK-PB", name: ""},
	{code: "PK-SD", name: "سندھ"},
	{code: "PK-TA", name: "وفاق کے زیر انتظام قبائلی علاقہ جات"},
	{code: "PK-JK", name: "آزاد کشمیر"},
	{code: "PK-GB", name: "گلگت بلتستان"}
]

List of regions: SQL

-- -----------------------------------------------------
-- Table `region`
-- -----------------------------------------------------
DROP TABLE IF EXISTS region;

CREATE TABLE IF NOT EXISTS region (
  id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
  code VARCHAR(6) NOT NULL,
  name_en VARCHAR(50) NOT NULL,
  name_ur VARCHAR(50) NOT NULL,
  PRIMARY KEY (id),
  UNIQUE INDEX id_UNIQUE (id ASC),
  UNIQUE INDEX code_UNIQUE (code ASC)
) ENGINE = InnoDB;

INSERT INTO region (id, code, name_en, name_ur) VALUES (null, 'PK-JK', 'Azad Kashmir', 'آزاد کشمیر');
INSERT INTO region (id, code, name_en, name_ur) VALUES (null, 'PK-BA', 'Balochistan', 'بلوچستان');
INSERT INTO region (id, code, name_en, name_ur) VALUES (null, 'PK-TA', 'Federally Administered Tribal Areas', 'بلوچستان');
INSERT INTO region (id, code, name_en, name_ur) VALUES (null, 'PK-GB', 'Gilgit-Baltistan', 'گلگت بلتستان');
INSERT INTO region (id, code, name_en, name_ur) VALUES (null, 'PK-IS', 'Islamabad', 'اسلام آباد');
INSERT INTO region (id, code, name_en, name_ur) VALUES (null, 'PK-KP', 'Khyber Pakhtunkhwa', 'خیبر پختونخوا');
INSERT INTO region (id, code, name_en, name_ur) VALUES (null, 'PK-PB', 'Punjab', 'پنجاب');
INSERT INTO region (id, code, name_en, name_ur) VALUES (null, 'PK-SD', 'Sindh', 'سندھ');

List of regions: XML

<!-- ISO-3166-2 code + name - English -->
<?xml version="1.0" encoding="UTF-8"?>
<regions>
	<region>
		<code>PK-JK</code>
		<name>Azad Kashmir</name>
	</region>
	<region>
		<code>PK-BA</code>
		<name>Balochistan</name>
	</region>
	<region>
		<code>PK-TA</code>
		<name>Federally Administered Tribal Areas</name>
	</region>
	<region>
		<code>PK-GB</code>
		<name>Gilgit-Baltistan</name>
	</region>
	<region>
		<code>PK-IS</code>
		<name>Islamabad</name>
	</region>
	<region>
		<code>PK-KP</code>
		<name>Khyber Pakhtunkhwa</name>
	</region>
	<region>
		<code>PK-PB</code>
		<name>Punjab</name>
	</region>
	<region>
		<code>PK-SD</code>
		<name>Sindh</name>
	</region>
</regions>

<!-- ISO-3166-2 code + name - Urdu -->
<?xml version="1.0" encoding="UTF-8"?>
<regions>
	<region>
		<code>PK-IS</code>
		<name>اسلام آباد</name>
	</region>
	<region>
		<code>PK-BA</code>
		<name>بلوچستان</name>
	</region>
	<region>
		<code>PK-KP</code>
		<name>خیبر پختونخوا</name>
	</region>
	<region>
		<code>PK-SD</code>
		<name>سندھ</name>
	</region>
	<region>
		<code>PK-TA</code>
		<name>وفاق کے زیر انتظام قبائلی علاقہ جات</name>
	</region>
	<region>
		<code>PK-JK</code>
		<name>آزاد کشمیر</name>
	</region>
	<region>
		<code>PK-GB</code>
		<name>گلگت بلتستان</name>
	</region>
</regions>