Colombia - Formatting standards & code snippets
Here is a complete list of standards and formats used in Colombia. 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 departments, in different formats such as CSV, XML, JSON, HTML and SQL.
What are the ISO-3166-1 codes for Colombia?
- Alpha-2: CO
- Alpha-3: COL
- Numeric: 170
- Java Locale Code: es_CO
- .Net CultureInfo Code: es-CO
- PHP Locale Code: es_CO
What is the official language in Colombia?
- Spanish
What is the date format in Colombia?
The date format in Colombia is little-endian:
- Format: d/M/yyyy
Ex: 3/12/2014 for December 3rd 2014
Formatting a date in Java:
Locale locale = new Locale("es", "CO");
SimpleDateFormat sdf = new SimpleDateFormat("d/MM/yyyy", locale);
sdf.format(new Date());
Formatting a date in C#:
CultureInfo ci = CultureInfo.GetCultureInfo("es-CO");
DateTime.Now.ToString("d/MM/yyyy", ci);
Formatting a date in JavaScript:
let date = new Date();
date.toLocaleDateString('es-CO');
Formatting a date in PHP:
date("j/m/Y")
What is the time format in Colombia?
The time format in Colombia is mostly 12-hour notation, but 24-hour format is also commonly adopted.
- Format: h:mm[:ss] a.m.|p.m.
Ex: 9:00 a.m. for 09:00 AM and 9:00 p.m. for 9:00 PM
Formatting time in Java:
Locale locale = new Locale("es", "CO");
SimpleDateFormat sdf = new SimpleDateFormat("h:mm:ss aa", locale);
sdf.format(new Date());
Formatting time in C#:
CultureInfo ci = CultureInfo.GetCultureInfo("es-CO");
DateTime.Now.ToString("h:mm:ss tt", ci);
Formatting time in JavaScript:
let date = new Date();
date.toLocaleTimeString('es-CO', {hour12: true});
Formatting time in PHP:
date("g:i:s a");
What is the numeric format in Colombia?
- Format: 999.999.999,99
- Group Size: 3
- Grouping Character: . (dot)
- Decimal Character: , (comma)
Formatting numbers in Java:
Locale locale = new Locale("es", "CO");
NumberFormat numberFormat = NumberFormat.getNumberInstance(locale);
numberFormat.format(999999999.99d);
Formatting numbers in C#:
double d = 999999999.99d;
d.ToString("n", CultureInfo.GetCultureInfo("es-CO")));
Formatting numbers in JavaScript:
let number = 999999999.99;
number.toLocaleString('es-CO');
Formatting numbers in PHP:
$fmt = new NumberFormatter($locale = 'es_CO', NumberFormatter::DECIMAL);
$fmt->format(999999999.99);
What is the currency format in Colombia?
- Format: $ 1.000.000.000
- Group Size: 3
- Grouping Character: . (dot)
- Decimal Character: Not supported
- Currency Symbol: $
- Currency Symbol Position: Before number
- Currency Name: Colombian Peso (COP)
Formatting currency in Java:
Locale locale = new Locale("es", "CO");
NumberFormat numberFormat = NumberFormat.getCurrencyInstance(locale);
numberFormat.format(999999999d);
Formatting currency in C#:
double d = 999999999d;
d.ToString("c", CultureInfo.GetCultureInfo("es-CO")));
Formatting currency in JavaScript:
let number = 999999999;
number.toLocaleString('es-CO', {currency: 'COP', style: 'currency'});
Formatting currency in PHP:
$fmt = new NumberFormatter($locale = 'es_CO', NumberFormatter::CURRENCY);
$fmt->format(999999999.99);
Download list of departments for Colombia in CSV, JSON, HTML, SQL and XML
List of departments: HTML - Select Control
------------------------
ISO_3166-2 code + name
------------------------
<select>
<option value="CO-AMA">Amazonas</option>
<option value="CO-ANT">Antioquia</option>
<option value="CO-ARA">Arauca</option>
<option value="CO-ATL">Atlántico</option>
<option value="CO-BOL">Bolívar</option>
<option value="CO-BOY">Boyacá</option>
<option value="CO-CAL">Caldas</option>
<option value="CO-CAQ">Caquetá</option>
<option value="CO-CAS">Casanare</option>
<option value="CO-CAU">Cauca</option>
<option value="CO-CES">Cesar</option>
<option value="CO-CHO">Chocó</option>
<option value="CO-COR">Córdoba</option>
<option value="CO-CUN">Cundinamarca</option>
<option value="CO-DC">Distrito Capital de Bogotá</option>
<option value="CO-GUA">Guainía</option>
<option value="CO-GUV">Guaviare</option>
<option value="CO-HUI">Huila</option>
<option value="CO-LAG">La Guajira</option>
<option value="CO-MAG">Magdalena</option>
<option value="CO-MET">Meta</option>
<option value="CO-NAR">Nariño</option>
<option value="CO-NSA">Norte de Santander</option>
<option value="CO-PUT">Putumayo</option>
<option value="CO-QUI">Quindío</option>
<option value="CO-RIS">Risaralda</option>
<option value="CO-SAP">San Andrés, Providencia y Santa Catalina</option>
<option value="CO-SAN">Santander</option>
<option value="CO-SUC">Sucre</option>
<option value="CO-TOL">Tolima</option>
<option value="CO-VAC">Valle del Cauca</option>
<option value="CO-VAU">Vaupés</option>
<option value="CO-VID">Vichada</option>
</select>
List of departments: CSV
code,name
CO-AMA,"Amazonas"
CO-ANT,"Antioquia"
CO-ARA,"Arauca"
CO-ATL,"Atlántico"
CO-BOL,"Bolívar"
CO-BOY,"Boyacá"
CO-CAL,"Caldas"
CO-CAQ,"Caquetá"
CO-CAS,"Casanare"
CO-CAU,"Cauca"
CO-CES,"Cesar"
CO-CHO,"Chocó"
CO-COR,"Córdoba"
CO-CUN,"Cundinamarca"
CO-DC,"Distrito Capital de Bogotá"
CO-GUA,"Guainía"
CO-GUV,"Guaviare"
CO-HUI,"Huila"
CO-LAG,"La Guajira"
CO-MAG,"Magdalena"
CO-MET,"Meta"
CO-NAR,"Nariño"
CO-NSA,"Norte de Santander"
CO-PUT,"Putumayo"
CO-QUI,"Quindío"
CO-RIS,"Risaralda"
CO-SAP,"San Andrés, Providencia y Santa Catalina"
CO-SAN,"Santander"
CO-SUC,"Sucre"
CO-TOL,"Tolima"
CO-VAC,"Valle del Cauca"
CO-VAU,"Vaupés"
CO-VID,"Vichada"
List of departments: JSON
------------------------
ISO-3166-2 code + Name
------------------------
[
{code: "CO-AMA", name: "Amazonas"},
{code: "CO-ANT", name: "Antioquia"},
{code: "CO-ARA", name: "Arauca"},
{code: "CO-ATL", name: "Atlántico"},
{code: "CO-BOL", name: "Bolívar"},
{code: "CO-BOY", name: "Boyacá"},
{code: "CO-CAL", name: "Caldas"},
{code: "CO-CAQ", name: "Caquetá"},
{code: "CO-CAS", name: "Casanare"},
{code: "CO-CAU", name: "Cauca"},
{code: "CO-CES", name: "Cesar"},
{code: "CO-CHO", name: "Chocó"},
{code: "CO-COR", name: "Córdoba"},
{code: "CO-CUN", name: "Cundinamarca"},
{code: "CO-DC", name: "Distrito Capital de Bogotá"},
{code: "CO-GUA", name: "Guainía"},
{code: "CO-GUV", name: "Guaviare"},
{code: "CO-HUI", name: "Huila"},
{code: "CO-LAG", name: "La Guajira"},
{code: "CO-MAG", name: "Magdalena"},
{code: "CO-MET", name: "Meta"},
{code: "CO-NAR", name: "Nariño"},
{code: "CO-NSA", name: "Norte de Santander"},
{code: "CO-PUT", name: "Putumayo"},
{code: "CO-QUI", name: "Quindío"},
{code: "CO-RIS", name: "Risaralda"},
{code: "CO-SAP", name: "San Andrés, Providencia y Santa Catalina"},
{code: "CO-SAN", name: "Santander"},
{code: "CO-SUC", name: "Sucre"},
{code: "CO-TOL", name: "Tolima"},
{code: "CO-VAC", name: "Valle del Cauca"},
{code: "CO-VAU", name: "Vaupés"},
{code: "CO-VID", name: "Vichada"}
]
List of departments: SQL
-- -----------------------------------------------------
-- Table `department`
-- -----------------------------------------------------
DROP TABLE IF EXISTS department;
CREATE TABLE IF NOT EXISTS department (
id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
code VARCHAR(6) NOT NULL,
name VARCHAR(50) NOT NULL,
PRIMARY KEY (id),
UNIQUE INDEX id_UNIQUE (id ASC),
UNIQUE INDEX code_UNIQUE (code ASC)
) ENGINE = InnoDB;
INSERT INTO department (id, code, name) VALUES (null, 'CO-AMA', 'Amazonas');
INSERT INTO department (id, code, name) VALUES (null, 'CO-ANT', 'Antioquia');
INSERT INTO department (id, code, name) VALUES (null, 'CO-ARA', 'Arauca');
INSERT INTO department (id, code, name) VALUES (null, 'CO-ATL', 'Atlántico');
INSERT INTO department (id, code, name) VALUES (null, 'CO-BOL', 'Bolívar');
INSERT INTO department (id, code, name) VALUES (null, 'CO-BOY', 'Boyacá');
INSERT INTO department (id, code, name) VALUES (null, 'CO-CAL', 'Caldas');
INSERT INTO department (id, code, name) VALUES (null, 'CO-CAQ', 'Caquetá');
INSERT INTO department (id, code, name) VALUES (null, 'CO-CAS', 'Casanare');
INSERT INTO department (id, code, name) VALUES (null, 'CO-CAU', 'Cauca');
INSERT INTO department (id, code, name) VALUES (null, 'CO-CES', 'Cesar');
INSERT INTO department (id, code, name) VALUES (null, 'CO-CHO', 'Chocó');
INSERT INTO department (id, code, name) VALUES (null, 'CO-COR', 'Córdoba');
INSERT INTO department (id, code, name) VALUES (null, 'CO-CUN', 'Cundinamarca');
INSERT INTO department (id, code, name) VALUES (null, 'CO-DC', 'Distrito Capital de Bogotá');
INSERT INTO department (id, code, name) VALUES (null, 'CO-GUA', 'Guainía');
INSERT INTO department (id, code, name) VALUES (null, 'CO-GUV', 'Guaviare');
INSERT INTO department (id, code, name) VALUES (null, 'CO-HUI', 'Huila');
INSERT INTO department (id, code, name) VALUES (null, 'CO-LAG', 'La Guajira');
INSERT INTO department (id, code, name) VALUES (null, 'CO-MAG', 'Magdalena');
INSERT INTO department (id, code, name) VALUES (null, 'CO-MET', 'Meta');
INSERT INTO department (id, code, name) VALUES (null, 'CO-NAR', 'Nariño');
INSERT INTO department (id, code, name) VALUES (null, 'CO-NSA', 'Norte de Santander');
INSERT INTO department (id, code, name) VALUES (null, 'CO-PUT', 'Putumayo');
INSERT INTO department (id, code, name) VALUES (null, 'CO-QUI', 'Quindío');
INSERT INTO department (id, code, name) VALUES (null, 'CO-RIS', 'Risaralda');
INSERT INTO department (id, code, name) VALUES (null, 'CO-SAP', 'San Andrés, Providencia y Santa Catalina');
INSERT INTO department (id, code, name) VALUES (null, 'CO-SAN', 'Santander');
INSERT INTO department (id, code, name) VALUES (null, 'CO-SUC', 'Sucre');
INSERT INTO department (id, code, name) VALUES (null, 'CO-TOL', 'Tolima');
INSERT INTO department (id, code, name) VALUES (null, 'CO-VAC', 'Valle del Cauca');
INSERT INTO department (id, code, name) VALUES (null, 'CO-VAU', 'Vaupés');
INSERT INTO department (id, code, name) VALUES (null, 'CO-VID', 'Vichada');
List of departments: XML
<!-- ISO-3166-2 code + name -->
<?xml version="1.0" encoding="UTF-8"?>
<departments>
<department>
<code>CO-AMA</code>
<name>Amazonas</name>
</department>
<department>
<code>CO-ANT</code>
<name>Antioquia</name>
</department>
<department>
<code>CO-ARA</code>
<name>Arauca</name>
</department>
<department>
<code>CO-ATL</code>
<name>Atlántico</name>
</department>
<department>
<code>CO-BOL</code>
<name>Bolívar</name>
</department>
<department>
<code>CO-BOY</code>
<name>Boyacá</name>
</department>
<department>
<code>CO-CAL</code>
<name>Caldas</name>
</department>
<department>
<code>CO-CAQ</code>
<name>Caquetá</name>
</department>
<department>
<code>CO-CAS</code>
<name>Casanare</name>
</department>
<department>
<code>CO-CAU</code>
<name>Cauca</name>
</department>
<department>
<code>CO-CES</code>
<name>Cesar</name>
</department>
<department>
<code>CO-CHO</code>
<name>Chocó</name>
</department>
<department>
<code>CO-COR</code>
<name>Córdoba</name>
</department>
<department>
<code>CO-CUN</code>
<name>Cundinamarca</name>
</department>
<department>
<code>CO-DC</code>
<name>Distrito Capital de Bogotá</name>
</department>
<department>
<code>CO-GUA</code>
<name>GuainĂa</name>
</department>
<department>
<code>CO-GUV</code>
<name>Guaviare</name>
</department>
<department>
<code>CO-HUI</code>
<name>Huila</name>
</department>
<department>
<code>CO-LAG</code>
<name>La Guajira</name>
</department>
<department>
<code>CO-MAG</code>
<name>Magdalena</name>
</department>
<department>
<code>CO-MET</code>
<name>Meta</name>
</department>
<department>
<code>CO-NAR</code>
<name>Nariño</name>
</department>
<department>
<code>CO-NSA</code>
<name>Norte de Santander</name>
</department>
<department>
<code>CO-PUT</code>
<name>Putumayo</name>
</department>
<department>
<code>CO-QUI</code>
<name>Quindío</name>
</department>
<department>
<code>CO-RIS</code>
<name>Risaralda</name>
</department>
<department>
<code>CO-SAP</code>
<name>San Andrés, Providencia y Santa Catalina</name>
</department>
<department>
<code>CO-SAN</code>
<name>Santander</name>
</department>
<department>
<code>CO-SUC</code>
<name>Sucre</name>
</department>
<department>
<code>CO-TOL</code>
<name>Tolima</name>
</department>
<department>
<code>CO-VAC</code>
<name>Valle del Cauca</name>
</department>
<department>
<code>CO-VAU</code>
<name>Vaupés</name>
</department>
<department>
<code>CO-VID</code>
<name>Vichada</name>
</department>
</departments>