• Start

Overview

REST API

SurrealDB exposes an HTTP-based REST API for executing queries, managing authentication, and performing CRUD operations.

Any language or tool capable of making HTTP requests can interact with SurrealDB through this API. This is useful when an official SDK is not available for your stack, or when you need to integrate SurrealDB with infrastructure tooling, scripts, or third-party platforms.

  • Query execution — send SurrealQL statements over HTTP and receive results as JSON.

  • Authentication — sign in, sign up, and manage tokens via dedicated endpoints.

  • CRUD operations — create, read, update, and delete records using RESTful conventions.

  • Health and status — check whether the server is running and accepting connections.

The full HTTP protocol reference, including request and response formats, authentication headers, and endpoint specifications, is available in the HTTP protocol page.

If you prefer a richer client experience, SurrealDB also supports:

  • WebSocket protocol — persistent connections with real-time capabilities.

  • Official SDKs — language-specific clients for JavaScript, Python, Rust, Go, Java, .NET, and PHP.

Was this page helpful?