Send & Receive Issues

Troubleshoot Classic ASP Email Sending Through Office 365 SMTP

John WilsonJohn Wilson Nov 22, 2026 868 views

Question details

Determine why a Classic ASP application cannot send email through Office 365 SMTP after working with an internal Exchange server.

Troubleshoot Classic ASP Email Sending Through Office 365 SMTP
Product
Exchange Online SMTP client submission and Classic ASP CDO
Device & OS
not provided
Scenario
The developer is migrating mail sending from an internal Exchange server to hosted Exchange and wants to retire the internal server.
Observed behavior
Email sending fails through Office 365 on ports 25 and 587 despite valid credentials and an SSL setting.
Before you start

Collect the exact CDO error message and confirm the sending mailbox and SMTP server settings without sharing passwords. Run connectivity checks from the server hosting the ASP application, not just from a separate workstation.

Solution 1Recommended

Check Exchange Online SMTP Submission and CDO Settings

Use these checks to isolate connectivity, authentication, TLS, or CDO configuration issues.

1
Test network access

On the ASP host, run `Test-NetConnection smtp.office365.com -Port 587` in PowerShell. If the TCP test fails, check outbound firewall and network rules; a successful test does not verify TLS or authentication.

2
Verify the CDO configuration

In the ASP code, inspect the CDO configuration fields: use `smtp.office365.com` as `smtpserver`, `587` as `smtpserverport`, authenticated submission via `smtpauthenticate`, and `smtpusessl` set to true. Confirm the mailbox credentials and avoid writing them to logs.

3
Check SMTP authentication

In the Microsoft 365 admin center, open the sending user and check Mail > Manage email apps for Authenticated SMTP. Also check organization-wide SMTP AUTH and authentication policies in the Exchange admin center or Exchange Online PowerShell; a mailbox setting alone may not override a blocking policy.

4
Check TLS and authentication support

Confirm that the host can negotiate TLS 1.2 or later using STARTTLS on port 587. Review the current Exchange Online SMTP AUTH requirements and compare them with the authentication and TLS capabilities of the CDO implementation.

5
Inspect the failure

Capture the CDO error number and description at the `.Send` call, then compare it with server, TLS, or authentication logs. Use the result to identify whether the failure occurs during connection, TLS negotiation, sign-in, or message submission.

Check Exchange Online SMTP Submission and CDO Settings
CDO compatibility: A successful TCP connection does not prove that CDO can negotiate the required TLS and authentication. Exchange Online security policies or current authentication requirements may prevent a legacy username-and-password implementation from working.
Free Microsoft Office alternative

Work With Office Email Attachments in WPS Office

WPS Office is a free, lightweight alternative for working with documents, spreadsheets, and presentations. Its familiar interface and Microsoft Office format compatibility make it easy to move existing files into your workflow. It does not fix Exchange Online SMTP or Classic ASP sending issues.

Open and edit common document attachments received by emailWork with Microsoft Office formats including DOCX, XLSX, and PPTXUse a familiar interface that makes migration from Office easierAccess free, lightweight tools for everyday office files
microsoft office alternative - wps office

Frequently Asked Questions

Which server and port should Classic ASP use for Exchange Online SMTP submission?

Use `smtp.office365.com` on port 587 with authenticated SMTP submission and STARTTLS. Confirm that the CDO implementation and host support the required TLS and authentication.

Does a successful PowerShell connection test mean the mailbox credentials work?

No. `Test-NetConnection smtp.office365.com -Port 587` checks TCP connectivity, not TLS negotiation or mailbox authentication. Test those separately from the application host.

Where can I check whether SMTP AUTH is enabled for the mailbox?

In the Microsoft 365 admin center, open the user and check Mail > Manage email apps for Authenticated SMTP. Also review organization-wide settings and authentication policies, which can affect access.

Why can CDO fail even when the SMTP server is reachable?

CDO or its host may not support the required TLS or authentication method, or an Exchange Online policy may block the sign-in. Inspect the error returned at `.Send` and check the relevant authentication and TLS logs.

What can I use if Classic ASP CDO cannot authenticate?

Consider a supported mail-sending component that uses OAuth with Exchange Online, or call Microsoft Graph's `sendMail` endpoint through an appropriately authorized application. A suitable external mail service or relay may also be an option.