gptcleanuppro.com / colon-to-json-array
Ready · local0w
Works with text copied from
ChatGPTClaudeGeminiGrokCopilotPerplexity
delimiter recognised
1
bytes sent to a server
0
length or run limit
None

The tool

A precise colon to JSON array converter

This tool takes a line with colon-separated fields and splits it on every colon, trims each value, and returns a formatted JSON array. It targets fixed-position records, where a colon is a genuine structural boundary rather than incidental punctuation.

The conversion runs entirely in JavaScript in your browser. There is no request sent to a server, and no run limit, since nothing here costs anything to serve.

Where the format comes from

Where colon-separated records actually come from

The canonical example is a Unix '/etc/passwd' line: 'root:x:0:0:root:/root:/bin/bash', seven colons marking seven fields in a fixed, defined order. A range of other system configuration files and legacy export formats follow the same shape, a colon between each field in a known sequence.

The colon also appears informally as a 'key: value' shorthand across notes, config snippets and simple settings files, where a label and its value sit on either side of a single colon.

How it works

How to convert a colon-separated record to JSON in three steps

No configuration, no field count to declare in advance.

Step 1
Paste the colon-separated line into the input field.
Step 2
Press Convert. The split and trim run instantly, client side.
Step 3
Copy the resulting JSON array from the output panel.

Why it matters

What breaks when a colon appears for a reason other than a field boundary

A colon is not exclusive to delimited records. A timestamp such as '14:30:00' separates hours, minutes and seconds with colons. A URL such as 'https://example.com:8080/path' carries one colon after the scheme and another before a port number. A ratio such as '16:9' carries one as well.

Paste a line containing one of these alongside genuinely delimited fields, and its internal colon is treated identically to a structural one, fracturing a value that was never meant to be split.

The same is true of anything that already looks like JSON. Paste an object such as '{"name": "value"}' and the tool has no concept of quoting or JSON syntax at all: it splits on every colon it finds, quote marks and braces included, exactly as it would a timestamp. A quoted string value containing its own colon fractures the same way.

The underlying constraint

Why colon-delimited data depends on a clean, single-purpose line

A format like passwd functions because every field in that file format is defined, by design, never to contain a colon of its own, a guarantee the format's designers made up front. A field storing a URL, a time or a ratio violates that guarantee the moment it appears in a colon-delimited row, since nothing in the data itself distinguishes a structural colon from an incidental one.

This is the same constraint every delimiter in this family works within: a delimiter only performs reliably when the source data is guaranteed not to contain it.

Straight answer

Will this correctly split a line containing a URL or a timestamp?

Not reliably. If a URL or a timestamp appears as one field among colon-delimited data, its own internal colons are split apart along with the genuine field boundaries, since this tool has no way to distinguish a structural colon from an incidental one.

For a clean positional record, such as a passwd-style line where colons only ever denote a boundary, the split behaves exactly as expected. Inspect the source data for any field that might carry its own colon before relying on the output.

Who it's for

Who uses a colon to JSON array converter, and when

System administrators use it to turn a line from '/etc/passwd', '/etc/group' or a comparable configuration file into a JSON array while scripting or documenting a server setup. Developers use it to parse a simple 'key: value' line pulled from a settings file or a note into a structured pair.

Anyone working with a legacy export or a fixed-format log using colons as its field separator, having checked for the timestamp and URL caveat, uses it to get one line into JSON without writing a dedicated parser.

FAQ

Colon to JSON array, answered precisely

All answered in full, nothing to click open.

How do I convert a colon-separated line to a JSON array?

Paste the line into the input field and press Convert. Each colon-separated value becomes one array item.

Is it free?

Yes. No signup, no length cap, no run limit, since the conversion runs on your own device.

Is my text uploaded anywhere?

No, the split runs entirely client side. Nothing is transmitted, stored or logged.

Will it split a timestamp like '14:30:00' apart?

Yes, every colon is a boundary, so a timestamp appearing in a colon-delimited line is broken up along with the genuine fields.

Will it split a URL apart at its colons?

Yes, the colon after the scheme and any colon before a port number are both treated as delimiters, fragmenting the URL.

Can I convert a passwd-style line with this?

Yes, that is precisely the format this converter targets, since every colon in that line genuinely marks a field boundary.

What happens to whitespace around each value?

It's trimmed automatically, so 'root : x : 0' returns as clean, trimmed items.

What happens with two consecutive colons?

The empty item between them is dropped, so an empty field doesn't produce a blank entry in the resulting array.

Is there a length limit on the input?

No. There's no cap and no run limit, only your device's own memory.

Does it work on phones?

Yes, the layout adapts to narrow screens.

What's the difference between this and the semicolon converter?

This splits on colons, common in positional records and key-value shorthand. The semicolon converter splits on semicolons, common in European CSV.

Can I split a simple key: value line?

Yes, 'name: value' converts into a two-item array, key first and value second.

Will an empty field in the middle of a record disappear?

Yes, the dropped empty item means the resulting array can have fewer entries than the record had fields.

Is there an API or batch mode?

Not currently. This is a single-line, browser-based converter.

Why did one of my fields get cut in half?

It likely contained its own colon, a time, a URL or a ratio, which this converter cannot distinguish from a field boundary.

Does it validate the resulting JSON?

The output is always syntactically valid JSON, built with JSON.stringify. It cannot confirm the split matched your data's actual structure.

Does this apply to Windows PATH-style variables?

No, Windows separates PATH entries with a semicolon, not a colon. Unix systems use a colon for that purpose.

Does this handle IPv6 addresses?

No, an address such as '2001:db8::1' is shattered at every colon, since this converter has no awareness of address formats.

Is confidential data safe to paste here?

Yes, nothing is transmitted anywhere. Processing happens locally in your browser.

How can I check whether a line is safe to split on colons?

Scan it for anything that isn't a genuine field boundary: a time, a URL, a ratio or an address. Absent those, a colon split is safe.

Does it respect quotes around a value the way a JSON parser would?

No. It has no concept of quoting or JSON syntax, so a colon inside a quoted string is split the same as a structural one. This is a plain character splitter, not a JSON parser.

Can I paste an already-formed JSON object into this?

You can, but the result won't be meaningful. Every colon in the object, including ones inside key-value pairs already valid on their own, gets treated as a delimiter and split apart.

Convert a colon-separated record to JSON.

Computed locally, no upload, no run limit.

Open the converter