Skip to content

In development. Expect rough edges and changes. The source code is not public yet.

Turso 3 min read Announcement mediumAdept

Turso Adds Ruby on Rails Support

Turso has released a technical preview of libsql_activerecord, an ActiveRecord adapter that connects Rails applications to Turso/libSQL databases. Setup takes three steps: add the gem, set adapter: libsql with a database url and auth_token in config/database.yml, and optionally set a local path for an embedded replica that syncs the remote database to a local file to remove network latency and allow offline work. The adapter also works outside Rails, in standalone ActiveRecord scripts and Sinatra apps, and supports migrations, CRUD, associations and raw SQL.

Assumes: Ruby on Rails basicsActiveRecord

Related posts

  • Announcing Laravel Support and PHP PDO Interface

    Turso mediumAdept

    Turso has released `libsql-laravel`, an official open-source Laravel adapter, along with a PHP PDO interface. Both are in technical preview. The adapter extends Laravel's SQLiteConnection, so existing SQLite-compatible code, Eloquent models, migrations and transactions work against local files or remote Turso databases. It replaces community drivers that needed custom PHP extensions but does require FFI to be enabled. A walkthrough builds a movie similarity search using `VectorCast`, the `vector` and `vectorIndex` migration helpers, and a `nearest` query builder method.

  • Toasty now fully supports Turso

    Turso mediumAdept

    Toasty, the async Rust ORM from Tokio's creator, now supports Turso in three modes behind one API: local files with optional concurrent writes (transactions automatically wrapped in BEGIN CONCURRENT), a serverless remote mode over HTTP with URL and auth token, and local-first sync with explicit pull/push calls. Only the driver constructor changes between modes, so the same models and queries run unchanged. For remote use, toasty::batch() combines independent statements into one round trip and returns typed tuple results, avoiding a network round trip per transaction statement.

  • We're building Postgres in Rust. Using the LLVM of databases

    Turso easyNovice

    Turso, a Rust rewrite of SQLite, is adding a Postgres frontend by parsing Postgres SQL into a common AST and compiling it to Turso's VDBE bytecode, turning the engine into an "LLVM of databases" with pluggable frontends. The argument is that SQL databases differ mostly in on-disk layout, not in core operations, so Postgres semantics can be expressed in or added to the VDBE. A C-to-VDBE compiler running Doom illustrates that the bytecode works as a real VM. The work starts from the earlier pgmicro experiment and is early-stage but runnable from source. Planned pieces include the Postgres wire protocol, embedded and in-browser use, live materialized views, and WASM-sandboxed extensions, aiming for broad rather than 100% compatibility.

  • Introducing React Native Bindings for Turso

    Turso mediumAdept

    `@tursodatabase/sync-react-native` is a single package that gives React Native apps on iOS and Android an embedded, SQLite-compatible Turso database plus optional bidirectional sync with Turso Cloud via `pull` and `push`, enabling offline-first apps. The native JSI layer is kept thin as a bridge to SDK-KIT, while async network IO and SDK logic live in TypeScript; this makes debugging, unit testing and iteration easier without native rebuilds. The bindings require React Native 0.76+ with the New Architecture and iOS 13.0+. Partial sync, an Expo plugin and real-time subscriptions are planned.

  • Migrating data from MySQL to Turso

    Turso mediumAdept

    Moving a MySQL database to Turso takes three commands: dump it with mysqldump using --skip-extended-insert, convert the dump to a SQLite file with the mysql2sqlite script piped into sqlite3, then create a Turso database from that file with `turso db create --from-file`. Row counts can be checked with the sqlite3 shell after conversion and with `turso db shell` after import. Larger migrations may hit issues that need extra help.

The quest for software engineering knowledge.

Look:
Layout: