ToolMulti
Your everyday online toolkit

JSON String to Number

Convert all string type key values in JSON to number type

Tool Guide

Introduction

The online JSON value string-to-number type tool can quickly traverse all levels of JSON data and convert all values from string type to number type, removing the double quotes around numbers.

In JSON, a numeric value can be represented in 2 forms: as a number type such as {"id":123}, or as a string type such as {"id":"123"}. This tool can recognize and remove the quotes around number-type values.

Note that, due to the representation range of the Number type, a number value can be at most 9007199254740991 (you can enter Number.MAX_SAFE_INTEGER in the console to see the maximum value). Beyond that, the numeric result will lose precision and be represented in scientific notation, such as 1.23e+22.

The conversion result is by default a JSON string formatted with 4-space indentation. If you want to compress the JSON, enter 0 for the indentation space count.

After conversion, you can copy the JSON with one click or export it to a TXT file.