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

# Overview

> Run Lekalao on your own servers.

Lekalao installs on an ordinary Linux server. Your lists, your content and your statistics stay with you. E-mails leave through the sending providers you choose: Amazon SES, Postmark, Mailgun, SendGrid, Brevo, Resend or any SMTP server.

## The architecture

```mermaid theme={null}
flowchart LR
  subgraph Server
    N[Nginx] --> F[PHP-FPM<br/>Lekalao]
    F --> P[(PostgreSQL)]
    F --> R[(Redis)]
    H[Horizon<br/>workers] --> R
    H --> P
    C[cron<br/>scheduler] --> R
    S[SMTP relay<br/>optional] --> P
  end
  U[Team and subscribers] --> N
  H --> E[Sending providers]
  E -. bounces, complaints .-> N
  A[Your applications] --> N
```

| Piece              | Role                                                                                  |
| ------------------ | ------------------------------------------------------------------------------------- |
| **The web app**    | The interface, the API, the public pages, open and click tracking, incoming webhooks. |
| **PostgreSQL**     | Every piece of data.                                                                  |
| **Redis**          | Queues, cache, sessions.                                                              |
| **Horizon**        | The workers: sending e-mails, imports, outgoing webhooks.                             |
| **The scheduler**  | One cron line: scheduled campaigns, statistics, automations, purges.                  |
| **The SMTP relay** | Optional: takes e-mails from other software.                                          |

## The road

<Steps>
  <Step title="Prepare the server">
    PHP 8.4, PostgreSQL, Redis, Node.js. See
    [Requirements](/self-hosting/requirements).
  </Step>

  <Step title="Install">
    Code, dependencies, database, first account. See
    [Installation](/self-hosting/installation).
  </Step>

  <Step title="Start the processes">
    Horizon, cron, and the relay if you need it. See
    [Processes](/self-hosting/processes).
  </Step>

  <Step title="Set it up">
    `.env` and `config/lekalao.php`. See
    [Configuration](/self-hosting/configuration).
  </Step>

  <Step title="Secure it and watch it">
    See [Security](/self-hosting/security) and
    [Monitoring](/self-hosting/monitoring).
  </Step>
</Steps>

## Two ways to run it

* **For your own organisation**: one operator, one or several teams, registration closed. That is the default.
* **As an online service**: registration open, plans, payments, several customers kept apart. See [Online-service mode](/self-hosting/cloud-mode).
