
Send Email from the Command Line — No SMTP, No Sendmail, No Postfix
Every CLI email tool has the same problem: SMTP configuration. mail needs Postfix. mutt needs credentials in a dotfile. msmtp handles sending but not reading. None support OAuth2 for Gmail or Microsoft 365 out of the box. Nylas CLI bypasses all of this. Authenticate once, then send email from Linux, macOS, or Windows with one command. Works with Gmail, Outlook, Exchange, Yahoo, iCloud, and IMAP. Install # macOS / Linux brew install nylas/nylas-cli/nylas # Or shell script (macOS / Linux / WSL) curl -fsSL https://cli.nylas.com/install.sh | bash # Windows PowerShell irm https://cli.nylas.com/install.ps1 | iex Authenticate Sign up at dashboard-v3.nylas.com , create an app, connect your mailbox, grab your API key: nylas auth config # Paste your API key nylas auth whoami # => Authenticated as you@company.com (Google Workspace) Send an email nylas email send \ --to "colleague@company.com" \ --subject "Quarterly report" \ --body "Please review the Q4 numbers before Friday." # Skip confirmation
Continue reading on Dev.to Tutorial
Opens in a new tab



