I have a SP 2013 server farm in Azure. It has a WFE and App Server.

  • WFE is exposed, whereas App server is not.

  • We are using hMailServer instead of SMTP for sending emails.

  • We have installed hMailServer in our WFE.

When we try to send email from our application or even through PowerShell, it is going to the Spam folder in GMail. But if I install hMailServer in App server(not exposed), then emails from PowerShell are going to Inbox properly.

But I cannot do it from App Server, since my application is deployed in WFE and not in App server.

I googled a lot and read about some SPF settings in DNS. Though, I tried it, it is of no help. Also, my SMTP relayer is blank in hMailServer setting, but still, no luck.

Can anyone please help?

1 Answer 1


Mails lands into Spam because...

Every recipient server is different and may apply different spam filtering criteria for the messages being received. In most cases, recipient servers don't provide any information about spam filtering to the sender of an email that was filtered. It would give too much information to spammers who would use that data to get around spam filters.

Spam filters are constantly changing to adapt to new techniques and types of spam messages, so what lands in the inbox today could be spam filtered tomorrow. There are some things you can do to help ensure your emails are being delivered to the inbox.

Most of the major email providers, including Yahoo!, AOL, Hotmail, and Gmail, use engagement-based filtering to help detect spam. This means that the more your recipients interact with your emails by opening, clicking, and reading, the more highly engaged your audience is, and the more likely you'll end up in their inboxes. If a lot of users are marking a message as spam, it's more likely to end up in other people's spam folders. If you've moved emails out of the spam folder, that's a positive indicator and can help ensure future emails that are similar are delivered to the inbox instead.

You can refer links below:


You can also learn about Spam filters from this:


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.