Withdata Software

Convert TXT to JSON

Want to convert TXT file to JSON file?

Try Withdata Data File Converter, a desktop TXT to JSON converter for Windows, MacOS, and Linux, Convert TXT to JSON, Easy and Fast.

Download Withdata DataFileConverter
Windows 64 bit
Windows 32 bit
Linux .deb (For Debian, Ubuntu) 64 bit
Linux .rpm (For Red Hat, Fedora, SUSE) 64 bit
MacOS 64 bit

Convert TXT to JSON

Choose TXT file -> Set JSON file -> Convert TXT to JSON

“Start a New Convert” for “TXT to JSON”.

Select From “File” “TXT” To “File” “JSON”.

1. Open source TXT file.

Support large TXT file ( > 4GB ).

Don’t worry about the delimiter, DataFileConverter will automatically determine the delimiter, includes comma, tab, colon, semicolon, pipe, hash (octothorpe), slash, asterisk, white space, and you can also enter a delimiter.

Source TXT file’s content is like this:

2. Config target JSON file.

3. Set rows options.

4. Convert TXT to JSON.

After converting, you can view the output JSON file.


More about TXT to JSON converter

See Video: Convert TXT file to JSON file

See also:

TXT → JSON reference

Type mapping

Value kindin TXTin JSON
Int1234, or right-aligned in a fixed-width column1234 (number)
Decimal1234.561234.56 (number)
Float1.234e+101.234e10 (number)
Textwritten as-is; padding depends on the chosen layout"text" (string)
Long textwritten as-is"multi-line\ntext" (escaped newline inside a string)
Datewhatever the writer chose"2026-09-18" (string)
Datetimewhatever the writer chose"2026-09-18T14:30:00Z" (string)
Binarynot representable"base64:..." (string)
BooleanY / N, or 1 / 0, or TRUE / FALSEtrue / false (boolean)
JSONwritten as-isnested object or array, kept as structure

Dialect differences

Both TXT and JSON are file formats, so what differs below is how each one chooses to represent a value.

Propertyin TXTin JSON
identifiersNone by conventionDouble quotes; backslash escapes
datesWhatever the writer produced; no convention is guaranteedNo date type: dates arrive as strings and the reader must p...
binaryNot supportedNot supported natively - base64 inside a string
separatorWhatever was chosen - often fixed column widthsBraces and commas
encodingNo declaration - UTF-8 works only with a BOMUTF-8 by definition
typingNone - every field is textstring, number, boolean, null, object, array - no date type
shapeFree form; a parser has to be told the layoutNested objects and arrays
ceilingNo formal limitWhole document is usually parsed into memory

Convert TXT to JSON the easy way

Use the TXT to JSON converter — an offline desktop app for Windows, macOS and Linux. Nothing to upload, large files and batch runs supported (free trial).