Command Line Email FAQ—simple answers to complex questions.
- Q: When trying to send email, I get "relaying access denied" or similar error message.
- A: For security reasons many SMTP servers, especially outside internal networks, reject all unrecognized connections and display the relaying denied message.
Authentication is required with an SMTP server. Otherwise, one of the following error messages will be displayed
"Couldn't send message, Server Response".
- 550 Relaying is prohibited.
- 550 5.7.1 Unable to relay.
- 550 Relaying denied.
- 554 Relay access denied.
The error messages may differ among various SMTP server products. The solution is to authenticate with the mail server, using AUTH parameter.
More relaying debugging…
- Test SMTP connection and send test email
- AW Event 50461 · Command RCPT failed
- AW Event 50463 · An unexpected response after end-of-mail indicator
- AW Event 2501 · Could not send notification email
- Gmail Workspace SMTP error reference
- Microsoft Office 365 authentication issues
When SMTP authentication is required, use -AUTH AUTO command for automatic authentication. Also, a user name and a password has to be provided, using -USER and -PASS parameters · See example with Gmail authentication.
febootimail -SMTP smtp.example.net -FROM firstname.lastname@example.org -TO email@example.com -TEXT "Mail server authentication example" -AUTH AUTO -USERNAME john -PASSWORD Joh2$8n@23
This article may be referenced as (KB ID: 516).
If you have any questions, please do not hesitate to contact our support team.