CrypterChat App

Self-Hosted Server Guide

Take full control of your private communication. Deploy your own zero-knowledge, end-to-end encrypted backend for the CrypterChat app.

Get Started

How CrypterChat Works

CrypterChat is designed with a decoupled architecture. The iOS and Android mobile apps act strictly as dumb clients. They handle the UI, push notifications, and local keystore management, but they rely entirely on your private server to route encrypted messages.

End-to-End Encryption
All messages are encrypted on the device using AES-256-GCM and Curve25519. Your server only ever sees ciphertext. It cannot read any message contents.
Zero-Knowledge Storage
The server acts as a relay. It queues encrypted payloads in PostgreSQL just long enough for the recipient device to pull them, after which they are instantly wiped.

Prerequisites

1
Node.js (v18 or higher)
Required to run the WebSocket and Express server runtime.
2
PostgreSQL (v14 or higher)
For storing user credentials, public keys, and encrypted message queues.
3
Redis (Optional but Recommended)
Required for horizontal scaling of WebSocket connections across multiple instances.

Quick Start Guide

1. Clone the server repository
git clone https://github.com/ericksonholding/crypterchat-server.git
cd crypterchat-server
2. Install dependencies
npm install
3. Configure your database

Copy the example environment file and add your PostgreSQL connection string.

cp .env.example .env
# Edit .env and set DATABASE_URL
4. Run database migrations
npm run db:migrate
5. Start the server
npm run start

Environment Variables

VariableDescriptionRequired
PORTThe port the server binds to (default: 3000)No
DATABASE_URLPostgreSQL connection stringYes
JWT_SECRETSecret used to sign client authentication tokensYes
REDIS_URLRedis connection for WebSocket pub/subNo
Connecting the Mobile App

Once your server is running, open the CrypterChat app on your iOS or Android device. Navigate to Settings > Advanced > Custom Server and enter your server URL (e.g., https://chat.yourdomain.com).

Docu: Ecosystem & Public Repositories

Access complete technical documentation powered by Docsify covering chatscan, WebApp, smart contracts, cryptographic protocols, and security rules.