A modern, secure, and blazing-fast local network messenger built with Python.
Crafted with passion by MRThugh.
DarkLine Messenger is a fully-featured, decentralized LAN (Local Area Network) chat application. Designed with a sleek, modern, dark-themed UI using customtkinter, it allows users on the same network to host servers, connect as clients, create private chat rooms, share media, and communicate securely using real-time AES encryption.
Whether you're looking for a private communication tool for your office/home network or an excellent example of Python socket programming and GUI design, DarkLine is built to impress.
- 🛡️ End-to-End Encryption: All messages and images are encrypted locally before transmission using AES (Advanced Encryption Standard via
cryptography.fernet). - 🎨 Modern Dark UI: Beautiful, responsive, and intuitive graphical interface powered by
CustomTkinterwith a custom "blue" color theme. - 🏠 Dynamic Chat Rooms: Create custom chat channels on the fly. You can even lock rooms with passwords for private group conversations!
- 🖼️ Media Sharing & Profiles:
- Set custom Profile Pictures (resized automatically and transmitted via Base64).
- Send, receive, and download image messages directly within the chat.
- 🖥️ Built-in Server Hosting: No third-party servers required. Host a server directly from the client with one click.
- 📡 Smart Networking: Auto-detects your local IP address and displays real-time connection status and active user counts.
- 🕒 Live Dashboard: Integrated real-time clock, date display, and system event logging (connection drops, new rooms, etc.).
| Login & Server Setup | Chat Room & Image Sharing | Private Rooms |
|---|---|---|
![]() |
![]() |
![]() |
You need Python 3.8 or higher installed on your machine. You will also need to install the required dependencies.
-
Clone the repository:
git clone https://github.com/MRThugh/DarkLine-Messenger.git cd DarkLine-Messenger -
Install required packages:
pip install customtkinter Pillow cryptography
-
Run the application:
python main.py
- Launch the app.
- Enter your desired Username and click
📷 Set Profile Picture(optional). - The app will show your Local IP on the sidebar.
- Enter a Port (default
5555) and click 🖥️ Host Server. - You are now hosting the chat! Tell your friends your Local IP and Port.
- Launch the app on another computer on the same network.
- Enter your Username and set a Profile Picture.
- Under Connection, enter the Host IP (the IP of the person hosting) and the Port.
- Click 🔗 Connect.
- Start chatting in the "General" room, or create your own locked rooms!
- Networking: Pure Python
socketlibrary utilizing TCP streams (SOCK_STREAM). - Concurrency: Utilizes Python
threadingto keep the UI responsive while simultaneously listening for incoming network packets. - Data Serialization: Payloads (text, timestamps, Base64 images) are packaged into
JSONformats before transmission. - Security:
Fernetsymmetric encryption ensures that any packet intercepted on the network is completely unreadable without the secret key.
- Add Emojis / Sticker support.
- Implement file sharing (PDFs, ZIPs).
- Add a global configuration file (
config.json) for custom encryption keys. - Notification sounds for new messages.
Contributions, issues, and feature requests are welcome! Feel free to check the issues page.


