---
title: 'Cratis Chronicle: event-sourcing database'
editUrl: https://github.com/Cratis/Chronicle/edit/main/Documentation/index.mdx
description: Cratis Chronicle is an event-sourcing database and runtime that stores application changes as events, builds read models, and runs reactions.
lastUpdated: 2026-11-05T00:00:00.000Z
---

Cratis Chronicle is an open-source event-sourcing database and runtime that keeps the changes your application records, builds queryable views from them, and runs reactions when events arrive. Use it when you need to explain how an order reached its current state or build a new view from its history, rather than keep only the latest row.

**Store events. Declare read models.**

Record a fact such as `OrderPlaced`, then declare how it changes the views your application reads. Chronicle processes the events and updates those views for you. [Start with a local kernel and your client](/chronicle/get-started/).

## What Chronicle takes care of

An event log answers what happened. To show an order summary or a list of outstanding orders, you also need a **read model**: data shaped for a particular query. Chronicle's [declarative projections](/chronicle/projections/) describe how events map onto those models. You define the mapping; the kernel processes events and writes the resulting changes to read-model storage. The same events can feed several views without duplicating the recorded history.

When a recorded change should send a notification or call another service, use a [reactor](/chronicle/reactors/). A reactor runs application code in response to events. It consumes the history alongside projections; it does not have to wait for a view to update.

:::note[Read model consistency]
Materialized read models update **after** an event is appended, not inside the append. A query immediately after a write can therefore lag behind it. See [read model consistency](/chronicle/read-models/consistency/) for when to wait for a materialized view or compute state on demand.
:::

## How do you handle personal data in event history?

Keeping history also means planning for personal data. Chronicle can encrypt fields marked as **personally identifiable information (PII)** with a key tied to the person the data concerns. Erasing that key makes the encrypted values unreadable without removing the event's place in the log. Start with [compliance and PII](/chronicle/compliance/) before modeling personal data, and use [regulatory responsibilities](/chronicle/compliance/regulatory-responsibilities/) to separate these mechanisms from the obligations your application and deployment must meet.

## Which clients and storage providers can you use?

Chronicle's .NET kernel, built on Microsoft Orleans, connects through gRPC, a language-neutral remote-call protocol, to clients for .NET, TypeScript, Kotlin, Java, and Elixir. It offers storage providers for MongoDB, PostgreSQL, Microsoft SQL Server, and SQLite. [Architecture](/chronicle/architecture/) explains those boundaries. Client capabilities and provider behavior are not interchangeable; follow the setup and capability guidance for the client and storage you choose.

## Start here

Begin with [Get started](/chronicle/get-started/) to run a local kernel, choose a client setup guide, and append your first event. If you are still deciding whether to adopt event sourcing, read [when event sourcing pays off — and when it does not](/chronicle/concepts/when-to-use-event-sourcing/).

  [Get started](/chronicle/get-started/)

  [When event sourcing pays off — and when it does not](/chronicle/concepts/when-to-use-event-sourcing/)

For a guided example, follow the library tutorial. The architecture and workbench guides help when you need to understand or inspect the running system.

  **Tutorial**

    [Build a small event-sourced library one concept at a time](/chronicle/tutorial/).
  
  **Why Event Sourcing**

    [Understand why Chronicle keeps meaningful changes instead of only current state](/chronicle/why-event-sourcing/).
  
  **Understand the architecture**

    [Locate the protocol surfaces, kernel, runtime scopes, and persistent subscriptions](/chronicle/architecture/).
  
  **Inspect with Workbench**

    [Browse runtime state and try supported projection mappings in the bundled workbench](/chronicle/workbench/).
  
## Run Chronicle locally

With Docker installed, you can start the kernel before writing application code. Use `latest-development` for this local evaluation: it bundles Chronicle and MongoDB and tracks the newest published development image. For a repeatable setup, pin a released version in your application or deployment configuration rather than copying an image digest into a getting-started command.

This command exposes only the kernel port, `35000`; the bundled MongoDB stays
inside the container. For a setup that also exposes MongoDB on port `27017` so
local database tools can connect, see the [two-port host quickstart](/chronicle/get-started/choose-hosting-model/#run-chronicle-locally).

1. Pull and start the current development image with Chronicle available only
   on this machine. MongoDB remains internal to the container.

   ```bash
   docker run --pull=always --rm -d --name chronicle \
     -p 127.0.0.1:35000:35000 \
     cratis/chronicle:latest-development
   ```

1. Wait for the local health endpoint to report readiness. The development
   image uses a self-signed certificate, so this command disables certificate
   verification only for this local check.

   ```bash
   curl --insecure --fail --retry 30 --retry-all-errors --retry-delay 1 \
     https://localhost:35000/health
   ```

   A successful response prints `Healthy`. You can now [connect an application](/chronicle/get-started/#pick-a-client) or open the workbench at `https://localhost:35000`.

1. Stop and remove it when the evaluation is complete.

   ```bash
   docker rm -f chronicle
   ```

:::caution[Keep the development setup local]
The development image uses well-known credentials and a self-signed certificate. Keep it on this machine. `Healthy` tells you that the container started; it does not validate security, durability, scale, compatibility, or suitability for your production topology. Client and provider capabilities still need to match your application. Self-hosting does not include a managed service or a support commitment.
:::

## Independent-use boundary

You can run Chronicle and its bundled workbench without Studio, Arc, or Components. Start the kernel, connect your chosen client, and use the workbench to inspect it. Your application still needs packages, protocols, and configuration compatible with that Chronicle server.

## Inspection surfaces

Open [Chronicle Workbench](/chronicle/workbench/) to inspect the event stores and namespaces you are authorized to access, check observer state, or try the projection behavior supported by your running image. This browser tool is bundled with Chronicle; you do not need Studio to use it. For terminal inspection and diagnosis, use the [Cratis CLI](/cli/).

Permission to inspect does not grant permission to append, revise, redact, replay, or recover data. These tools do not promise complete administration or governed production mutations, nor do they establish client parity or federation. Self-hosted inspection is separate from a managed service, support, or a service-level agreement (SLA).

## Continue

  **Architecture**

    [Understand the kernel, protocol, store, namespace, and subscription boundaries](/chronicle/architecture/).
  
  **Workbench**

    [Inspect Chronicle from the bundled local browser application](/chronicle/workbench/).
  
  **Cratis CLI**

    [Terminal inspection and diagnosis for Chronicle](/cli/).
  
  **Operating Chronicle**

    [Diagnose failures and recover observers and partitions](/chronicle/operations/).
  
  **Chronicle source**

    [Owning kernel, client, Workbench, and package source](https://github.com/Cratis/Chronicle/tree/main/Source).
