返回资讯中心
外部精选
软件工程
#开发者实时流

Serverless LibSQL

SQLite-compatible, edge-friendly, with HTTP and WebSocket drivers. Free tier, the same SQL you already know, cloud or self-host with the Layerbase CLI.

Hacker News 最新cs19962026/10/19 · 27 天前19 分钟阅读

以下正文同步自 Hacker News 最新,版权归原站所有,已转换为易读排版。

libSQL

Serverless libSQL

SQLite-compatible, edge-friendly, with HTTP and WebSocket drivers. Free tier, the same SQL you already know, cloud or self-host with the Layerbase CLI.

Free tier, no credit card

Create libSQL freeCreate an account

SQL Console

libSQL

Tables

The libSQL client wraps SQL queries in HTTPS calls, so Cloudflare Workers, Vercel Edge, and any runtime that cannot hold a TCP socket can talk to a libSQL endpoint. Point the same client library Turso users already have at the URL and auth token from the dashboard, and the SQL you write is still SQLite SQL. It hibernates when idle, wakes on the next connection, and branches copy-on-write like the rest of the branchable engines.

import { createClient } from '@libsql/client' const db = createClient({ url: 'https://your-host.cloud.layerbase.dev', authToken: process.env.LIBSQL_AUTH_TOKEN })

Quick start

Edge and serverless apps that want SQLite semantics, multi-region replication patterns, and projects already on Turso that want a portable alternative.

const db = createClient({ url: 'https://your-host.cloud.layerbase.dev', authToken: process.env.LIBSQL_AUTH_TOKEN })

Where to run it

One database, three places it can live. Pick the speed you want and move between them when you outgrow it.

Layerbase Cloud

libSQL in seconds. Free tier, no card.

Run libSQL locally with the same dashboard and query console.

Layerbase CLI

Run libSQL from the terminal, locally or on your own infra.

libSQL is SQLite with a network in front of it: the SQL you already know, reachable over HTTP and WebSocket from edge runtimes. This is what the Free plan includes and where the line is.

The Free plan covers 2 databases, 5 GB of storage, and up to 20 concurrent connections. libSQL is one of the engines you can create on it. There is no trial clock on the plan and no expiry date.

HTTP and WebSocket drivers, so edge runtimes work

libSQL is served over HTTPS, which means the official client works from Cloudflare Workers, Vercel Edge, Deno, and anywhere else a raw TCP socket is not available. The same database is also reachable from an ordinary Node or Bun process.

It sleeps after 15 minutes idle and wakes on connect

A free libSQL database hibernates after 15 minutes with no requests; paid plans wait 6 hours. A hibernated database keeps its hostname and data volume, and the next HTTP or WebSocket request wakes it in roughly 1 to 5 seconds rather than failing.

Forget about it and it archives, it does not vanish

A free database left hibernated for 14 days is archived (7 days if you never connected to it): its address is released and it takes an explicit Restore, roughly 10 to 30 seconds, to bring it back. Data and backups are kept. After 90 continuous days archived the live resources are reclaimed and the most recent backup is kept and still restorable in one click. Paid plans are never auto-archived.

No card on Free. Solo is $5/mo and Pro is $15/mo when you outgrow it.

libSQL is the Turso-backed open-source fork of SQLite that adds HTTP and WebSocket access on top of the SQLite engine, so edge and serverless runtimes can query it without holding a TCP socket open. The SQL you write is still SQLite SQL. Layerbase runs it as a managed database on the Free plan, with a web SQL console, and the same client library Turso users already have connects to it.

libSQL is the Turso-backed fork that adds HTTP and WebSocket drivers and remote-friendly features. Pick libSQL when you want edge-runtime access; pick SQLite for the bare upstream engine.

Yes. libSQL on Layerbase speaks the same protocol and ships with the same client library Turso users already have.

The libSQL client wraps SQL queries in HTTPS calls so edge and serverless runtimes (Cloudflare Workers, Vercel Edge) can talk to a libSQL endpoint without a TCP socket.

libSQL is in the Free tier. Your database hibernates after 15 minutes of inactivity and wakes on the next connection; upgrade if you need always-on or larger storage.

Yes. The Layerbase CLI and Layerbase Desktop both run libSQL with the same install workflow.

Branch libSQL in seconds

Fork a running libSQL into a full, isolated copy with its own connection string. Copy-on-write makes it near-instant, not a dump and restore. Point a preview deploy at it, test a migration, then throw it away. Layerbase branches 16 engines, not just Postgres.

The same primitives on every libSQL database: TLS, web console, hibernation, and a real dashboard. The rows that need a paid plan say so on the row; nothing here is hidden behind a sales call.

Query console in the dashboard, no extra client to install.

All connections encrypted. No setup required.

Pin a database to your plan's always-on pool so it never hibernates. Free has no pool, so a free database always sleeps when idle; Solo includes 768 MB of pool and Pro 1.5 GB.

Hibernates when idle. Wakes on the next connection.

Pooled endpoint for serverless and edge workloads.

Bypass the pooler for migrations and replication.

Engines whose own wire protocol speaks HTTPS. Every database, including this one, is also queryable over the platform's HTTPS query API and web console.

Drop-in HTTP driver for edge runtimes (Neon serverless, PlanetScale, Upstash REST, or the engine-native client).

Restrict access to specific IPs or CIDR ranges.

Scheduled dumps and volume snapshots with one-click restore on paid plans. Free includes 1 manual backup slot you take and restore yourself.

Plans are flat. There is no per-hour compute meter, no per-database line item, and no ingress or egress fee, so the bill does not change shape when your traffic does. You do not need an AWS, GCP, or Azure account either: Layerbase runs the infrastructure.

Every engine, plus a bigger always-on pool.

Competitor facts verified September 7, 2026 against each vendor's own pricing and documentation pages: Turso.

Already have data? Migrate it from Cloudflare D1, Turso Any connection string works too.

Email and password plus OAuth sign-in, scaffolded on the SQL database you already run.

If you do not need the HTTP or WebSocket driver and want the bare upstream engine, point your client at SQLite on Layerbase instead. Both run on the same platform.

Supabase announced it is buying Turso, the company behind libSQL, alongside another $150M. Nothing breaks today. The part worth your attention is how few companies now own the default database for small projects, and what that does to pricing later.

libSQL is the open source SQLite fork. Turso is the company behind it, its managed platform, and now a separate Rust rewrite with the same name. Here is how the three fit together in September 2026.

A SQLite file stops working the moment something other than one process needs it. Here is how to put the same file behind an address, with a Postgres driver or the libSQL client, without rewriting a schema.

We built importers from Cloudflare D1 and Turso into libSQL and found seven data-fidelity bugs. They turned out to be the same two bugs, and neither one is really about SQLite.

D1 is SQLite, so your SQL is portable. The coupling is somewhere else: there is no wire protocol, the SQL export rounds any integer past 2^53, and you cannot get the file underneath. Here is an honest inventory, the alternatives, and when staying on D1 is the right call.

libSQL is developed by the libSQL project. Layerbase packages and hosts official releases; the engine itself is built upstream.

正文由 探How 从来源站点 RSS 同步,内容未经改写;遇到排版缺失或需要图片、视频时请以原文为准。

打开原文
去社区讨论 →