跳到主要內容
bobob

CSV 與 JSON 互轉工具

在 CSV 列與 JSON 陣列之間轉換,並檢查表頭、引號值與資料形狀。

只在瀏覽器裡處理輸入的內容不會送到伺服器。

輸入與結果

輸入的內容只存在這個瀏覽器。重新開啟可以還原上次的操作。

  • 在 CSV 列與 JSON 陣列之間轉換,並檢查表頭、引號值與資料形狀。
  • 以瀏覽器本機方式處理輸入,並在複製前檢查結果。
  • 搭配 CSV 與 JSON 互轉工具 與相關工具縮短工作流程。
常見輸入
id,name 1,Bob
用此範例檢查 CSV 與 JSON 互轉工具 的輸入流程。
典型輸出
[{"id":"1","name":"Bob"}]
複製前用來確認結果格式與後續檢查點。
附加範例
id , name , status 1 , Bob , active 1 , Bob , active
複製前用來確認結果格式與後續檢查點。
附加範例
[{"id":"1","name":"Bob"},{"id":"2","name":"Alice"}]
複製前用來確認結果格式與後續檢查點。
  • 在 CSV 列與 JSON 陣列之間轉換,並檢查表頭、引號值與資料形狀。
  • 如果瀏覽器本機處理方式和真實輸入結構不一致, 輸出不能直接信任。
  • 複製的值中如果混入正式密鑰、客戶資料或內部 URL, 分享前必須移除。
  1. 1再次比較原始輸入與輸出形態。
  2. 2確認目標執行環境、編碼、時區與安全政策差異。
  3. 3繼續用相關工具檢查 CSV 與 JSON 互轉工具 的結果是否適合下一步。
  • Any field with a comma, quote or newline must be quoted

    RFC 4180 requires such a field to be wrapped in double quotes, with inner quotes doubled. Skip it and every column shifts from that row on - the usual cause when an address or notes column corrupts a file.

    依據:RFC 4180

  • CSV records are separated by CRLF

    RFC 4180 specifies CRLF line endings. LF-only files usually parse, but mixed with newlines inside quoted fields a parser can mistake where a record ends and your row count changes.

    依據:RFC 4180

  • JSON is UTF-8 and carries no BOM

    RFC 8259 says JSON exchanged between systems is encoded in UTF-8 and implementations must not add a byte order mark. Carry over the BOM Excel writes and your first key name gains an invisible character, so lookups miss.

    依據:RFC 8259

CSV 與 JSON 互轉工具 的輸入在哪裡處理?

可行的處理會在瀏覽器中執行,但不要輸入正式密鑰或客戶資料。

結果可以直接用於正式環境嗎?

複製前請再次確認執行環境、編碼、時區與安全政策等環境差異。