How to send email to multiple addresses using System.Net.Mail
Master System Design with Codemia
Enhance your system design skills with over 120 practice problems, detailed solutions, and hands-on exercises.
Introduction
To send email to multiple recipients with System.Net.Mail, add more than one address to the MailMessage.To collection before sending. The core idea is simple, but the surrounding details still matter: valid addresses, SMTP configuration, exception handling, and whether you also want Cc or Bcc.
Add Multiple Recipients to MailMessage.To
The most explicit approach is to add each recipient individually:
That is the basic pattern. Every call to To.Add appends another recipient.
Send the Message
Then configure the SMTP client and send:
If the SMTP settings are correct, the message goes to every address in To.
Add Recipients From a List
If your addresses come from configuration or user input, loop over them:
This is cleaner than hard-coding repeated To.Add calls when the recipient set is dynamic.
Cc and Bcc Work the Same Way
You are not limited to the To field. Cc and Bcc are also collections:
Use:
- '
Tofor direct recipients,' - '
Ccfor visible copied recipients,' - '
Bccfor hidden copied recipients.'
That distinction matters more than people sometimes realize, especially in bulk or compliance-sensitive mail flows.
Handle Errors Explicitly
Email sending can fail for many reasons:
- bad credentials,
- invalid addresses,
- SMTP server rejection,
- DNS issues,
- or TLS misconfiguration.
Wrap sending in exception handling:
This makes failures visible instead of silently losing mail.
Build the Message With using
Because MailMessage and SmtpClient are disposable, it is good practice to scope them cleanly:
This keeps the message-building code tidy and ensures cleanup happens even if an exception is thrown.
Validate or Normalize Recipient Input
If recipient addresses come from user input, trim and validate before adding them:
MailAddress can also be used directly when you want explicit parsing:
This is useful when display names are part of the requirement.
About SmtpClient
System.Net.Mail.SmtpClient still exists and works, which makes it fine for understanding the mechanics of multi-recipient mail in .NET. For newer or more advanced email workflows, many developers prefer newer libraries, but the address-handling model shown here is still a useful foundation.
The key point for this article is that sending to multiple recipients is about populating the address collections correctly, not about calling Send multiple times.
Common Pitfalls
The biggest pitfall is trying to concatenate several addresses into one malformed string instead of adding them properly to the recipient collection.
Another mistake is confusing To, Cc, and Bcc, especially when recipient privacy matters.
Developers also often skip exception handling and then have no idea whether the SMTP server rejected the message or the code failed before sending.
Finally, make sure the SMTP credentials, host, port, and SSL settings match the server you are using. Multi-recipient logic is irrelevant if the transport configuration is wrong.
Summary
- Add multiple recipients by calling
MailMessage.To.Addmore than once. - '
CcandBccare separate collections with different visibility semantics.' - Loop over a list of addresses when recipients are dynamic.
- Use
usingand exception handling around message creation and sending. - The hardest part is usually SMTP configuration, not adding multiple addresses.

