How it works

Galacha has four moving parts. You install one. We run the other three.

The pieces

PieceWhere it runsWhat it does
SDKIn your app (browser / device)Records events, buffers them, ships them to the API
APIapi.galacha.meValidates the project key, writes events to storage
StorageOur managed tierHolds session events + replay frames
Dashboardgalacha.meQueries storage, plays sessions back, shows errors + metrics

The flow

  1. You drop in the SDK via <GalachaProvider> or a <script> tag.
  2. The SDK generates a visitor ID (first run) and a session ID (first activity), both scoped to your project.
  3. The SDK starts recording: DOM snapshots, clicks, navigation, network calls, errors, console logs.
  4. Events batch into a buffer. Every 5s (or when the buffer hits 50 events), the batch is gzipped and POSTed to api.galacha.me/api/v1/events.
  5. The API validates your project key, attributes the events to the right project, and writes them.
  6. Open the dashboard. The replay shows up within a few seconds.

A concrete example

// Your app
<GalachaProvider projectKey="4d4b83bcd00a...">
  <App />
</GalachaProvider>

That one line does all of the following on mount:

  1. Injects <script src="https://sdk.galacha.me/sdk/latest/galacha.umd.js"> into the page head.
  2. Calls Galacha.init({ projectKey }) once the bundle loads.
  3. Patches fetch / XHR / history / window.onerror.
  4. Starts rrweb's DOM recorder.
  5. Stores a visitor ID in localStorage (persists across tabs + reloads).
  6. Stores a session ID in memory, starts the 30-minute idle timer.
  7. Opens a buffer and starts the 5s flush interval.

When the user clicks a button: rrweb serializes the click + the DOM mutation, pushes to the buffer. On the next flush tick, the batch goes out.

What you don't do

  • No servers to run.
  • No database to manage.
  • No rrweb to vendor — the recorder lives on our CDN, your React package just loads it.
  • No background workers for processing replays.

You sign up, create a project, get a project key, drop it in, watch replays. That's the whole operation.

Related