Tom's Obvious Minimal Language (TOML) Knowledge

Kip Landergren

(Updated: )

Contents

Overview

Tom’s Obvious Minimal Language (TOML) is a UTF-8 file format with the following objectives:

TOML:

title = "Foo App"
version = "2.3.8"
debug = false

[owner]
name = "Kip Landergren"
joined = 2026-10-12

[database]
host = "localhost"
ports = [5432, 5433]
max_connections = 50

[[servers]]
name = "alpha"
ip = "10.0.0.1"

[[servers]]
name = "beta"
ip = "10.0.0.2"

And the JSON equivalent:

{
  "title": "Foo App",
  "version": "2.3.8",
  "debug": false,
  "owner": {
    "name": "Kip Landergren",
    "joined": "2026-10-12"
  },
  "database": {
    "host": "localhost",
    "ports": [5432, 5433],
    "max_connections": 50
  },
  "servers": [
    {
      "name": "alpha",
      "ip": "10.0.0.1"
    },
    {
      "name": "beta",
      "ip": "10.0.0.2"
    }
  ]
}

Core Idea

A TOML file should map directly to a hash table.

Key Concepts

Headers

The square brackets that define a table somewhere within the root table.

TOML:

[header]
foo = "bar"

JSON:

{
  "header": {
    "foo": "bar"
  }
}

Related