TLDR Solution
TLDR Answer: Use a ,
without spaces to separate e-mail addresses.
RFC6068: The 'mailto' URI Scheme (published October, 2010) is only a proposed standard, and it is not an accepted, Internet standard. It also doesn't discuss comma-separation.
TLDR Caveats/Gotchya's
- Be aware (per RFC6854) that you shouldn't comma-separate addresses in an e-mail's
Sender
field (for security reasons).
- Many services allow spaces with the
,
, so an ideal regex for splitting would be /\s*,\s*/
.
- Outlook and Exchange (and other X.400/X.500-compliant software) supports using a
;
. This is because the X.400/X.500 specification that treats semicolons as a valid name-separator (see RFC1485, published July, 1993). Going forward, using ,
is recommended.
The Source
To quote the original proposed standard, RFC2822: Internet Message Format, published April, 2001...
3.6.3. Destination address fields
The destination fields of a message consist of three possible fields,
each of the same form: The field name, which is either "To", "Cc", or
"Bcc", followed by a comma-separated list of one or more addresses
(either mailbox or group syntax).
to = "To:" address-list CRLF
cc = "Cc:" address-list CRLF
bcc = "Bcc:" [address-list / CFWS] CRLF
This proposed standard was accepted as a draft standard in October, 2008, with RFC5322: Internet Message Format. I would quote the text there, but they decided to keep it exactly as it is. An update was proposed in March, 2013, with RFC6854: Update to Internet Message Format to Allow Group Syntax...: you shouldn't be allowing comma-separated values in the Sender
field, because then it's uncertain who really triggered sending the e-mail. To quote this RFC, RFC6854...
2.1. Replacement of RFC 5322, Section 3.6.2. Originator Fields
...The from field and the sender
field SHOULD NOT use group syntax; rather, the from field SHOULD use
only the mailbox-list syntax and the sender field SHOULD use only
mailbox syntax (see RFC 6854, Section 3). If the sender field uses
group syntax, the group MUST NOT contain more than one mailbox.