Sending website email when your mailboxes are on Microsoft 365


If your mailboxes are with Microsoft 365 (including Microsoft 365 bought through GoDaddy or another provider) and your website or web app is hosted with UpTime, emails from your website such as contact forms, enquiry forms and order notifications can fail to send or be rejected as spam. This guide covers sites on our cPanel (Linux) and Plesk (Windows) hosting, including Classic ASP (CDO), ASP.NET and other custom code.

Using WordPress? See Connecting WordPress to Microsoft 365 and Setting up SMTP with WordPress instead.

Why website email fails

Receiving mail servers, such as Gmail and Microsoft 365, check that every email really comes from a server allowed to send for your domain. Two things commonly go wrong:

  • The website sends without logging in to a mailbox (for example PHP mail() or an unauthenticated script). These emails are very likely to be blocked or marked as spam.
  • The website tries to log in to Microsoft 365 with a username and password. Microsoft 365 expects apps to connect using modern authentication (OAuth or Microsoft Graph), which must be set up in your Microsoft 365 account.

Note: there is no general smtp.uptimewebhosting.com server. Always use the settings for your own mailbox, as described below.

You have two options.

Option 1 (recommended): send through a mailbox on your hosting account

This is free and simple. Your website logs in to a mailbox on your hosting account and sends through our mail server. All outgoing email from our servers is filtered by MailChannels. Your Microsoft 365 mailboxes and MX records stay exactly as they are.

Step 1: Create a sending mailbox

Create a mailbox on your hosting account to be used only by the website, for example website@yourdomain.com.au. Give it a strong, unique password.

Step 2: Point your website's code at that mailbox

Configure your form or application to send by authenticated SMTP, using the mailbox's full email address as the username, its password, and that same address as the "From" address.

  • cPanel: use the outgoing (SMTP) server details shown in Access Your cPanel Email Configuration (see also cPanel Email Set Up Information).
  • Plesk: code running on your Plesk hosting (including Classic ASP/CDO and ASP.NET) can send through the local mail server, using localhost as the SMTP server and logging in with the mailbox you created in Step 1. Use port 25 (unencrypted) or port 587 with STARTTLS, whichever suits your code. The standard settings for the mailbox are in Plesk Email Server Settings (your domain name as the server, port 465, SSL on).

Don't put a Microsoft 365 address or password in your website code for this option.

Step 3: Add MailChannels to your SPF record

Your SPF record lists the servers allowed to send email for your domain. It must include both Microsoft 365 and MailChannels. Add include:relay.mailchannels.net to your existing record, keeping everything that is already there.

For example, a typical Microsoft 365 record:

v=spf1 include:spf.protection.outlook.com -all

becomes:

v=spf1 include:spf.protection.outlook.com include:relay.mailchannels.net -all

If your Microsoft 365 was supplied by GoDaddy, your record may use include:secureserver.net instead. In that case:

v=spf1 include:secureserver.net include:relay.mailchannels.net -all

Edit the record wherever your domain's DNS is managed (for example our cPanel Zone Editor, GoDaddy or Cloudflare). A domain must have only one SPF record, so edit the existing one rather than adding a second. See also DNS records for MailChannels.

Step 4: Make sure mail for your own domain still goes to Microsoft 365

If your website sends to addresses at your own domain (for example orders@yourdomain.com.au), the hosting server must know your mail lives at Microsoft 365, otherwise it may try to deliver those emails locally.

Step 5: Test

Submit your form and send test emails to an outside address (such as a Gmail account) and to a Microsoft 365 address at your domain. Check they arrive in the inbox, not spam. How to check the health of your email deliverability explains how to check your SPF and other records. If an email is blocked with a "550 5.7.1 [CS]" error, see Fixing the 550 5.7.1 [CS] Message blocked error.

Option 2: connect your website directly to Microsoft 365

If your website must send through Microsoft 365 itself, it needs to connect using OAuth or Microsoft Graph. This is set up in your Microsoft 365 account by your Microsoft 365 administrator (usually with your web developer), for example by registering an app and creating the client ID, tenant ID and client secret your website's code or plugin needs. Follow Microsoft's or your plugin's instructions.

This work is done in your own Microsoft 365 account, so it isn't covered by our standard support. If you'd like us to do it for you, it is a paid support ticket as per our Help Desk Additional Fees page. Option 1 is the free and easy way to get your website sending.

Still not sending?

Open a helpdesk ticket with your domain name, which option you're using, the exact error message and the date and time of a failed test. Don't include passwords. We can check that our mail server is receiving and sending your website's emails; reviewing or debugging your website's code is your developer's job.


Was this answer helpful?

Still need help?

Our friendly support team are ready to offer assistance with any issues you may be encountering.
Click the button below to open a ticket:
Open Ticket

 WordPress Hosting

Fast hosting for WordPress
Experience the best in Australian WordPress hosting with lightning fast servers, built-in caching, and performance tools.

 Build Your Website

Sitejet Hosting
Build your site fast with a drag and drop editor with no coding required. 140+ quality, templates to get you started.

 Register Domains

It all starts with your domain name
Find the perfect domain and register now with our competitive pricing on all extensions.

 Web Hosting

Fast, local, secure hosting
Full featured hosting on cPanel with multiple server locations around the country.
« Back