Skip to main content

๐Ÿ’ป Whinself on Windows (WLS) Docker

This guide shows you how to install and run Whinself in a Docker container on a Windows 10/11 machine using the Windows Docker Desktop client with WSL2 integration. Whinself provides a low-cost, low-power WhatsApp API server in a convenient container.


Prerequisitesโ€‹

Before you begin, make sure you have:

  • A Windows 10 (2004+) or Windows 11 PC
  • WSL2 enabled with a Linux distro installed (weโ€™ll use Ubuntu)
  • Docker Desktop for Windows installed and configured for WSL2
  • Basic familiarity with Windows PowerShell or Command Prompt
  • A WhatsApp account

Step 1: Install & Configure WSL2 (Skip if Already Done)โ€‹

  1. Enable the Windows Subsystem for Linux and Virtual Machine Platform features
    Open PowerShell as Administrator and run:
    dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
    dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
  2. Set WSL2 as the default version
    wsl --set-default-version 2
  3. Install Ubuntu from the Microsoft Store
    • Search โ€œUbuntuโ€ and install the latest LTS.
    • Launch Ubuntu, create your UNIX username/password.

Step 2: Install Docker Desktop & Enable WSL2 Integrationโ€‹

  1. Download Docker Desktop for Windows from https://www.docker.com/get-started
  2. Run the installer, accept defaults, and reboot if prompted.
  3. Open Docker Desktop, go to Settings โ†’ Resources โ†’ WSL Integration, and enable integration for your Ubuntu distro.
  4. Verify in WSL:
    docker --version
    You should see something like Docker version XX.XX.X, build XXXXXXX.

Step 3: Create the Whinself Configuration Fileโ€‹

  1. Open your Ubuntu WSL shell and make a working directory:
    mkdir -p ~/whinself && cd ~/whinself
  2. Create config.json:
    nano config.json
  3. Paste your configuration (edit values as needed):
    {
    "slotid": "my-whatsapp-bot",
    "nrurl": "https://your-webhook-endpoint.com/api/messages",
    "portin": 9001,
    "devicename": "Windows WhatsApp Bot",
    "debuglevel": 0,
    "logstdout": true,
    "logsse": true
    }
    • Replace your webhook URL accordingly.
    • Adjust the port if needed.
  4. Save and exit: Ctrl+O, Enter, then Ctrl+X.

Step 4: Run the Whinself Docker Containerโ€‹

From your Ubuntu WSL shell, run:

docker run -d   --name whatsapp-bot   --restart unless-stopped   -p 9001:9001   -v "$(pwd)/config.json:/app/config/config.json"   inutil/whingo:latest

This will:

  • Pull inutil/whingo:latest (multi-arch for x86/ARM)
  • Map host port 9001 โ†’ container port 9001
  • Mount your config.json into the container
  • Auto-restart unless manually stopped
    Verify itโ€™s running:
docker ps

Step 5: Access the Whinself Dashboardโ€‹

  1. Find your Windows hostโ€™s IP from WSL:
    grep nameserver /etc/resolv.conf | awk '{print $2}'
  2. Open a browser in Windows and navigate to:
    http://<WSL_IP>:9001
    Replace <WSL_IP> with the address you retrieved.
  3. Sign Up with your email and password, verify via the link, then log in.

Step 6: Connect WhatsAppโ€‹

  1. Click Subscribe on the dashboard (start free trial if required).
  2. A QR code appearsโ€”on your phone open WhatsApp โ†’ Settings โ†’ Linked Devices โ†’ Link a Device and scan.
  3. Wait for completion. To switch accounts, disconnect first.

Step 7: Test Sending a Messageโ€‹

From WSL or Windows PowerShell, run:

curl -X POST http://localhost:9001/wspout   -H "Content-Type: application/json"   -d '{
"text": "Hello from my Windows Whinself server!",
"jid": "[email protected]"
}'

Replace the jid with the actual number (including country code).


Step 8: Set Up Permanent Access (Optional)โ€‹

Windows Firewallโ€‹

Allow port 9001 through Windows Defender Firewall:

  1. Open Windows Security โ†’ Firewall & network protection โ†’ Advanced settings.
  2. Create a new Inbound Rule for TCP port 9001.

Reverse Proxy with SSL (WSL)โ€‹

  1. Install Nginx & Certbot:
    sudo apt update
    sudo apt install -y nginx certbot python3-certbot-nginx
  2. Configure /etc/nginx/sites-available/whinself:
    server {
    listen 80;
    server_name your-domain.com;

    location / {
    proxy_pass http://localhost:9001;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection 'upgrade';
    proxy_set_header Host $host;
    proxy_cache_bypass $http_upgrade;
    }
    }
  3. Enable & obtain SSL:
    sudo ln -s /etc/nginx/sites-available/whinself /etc/nginx/sites-enabled/
    sudo certbot --nginx -d your-domain.com
    sudo systemctl reload nginx

Troubleshootingโ€‹

  • Container isnโ€™t running:
    docker logs whatsapp-bot
  • Cannot reach dashboard:
    • Verify WSL IP: hostname -I or grep nameserver /etc/resolv.conf.
    • Check Docker mapping: docker ps.
  • QR code fails:
    • Test connectivity: ping google.com.
    • Restart container:
      docker restart whatsapp-bot

Maintenanceโ€‹

Update Whinselfโ€‹

docker pull inutil/whingo:latest
docker stop whatsapp-bot && docker rm whatsapp-bot
docker run -d --name whatsapp-bot --restart unless-stopped -p 9001:9001 -v "$(pwd)/config.json:/app/config/config.json" inutil/whingo:latest

View Logsโ€‹

docker logs -f whatsapp-bot

Conclusionโ€‹

You now have Whinself running under Windows with Docker Desktop and WSL2. Integrate it into your automation, chatbots, or any system to leverage WhatsApp messaging. Use Dockerโ€™s restart policies and Windows Firewall rules to keep your service reliable and secure.

Disclaimer: Whinself is an unofficial third-party WhatsApp API server. It is not affiliated with WhatsApp Inc. or Meta. Use responsibly under WhatsAppโ€™s Terms of Service.