INI / Config File Parser

Parse INI sections and key/value pairs into readable paths.

Open tool

Overview

The INI parser reads a classic .ini config file and prints every key as a dotted path with its value. Sections become path prefixes so you can search and scan a sprawling file quickly without losing the section context.

It's a quick way to audit a legacy config — Windows desktop.ini, PHP php.ini, Samba smb.conf, or any tool that still uses the format — when you want to compare two environments or hunt for a stray setting. Sysadmins and developers maintaining legacy systems reach for an ini config parser when grep alone doesn't tell them which section a key belongs to.

How it works

INI is informally specified — there's no single RFC — but the common rules are: lines starting with [section] open a new section, key=value (or key: value) pairs define entries, ; and # start comments, and leading/trailing whitespace is trimmed. The parser handles the common dialect including the [default]/no-section keys (placed at the root path) and case-insensitive section/key names if you toggle the option.

Inline comments after a value are stripped only when preceded by whitespace, so name=foo;bar stays intact while name=foo ; comment keeps just foo. Quoted values preserve their literal contents including embedded comment markers.

Examples

[server]
host = localhost
port = 5432

[server.logging]
level = info
Output:
server.host           localhost
server.port           5432
server.logging.level  info
; comment
[database]
url="postgres://u:p@h:5432/db"
database.url  postgres://u:p@h:5432/db

FAQ

Are nested sections like [a.b.c] supported?

Yes. Section names with dots are treated as a hierarchy, mirroring the way many modern config dialects (Git, TOML) interpret them. Disable hierarchical mode if your INI uses dots as literal characters.

Does it preserve comments?

Comments are stripped from the structured output but listed in a separate section if you want to keep them for documentation purposes. Round-tripping through this tool is not lossless if comments matter.

What about duplicate keys?

Most INI parsers either keep the last duplicate or error out. This tool keeps the last value by default and warns about the duplicate so you can decide whether the source needs cleaning up.

Try INI / Config File Parser

An unhandled error has occurred. Reload ×