Skip to content
Chatto v0.5.0

Quick Start

Alright, here’s some stuff you should know before diving in. Please do not skip this part! You will have a significantly easier time setting up Chatto:

  • Chatto is extremely compact; it’s just a single binary (or Docker image) that you spin up to get a functional chat server.
  • It can be configured through a config file (chatto.toml) or through environment variables.
  • You can let Chatto store uploaded files, or configure an S3 compatible object store.
  • Voice and video calls are powered by LiveKit, which you will need to deploy separately (but don’t worry, we’ll guide you through it.) LiveKit is fully optional; if you don’t need call functionality, you can safely skip it.

We’ve saved the most important fact for last. Read it thoroughly, then read it again, because if you don’t, you will eventually lose your data:

  • Chatto does not use a database. Instead, it persists its data in something called NATS. For simple single-process deployments, Chatto can run an embedded NATS server; but if you want to move to multiple processes (either for scaling, redundancy, or zero-downtime updates), you will need to set up and run a separate NATS server. (This is also very easy, and we’ll guide you through it. Also, you can move from one setup to the other easily, so it’s not a big decision you need to make beforehand.)

That’s it. For now. Let’s dive in.

The quickest and easiest way to give Chatto a try is to just download the executable and run it. Setting up a proper production environment can be a little more involved (depending on your requirements), but if you just want to test the waters, this will get you up and running within minutes.

  1. Install Chatto:

    Terminal window
    brew install chattocorp/tap/chatto

    If you don’t have Homebrew, download the Linux, macOS, or FreeBSD archive for your platform from GitHub Releases. Support for more package managers will be added with time!

  2. Generate a configuration file:

    Move to an empty directory and have Chatto generate a configuration file:

    Terminal window
    chatto init

    For fullscreen terminal setup, run chatto init --interactive (or -i). Press Enter on the welcome page to begin. Use ↑/↓ or Tab/Shift+Tab to move between questions, and ←/→ to change choices. Press Enter on Continue to open the next page. The wizard asks for the port and public URL on the Server page. The Access page controls registration, password login, and optional OpenID Connect single sign-on (SSO). Other pages configure embedded or external NATS, search, calls, and optional SMTP settings. Review your choices before you create the files. Cancel or press Ctrl+C to exit without creating files.

    The output path is chatto.toml, or the path you supply with --config. If that file exists, setup exits before opening the wizard. It does not edit existing configurations. --with-search and --with-livekit set the initial feature choices. Interactive setup requires a terminal. For scripts, use chatto init without --interactive.

    For SSO, enter your provider’s issuer URL and client credentials, then register the redirect URI shown by the wizard with your provider. SSO account creation has a separate switch from password registration. Keep password login enabled for first-run owner setup. To use SSO-only login, link the owner account to SSO before you disable auth.direct_login and restart Chatto.

    Embedded NATS stores data in ./data. For external NATS, enable JetStream on your server and supply its connection and authentication settings.

    This creates a chatto.toml with random secrets for cookie signing, cookie encryption, runtime-token verifiers, asset signing, and NATS authentication.

    To include a local LiveKit server configuration for calls, use chatto init --with-livekit. See voice and video calls for startup and deployment instructions.

    To enable message search and its bundled provider, add --with-search. You can combine both flags: chatto init --with-livekit --with-search. See Search for index storage and configuration.

    Take a minute to review this file. It is already a working configuration, but you can customize it. Configure SMTP or JMAP if Chatto must send transactional email.

  3. Start the server:

    Terminal window
    chatto run
  4. Complete setup at http://localhost:4000, or the address you configured.

    Choose a server name, an optional description, and your owner account’s username, display name, and password. Then sign in with that account. Email delivery is not required for setup. Keep access to the new server restricted until you finish: the first visitor can create its owner.

    Existing servers do not show the wizard. For an automated installation, set skip_setup_wizard = true in [core] and create accounts with the local operator API. This flag does not reset completed setup.

The generated chatto.toml contains a sane set of defaults to get you started. After getting to know your new Chatto server for a little bit, it is strongly recommended to review and fine-tune this file, especially if you’re interested in support for video uploads, push notifications, SSO, or voice and video calls.

You will probably want to deploy Chatto in a manner that makes it reachable from the Internet, possibly from a VPS, a Kubernetes cluster, or similar; please move on to our Deployment guides section that will guide you through various different setups.