All posts

How to Convert a CSV Lead List to JSON

··3 min read

To convert a CSV lead list to JSON, upload it to the CSV to JSON converter, choose one array or one object per line, and download the file. Each row becomes an object, and the header row gives the keys.

This guide covers the choices that matter for a lead list: the shape of the file, how values are written and what to do with blanks.

What you need

  • A CSV or .xlsx file with a header row, or the cells copied from a sheet.
  • To know where the JSON is going: an API request, a webhook, a database loader or a test file.

Step 1: load the list

Upload the file or paste the cells with the header row first. The header names become the keys, so tidy them first if they are untidy. A blank header becomes column_1 by position, and a repeated header gets _2 on the second one.

Step 2: pick the shape

Shape Looks like Good for
One array [ {...}, {...} ] A request body, a config file, a small list
One object per line {...} on each line A large list, loaders that read line by line

If the API says it takes "an array of contacts", use the array. If a loader says NDJSON or JSON Lines, use one per line.

Step 3: decide how values are written

By default every value stays as the text in the cell. That is the safe choice for lead lists. A phone number such as 0123456789 or a zip code such as 02134 loses its leading zero if it becomes a number, and a very long ID can lose digits.

Tick the typed option only when the API needs numbers or booleans. Plain whole numbers and decimals become numbers and true or false become booleans. Values with a leading zero, and values of 16 or more digits, stay text either way.

Step 4: decide how blanks look

A blank cell becomes an empty string, or null if you tick that option. Some APIs treat a missing value, null and "" differently, so read the API's notes before you choose. When unsure, send a few rows first and read the response.

Step 5: check, then send

Read the first rows shown under the result. Then download the file or copy the JSON. Send three rows before you send three thousand.

Check the list before it goes anywhere

A JSON file is the same list in a new format. Dead mailboxes and role addresses are still in it. Before you load it into an API or a sender, upload the CSV to check the addresses. The first checks are free with a Google sign-in, and the pricing page lists the plans if you have more. For a routine to follow, see how to clean an email list and the list quality check.

If you go the other way, the JSON to CSV converter turns an array back into rows. To load a list into a database instead, see how to turn a lead list into SQL INSERT statements.

Common problems

  • The API rejects a number as text. Tick the typed option, or convert that one column on the receiving side.
  • A zip code or phone number lost its zero. Leave typed values off.
  • A comma inside a name split the row. The file was not quoted as standard CSV; export it again from the source, quoting cells that hold commas.
  • Only some columns appear. The converter reads the first sheet of a workbook, so check you are on the right sheet.

Frequently asked questions

Does the converter change my data? It changes the format only. Text stays as it is, apart from the options you choose.

Can it make nested JSON? No. Each row becomes a flat object.

Does it work for a large list? It runs in your browser with no row cap, and an uploaded file can be up to 25 MB.

Common questions

How do I convert a CSV to JSON?

Upload the CSV to the CSV to JSON converter or paste the cells with the header row first. Each row becomes an object whose keys are the column names. Choose an array or one object per line, then download or copy the result.

Why did my phone number lose its leading zero?

A leading zero is dropped when a value is written as a number. Keep the value as text. The converter keeps numbers with a leading zero as text even when you turn typed values on.

What is NDJSON?

One JSON object per line with no surrounding array. It lets a program read a large file one line at a time.

Is my file uploaded?

No. The converter runs in your browser.

Check your list before you send

Real mailbox checks over SMTP, and nothing is sent to the address. Sign in with Google and your first 100 email checks are free, no card. Plans for bigger lists are on the pricing page.