Search code examples
phpemailbcc

will adding bcc to php mail save resources?


I am writing an admin notification sytem for my custom CMS. So I am planning of adding a bcc to all the users of sites. So here are my questions?

  • Is bcc better than the foreach($user){mail()} function? in terms of server resource usage?
  • How many bcc's will the server support?

Thank you.


Solution

  • A direct mail to a user is usually the 'nicer' option, as it allows you to personalize it. The advantage for you is that you may get the chance to get some feedback by adding a unique id for each mail to each url that links back to your site. Using bcc is just one mail (from the view of your php server), but you shouldn't really worry about server resources here.

    Limits for bcc seem to depend on your provider. I have seen limits ranging from 5 too 500. Sending too many mails at once may also not work due php processing time limits. For many users you will have to split the sending in both cases.