## TL;DR

Fixed in 0.6.2 (reporter confirmed, thanks to giovannibenussi). If you hit this, upgrade past 0.6.1.

## The error

```text
After updating to version [0.6.1](https://www.npmjs.com/package/@libsql/client/v/0.6.1), I'm getting `Error: Unexpected end of JSON input`
Uncaught SyntaxError: Unexpected end of JSON input
```

## Fix

1. Fixed in 0.6.2 (reporter confirmed, thanks to giovannibenussi).
2. If you hit this, upgrade past 0.6.1.

Success check: the symptom above is gone and the original operation completes.

## When to use

- You hit this exact symptom in libsql-client-ts.
- You want the verified fix without digging through the thread.

## When not to use

- A different error in libsql-client-ts, even a similar-looking one.
- General libsql-client-ts setup or credential questions.

## Compatibility

- Libsql Client Ts (tursodatabase/libsql-client-ts) Reported against version 0.6.0.

## Variant phrasings

- How to fix "libsql/client@0.6.1 + Next.js" in libsql-client-ts
- libsql-client-ts: libsql/client@0.6.1 + Next.js

## Root cause

[tomek-f (reporter)]: Regression in @libsql/client 0.6.1 - `Error: Unexpected end of JSON input` (SyntaxError at JSON.parse) in a Next.js 14 app that worked on 0.6.0.

## Source

- https://github.com/tursodatabase/libsql-client-ts/issues/216