Installation Guide
MailOS can be installed through multiple methods depending on your platform and preferences.
Quick Install
YOLO Install (Cross-platform)
# Unix-like systems (macOS, Linux, WSL)
curl -fsSL https://email-os.com/install | bash
# Windows PowerShell (Recommended for Windows)
iwr -useb https://email-os.com/install.ps1 | iexPackage Managers
npm (All Platforms)
npm install -g mailosThe npm package automatically downloads the correct binary for your platform (macOS, Linux, Windows) and architecture (x64, ARM64).
Windows Package Managers
# Scoop (Recommended for Windows)
scoop bucket add extras
scoop install extras/mailos
# Chocolatey
choco install mailos
# WinGet (Windows Package Manager)
winget install EmailOS.MailOSUnix Package Managers
# Homebrew (macOS/Linux)
brew tap anduimagui/mailos
brew install mailos
# Arch Linux
paru -S mailos-binPlatform-Specific Installation
macOS
Apple Silicon (M1/M2/M3/M4)
curl -L https://github.com/anduimagui/emailos-cli/releases/latest/download/mailos-darwin-arm64.tar.gz | tar xz
sudo mv mailos /usr/local/bin/Intel Macs
curl -L https://github.com/anduimagui/emailos-cli/releases/latest/download/mailos-darwin-amd64.tar.gz | tar xz
sudo mv mailos /usr/local/bin/Linux
x64/AMD64
curl -L https://github.com/anduimagui/emailos-cli/releases/latest/download/mailos-linux-amd64.tar.gz | tar xz
sudo mv mailos /usr/local/bin/ARM64
curl -L https://github.com/anduimagui/emailos-cli/releases/latest/download/mailos-linux-arm64.tar.gz | tar xz
sudo mv mailos /usr/local/bin/Windows
Using PowerShell
# Download the binary
Invoke-WebRequest -Uri "https://github.com/anduimagui/emailos-cli/releases/latest/download/mailos-windows-amd64.tar.gz" -OutFile "mailos.tar.gz"
# Extract (requires tar in Windows 10+)
tar -xzf mailos.tar.gz
# Move to a directory in your PATH
Move-Item mailos.exe "C:\Program Files\mailos\mailos.exe"
# Add to PATH if needed
[Environment]::SetEnvironmentVariable("Path", $env:Path + ";C:\Program Files\mailos", [EnvironmentVariableTarget]::User)Using WSL
# Install the Linux version in WSL
curl -L https://github.com/anduimagui/emailos-cli/releases/latest/download/mailos-linux-amd64.tar.gz | tar xz
sudo mv mailos /usr/local/bin/Build from Source
Prerequisites
- Go 1.24 or higher
- Git
Build Steps
# Clone the repository
git clone https://github.com/anduimagui/emailos-cli.git
cd emailos-cli
# Build the binary
go build -ldflags="-s -w" -o mailos ./cmd/mailos
# Install globally (Unix-like systems)
sudo mv mailos /usr/local/bin/
# Or add to PATH on Windows
# Move mailos.exe to a directory in your PATHVerify Installation
After installation, verify MailOS is working:
# Check version
mailos --versionNext Steps
After successful installation, proceed to:
- Setup Guide - Configure your email account with app passwords
- Documentation Index - Learn how to use MailOS commands {/* TODO: broken link removed — target page
ai-integration.mddoes not exist in this repo. Restore once an AI Integration doc is added. */}
Quick Start: Run mailos setup to begin configuration with the interactive setup wizard.
Email Scheduling Features
MailOS supports advanced email scheduling when msmtp-queue is installed:
Available Scheduling Options
# Schedule email for specific time
mailos send --to [email protected] --subject "Meeting" --schedule-at "2024-01-01T15:04:05Z"
# Schedule email after a duration
mailos send --to [email protected] --subject "Reminder" --schedule-in "30m"
# Natural language with scheduling
mailos send "thank [email protected] for the meeting" --schedule-in "2h"
# List scheduled emails
mailos send --schedule-list
# Manage scheduled emails
mailos send --schedule-cancelInstalling msmtp-queue Manually
If the automatic installation didn't install msmtp-queue, you can install it manually:
macOS (Homebrew)
# Check if available in Homebrew
brew search msmtp-queue
# Install from source if not available
curl -O https://raw.githubusercontent.com/marlam/msmtp-scripts/master/msmtp-queue/msmtp-queue
chmod +x msmtp-queue
sudo mv msmtp-queue /usr/local/bin/Linux
# Download msmtp-queue scripts
curl -O https://raw.githubusercontent.com/marlam/msmtp-scripts/master/msmtp-queue/msmtp-queue
curl -O https://raw.githubusercontent.com/marlam/msmtp-scripts/master/msmtp-queue/msmtp-runqueue.sh
curl -O https://raw.githubusercontent.com/marlam/msmtp-scripts/master/msmtp-queue/msmtp-listqueue.sh
# Make executable and install
chmod +x msmtp-queue msmtp-runqueue.sh msmtp-listqueue.sh
sudo mv msmtp-queue msmtp-runqueue.sh msmtp-listqueue.sh /usr/local/bin/Verify Installation
# Check if msmtp-queue is available
msmtp-queue --help
mailos send --schedule-listUpdating MailOS
Using npm
npm update -g mailosUsing Direct Download
Re-run the installation commands above to get the latest version.
Check Current Version
mailos --versionComplete Uninstallation
⚠️ Important: Standard uninstallation methods only remove the EmailOS binary, but leave your configuration and email data intact in the ~/.email directory.
Quick Complete Uninstallation (Recommended)
Use EmailOS's built-in uninstall command for complete removal:
# Complete uninstallation with backup
mailos uninstall --backup
# Force uninstallation without prompts
mailos uninstall --force
# See what would be removed (dry run)
mailos uninstall --dry-run
# Keep emails but remove configuration
mailos uninstall --keep-emails
# Keep configuration but remove emails
mailos uninstall --keep-configPackage Manager Uninstallation
npm
npm uninstall -g mailos📝 Note: The npm uninstall script will detect your EmailOS data and offer to remove it interactively.
Homebrew
brew uninstall mailos⚠️ Important: After Homebrew uninstallation, run mailos cleanup to remove remaining data.
Manual Binary Removal
# Unix-like systems
sudo rm /usr/local/bin/mailos
# Windows
# Remove mailos.exe from wherever you installed it⚠️ Important: After manual removal, your data remains in ~/.email. See cleanup instructions below.
Cleaning Up After Package Manager Uninstallation
If you uninstalled EmailOS using a package manager but want to remove all data:
Automatic Cleanup (Recommended)
# If mailos command is still available
mailos cleanup
# If you get "command not found", manually download and run:
curl -L https://github.com/anduimagui/emailos-cli/releases/latest/download/mailos-$(uname -s | tr '[:upper:]' '[:lower:]')-$(uname -m).tar.gz | tar xz
./mailos cleanup
rm ./mailosManual Cleanup
# ⚠️ This will permanently delete all EmailOS data!
# Create backup first (optional):
cp -r ~/.email ~/Downloads/emailos-backup-$(date +%Y%m%d)
# Remove EmailOS data directory
rm -rf ~/.email
# Remove any local project configurations
find ~/projects -name ".email" -type d -exec rm -rf {} + 2>/dev/nullWhat Gets Removed
When performing complete uninstallation, the following are removed:
📁 Configuration Files:
~/.email/config.json- Account settings and credentials~/.email/.license- License information
📧 Email Data:
~/.email/sent/- All sent email copies~/.email/received/- All synced received emails~/.email/drafts/- All draft emails
🗂️ Local Project Configs:
.email/directories in project folders (if any)
🔧 System Integration:
EMAILOS.mdfiles in project directories
Data Recovery
If you uninstalled EmailOS but want to recover your data:
# Check if data still exists
ls -la ~/.email
# If data exists, reinstall EmailOS to access it
npm install -g mailos
# Or manually backup the data
cp -r ~/.email ~/emailos-backup-$(date +%Y%m%d)Verification
To verify complete removal:
# Check for remaining files
ls -la ~/.email 2>/dev/null || echo "✓ No EmailOS data found"
# Check for remaining binary
which mailos 2>/dev/null || echo "✓ No EmailOS binary found"
# Check for local configs (optional)
find ~ -name ".email" -type d 2>/dev/nullTroubleshooting Uninstallation
"Permission Denied" Errors
# If you get permission errors removing ~/.email
sudo rm -rf ~/.email
# If you get permission errors removing the binary
sudo rm $(which mailos)Partial Uninstallation Recovery
If uninstallation was interrupted:
# Reinstall EmailOS temporarily
npm install -g mailos
# Complete the uninstallation
mailos uninstall --force
# Remove the binary again
npm uninstall -g mailosOrphaned Data Detection
EmailOS automatically detects orphaned data and will show hints when you run other commands. To manually check:
# If EmailOS is installed
mailos cleanup
# If EmailOS is not installed but you suspect data remains
ls -la ~/.emailSystem Requirements
Minimum Requirements
- Operating System: macOS 10.15+, Linux (glibc 2.17+), Windows 10+
- Memory: 512MB RAM
- Storage: 50MB free space
- Network: Internet connection for email operations
Required Dependencies
MailOS requires the following dependencies for full functionality:
Core Dependencies (Required)
- isync (mbsync): For email synchronization
- msmtp: For email sending
- curl or wget: For downloading updates
Optional Dependencies
- msmtp-queue: For email scheduling features (highly recommended)
The installation script automatically installs these dependencies on supported platforms.
Supported Email Providers
- Gmail
- Fastmail
- Zoho Mail
- Outlook/Hotmail
- Yahoo Mail
- iCloud Mail (@icloud.com, @me.com, @mac.com)
- ProtonMail (SMTP sending only, requires SMTP token or Bridge)
- Any IMAP/SMTP compatible provider
Note: See the Setup Guide for provider-specific app password instructions.
Troubleshooting
Permission Denied (Unix-like systems)
If you get a permission error when moving to /usr/local/bin/:
# Create the directory if it doesn't exist
sudo mkdir -p /usr/local/bin
# Move with sudo
sudo mv mailos /usr/local/bin/
# Make executable
sudo chmod +x /usr/local/bin/mailosCommand Not Found
If mailos is not found after installation:
Check if it's in PATH:
bashecho $PATH which mailosAdd to PATH (bash/zsh):
bashecho 'export PATH="/usr/local/bin:$PATH"' >> ~/.bashrc source ~/.bashrcFor Windows, ensure the installation directory is in your PATH environment variable.
npm Installation Issues
The npm package automatically installs the correct binary for your platform during the postinstall phase.
If npm installation fails:
Update npm and Node.js:
bashnpm install -g npm@latest # Ensure Node.js 14.0.0 or higher is installed node --versionClear npm cache:
bashnpm cache clean --forceUse sudo (Unix-like systems):
bashsudo npm install -g mailosCheck npm prefix:
bashnpm config get prefixPlatform-specific binary not found: If the postinstall script fails to find a binary for your platform:
bash# Check your platform details node -e "console.log(process.platform, process.arch)" # Supported platforms: darwin-x64, darwin-arm64, linux-x64, linux-arm64, win32-x64Manual binary installation: If npm installation continues to fail, use the direct download method above.
License Key Issues
If you encounter license validation errors:
- Ensure you have an active internet connection
- Check if your license key is valid
- Visit https://email-os.com/checkout to purchase or renew
- Run
mailos setupto re-enter your license key
Getting Help
- Documentation: https://github.com/anduimagui/emailos-cli/tree/main/docs
- Issues: https://github.com/anduimagui/emailos-cli/issues
- Website: https://email-os.com
Next Steps
After installation, proceed to:
- Setup Guide - Configure your email account with app passwords
- Documentation Index - Learn how to use MailOS {/* TODO: broken link removed — target page
ai-integration.mddoes not exist in this repo. Restore once an AI Integration doc is added. */}
Quick Start: Run mailos setup to begin configuration with the interactive setup wizard.
