Hosted backend

Sanity is powered by a secure and scalable real-time database.

An iconic face being represented on a multitude of services and devices

Apps, not ops

Focus on building business value, not running operations.

Cloud platform icon

Cloud based

  • Hosted and fully managed
  • Auto-scaling backends
Icon implying ease of use

Durable and reliable

  • Continuous DB backups
  • Versioned asset backups
  • Isolated offsite backups
European flag stars in Sanity colors

GDPR compliant

  • Fully GDPR compliant
  • Hosted in the EU
Icon of a lock implying security


  • Physical access staff background vetted
  • Data encrypted at rest and in transit
  • APIs are TLS / SSL only
Icon implying performance


  • Global load balancing with geo-routing
  • Optimized backend
  • Edge cached assets
  • Geo-routed API cache
Icon of concentric circles implying edge caching infrastructure

Global CDN

  • Distributed & Redundant infrastructure
  • Geographically distributed

Read about our Security and Compliance.

Powerful Query Language

GROQ - Graph Oriented Query Language

Ask for exactly the information your application needs. Join together information from several sets of documents. Stitch together a very specific response the exact fields you need.

  • Follow references
  • Relational joins on key-value data
  • Get exactly the data structures you need by reprojecting attributes
  • Bundle multiple queries in the same request and get it all cached.
  • Query on structured block text



Movies released after 1979

*[_type == 'movie' && releaseYear > 1979]

… ordered by release year and only certain fields

*[_type == 'movie' && releaseYear >= 1979]
  | order(releaseYear) {
    _id, title, releaseYear

Get actors and join in arrays of the titles of the movies they played in

*[_type == "person"]{
  _id, name,
      _type == "movie"
      && references(^._id)

Read more about our Graph Oriented Query Language (GROQ)

Drawing of an iconic face appearing on lots of different devices

Real world, real time

Unfortunately the world happens all at once

Systems should respond to events as they unfold. Sanity is therefore built as a real-time architecture from the bottom-up.


  • Patch-based updates
  • Transactional writes
  • Full revision history
  • Configurable consistency
  • Diff-match-patch for conflict free collaboration on block text

Get notified

  • Install webhooks
  • Listeners: Get streaming updates to queries
  • Hundreds of thousands of clients to listeners

Enterprise comforts

Sanity is Enterprise ready

An illustration of a business GNU
  • Handle millions of densely connected documents
  • Connect hundreds of thousands of real-time listeners
  • Single-sign-on (SSO) / Third party login integration
  • Free form security rules
  • Geographically cached endpoints
  • Service Level Agreement (SLA) available

Contact sales

Command Line Goodness

Sanity ships with a command line interface that makes it easy to create new projects and set up, import and tear down datasets.

Get started

npm install -g @sanity/cli && sanity init

Create and run new project

sanity init && sanity start

Create a new dataset

sanity dataset create myDataset

Export a dataset and associated assets

sanity dataset export myDataset

Install a webhook

sanity hook create myHook myDataset https://myCallbackURL

Query, slice and color it prettily

sanity documents query '*[_type == "movie"][0...5]' --pretty

Import your document

sanity import myJSON.json myDataset

Import reads new-line delimited JSON (NDJSON). It will very happily import your image assets both on local disk and from URLs. Afterwards references between objects will be made strong to ensure integrity. :tada:

Get the title, and have a cow say it

sanity documents get myDocId | jq .title | cowsay

Read the CLI documentation

Icon of image being cropped

Image pipeline

Deliver and transform images for any device

Sanity allows you to upload 268 megapixel archival originals. A flexible image pipeline will resize, crop and reformat on the way to clients. Set image hot-spots to recrop for any aspect ratio.

  • Hot-spots: Automatically crop for different aspect-ratios
  • Store archival grade originals
  • Ingest JPG, PNG & TIFF. GIF too (kittehs!).
  • Output JPG, PNG & WebP.
  • Pass-through for SVG & GIF or transcode to other formats.

Read more about the Image URL Builder Client or the image URLs