---
title: "Migrating"
description: "Import CSV, JSON Lines and Kafka data into SurrealDB."
canonical_url: "https://surrealdb.com/docs/integrate/migrating/from-files-and-streams"
section: "From files and streams"
surrealdb_version: "4.x"
last_modified: "2026-11-18T02:09:16Z"
---

> Full SurrealDB documentation index: https://surrealdb.com/docs/llms.txt

# Migrating

Import CSV, JSON Lines and Kafka data into SurrealDB.

This section details how to map data, queries and concepts you may know from other databases and datatypes into SurrealDB.

The sources in this section of the documentation can be automatically imported to SurrealDB using the [Surreal Sync](https://github.com/surrealdb/surreal-sync/) tool. In addition, [CSV data](/docs/integrate/migrating/from-files-and-streams/csv.md) can be automatically imported into SurrealDB Studio using its own [built-in functionality](/docs/reference/studio.md).

For a source that is not yet supported, export the data as [JSON Lines](/docs/integrate/migrating/from-files-and-streams/json-lines.md) and import it with Surreal Sync, or write it out as SurrealQL `INSERT` statements and load the file with [`surreal db import`](/docs/reference/cli/db/commands/import.md), which takes a SurrealQL file. Alternatively, you can use [one of the many available SDKs](/docs/languages.md) to access your existing database and transfer its content directly to a SurrealDB instance.

* [CSV data](/docs/integrate/migrating/from-files-and-streams/csv.md)
* [JSON lines](/docs/integrate/migrating/from-files-and-streams/json-lines.md)
* [Kafka](/docs/integrate/migrating/from-files-and-streams/kafka.md)
