moreweb Messenger is a self-contained chat application built in a single PHP file. It bridges the gap between privacy and persistence by using the server purely as an ephemeral courier while storing chat history permanently in the user's browser.
- Zero-Knowledge Server: Messages are deleted from the server database immediately upon delivery. The server has no knowledge of your chat history.
- Browser Persistence: Chat history is stored locally in your browser's
localStorage, ensuring you keep your data without leaving a footprint on the server. - End-to-End Encryption (E2EE): Optional "Secret Mode" using the Web Crypto API (ECDH + AES-GCM) ensures the server cannot read your messages even while they are in transit.
- Single File Deployment: The entire application runs from a single
index.phpfile. No Composer, Node.js, or complex installation required. - Modern UI: A sleek, dark-themed interface with a vertical navigation rail, mobile responsiveness, and smooth interactions (no heavy animations).
- Rich Messaging:
- Emoji Reactions.
- Reply/Quote functionality.
- Image Sharing (Base64 encoded).
- Group Chats:
- Public Groups: Join via a generated 6-digit code.
- Private Groups: Invite-only (database level).
- Notifications: Built-in notification center for missed messages.
- PHP 7.4 or higher.
- PDO SQLite extension enabled (Standard on most hosts).
- Write Permissions: The script must be able to create and write to
chat_mw.dbin its directory. - HTTPS (SSL): Required for End-to-End Encryption features (Browsers block the Web Crypto API on insecure HTTP connections, except
localhost).
- Download: Download the
index.phpfile from this repository. - Upload: Upload the file to your web server (e.g.,
public_html/messenger/index.php). - Permissions: Ensure the folder containing the file is writable by the web server.
- Linux/Unix:
chmod 755orchmod 777on the folder.
- Linux/Unix:
- Run: Navigate to the URL (e.g.,
https://yourdomain.com/messenger/). - First Run: The database (
chat_mw.db) will be created automatically.
Unlike traditional messengers, moreweb Messenger does not keep a history on the server.
- Sender posts a message to the database.
- Recipient polls the server.
- Once the recipient fetches the message, the server executes a DELETE command in the same transaction cycle.
- The message now exists only in the recipient's and sender's browser
localStorage.
When enabled in a Direct Message (DM):
- Users exchange public keys via an initial handshake.
- A shared secret is derived using ECDH (Elliptic Curve Diffie-Hellman).
- Messages are encrypted with AES-GCM before leaving the browser.
- The server only sees and stores encrypted ciphertext strings until delivery.
Simply toggle the login box to "Register" and create a username and password.
- Click the + button next to "Chats".
- Type the exact username of the person you want to message.
- Once the chat opens, say "Hi"
- Create: Go to the Groups tab, click +, name your group, and choose "Public" or "Private".
- Join: If a group is Public, ask the creator for the 6-digit Join Code. Click "Join via Code" in the Groups tab.
- Open a Direct Message.
- Click the Lock Icon (🔒) in the top header.
- Wait for the recipient to come online and acknowledge the handshake.
- Once the alert confirms "Secure channel ready," your chats are encrypted.
You can adjust upload limits by modifying your server's php.ini or creating a .user.ini file in the same directory:
upload_max_filesize = 50M
post_max_size = 50M