How do you change the "From" address in the WordPress email notifications?

When WordPress sends out an email notification, the "From" address is wordpress@mydomain.com. I want to change WordPress to another email address. I've searched WPMUDEV and online and have found several solutions but none seem to work with my Multisite install.

Does the email function work differently from a single site install and if so, is there still a way to change "From" address in Multisite?

I found some SMTP plugins that allow you to connect your WordPress install to an actual email server (Gmail) to send notifications. This is supposedly more reliable as php mail often gets trapped in SPAM filters. Do you think it's a good idea to use one of these plugins, and if so, this should solve the problem I'm having with the WordPress email address, correct?

Thanks for your help,
Trevor

  • Nithin

    Hi Trevor,

    Hope you are doing good today.

    I found some SMTP plugins that allow you to connect your WordPress install to an actual email server (Gmail) to send notifications. This is supposedly more reliable as php mail often gets trapped in SPAM filters. Do you think it's a good idea to use one of these plugins, and if so, this should solve the problem I'm having with the WordPress email address, correct?

    For an easy solution you could try the following solution, or the plugin mentioned in the article:
    http://www.wpbeginner.com/plugins/how-to-change-sender-name-in-outgoing-wordpress-email/

    SMTP plugin are used in case you have issues with receiving/sending, or spam issues. By default WordPress uses the PHP mail function to send emails, and there is always a possibility of email ending up in spam. You can find the following article helpful:
    https://www.jvfconsulting.com/blog/php-mail-function-vs-smtp-guaranteed-delivery/

    If you are looking to configure SMTPs you might find the following plugins helpful:
    https://wordpress.org/plugins/tags/smtp/

    Kind Regards,
    Nithin

  • Trevor

    Hi Nithin,

    Thanks for your information. I tried using the code provided in your first link before but that didn't work. Following their instructions, I did add it to my child theme's functions.php file. I also tried the plugin that they suggested but that didn't work either.

    I started thinking, both of these suggestions seemed to be specific for a single site install, not a Multisite install. Since I already had the CB Mail Sender plugin installed on the Network, I activated it on one of my sub sites, what do you know it worked!

    So it appears that since this is a Multisite install the plugin, or code in the functions.php file, would need to be activated/included on each sub site.

    Since I want this sender name and email to be changed for the main site and all sub sites, I created a plugin, added the code that would normally be put in the functions.php file, then uploaded it to my MU Plugins folder. BAM!!! now it changes the sender info on the main site as well as all of my sub sites.

    Then I got to thinking, when someone first signs up for a sub site, having website notifications coming from my name and email is ok, but what if they want to change that for their site down the road. If they should allow registration on their sub site, they will most likely want to brand the emails to them, not me. So I activated the CB Mail Sender plugin on a sub site, configured it to use a different name, and it worked perfectly replacing my sender information.

    This seems like a good solution for now. If I should run in to sending problems I may want to look in to configuring a SMTP plugin at a later date.

    Thanks again,
    Trevor