> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bijection.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Realtime

> Building realtime apps with Bijection

Turns out Bijection is automatically realtime! You don’t have to do anything
special if you are already using [query functions](/functions/query-functions),
[database](/database/overview), and [client libraries](/client/react/overview)
in your app. Bijection tracks the dependencies to your query functions, including
database changes, and triggers the subscription in the client libraries.

```mermaid theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
sequenceDiagram
    participant A as Browser A
    participant B as Bijection
    participant C as Browser B
    A->>B: subscribe to query
    C->>B: subscribe to the same query
    A->>B: call a mutation
    B->>B: commit the change and rerun affected queries
    B-->>A: updated result
    B-->>C: updated result
```

Aside from building a highly interactive app with ease, there are other benefits
to the realtime architecture of Bijection:

## Automatic caching

Bijection automatically caches the result of your query functions so that future
calls just read from the cache. The cache is updated if the data ever changes.
You don't get charged for database bandwidth for cached reads.

This requires no work or bookkeeping from you.

## Consistent data across your app

Every client subscription gets updated simultaneously to the same snapshot of
the database. Your app always displays the most consistent view of your data.

This avoids bugs like increasing the number of items in the shopping cart and
not showing that an item is sold out.

## Learn more

Learn how to work with realtime and reactive queries in Bijection on
Stack.
