Back to Top

How to change default FROM name and email address in WordPress

Generally, To change default From name and default From Email Address in notifications mail send to the users, most of the people go for the plugin but If your aim is to change simply this address, there is no need of the plugin because if you want to do this yourself, it’s quite simple without use of plugin.

Sometimes what happened you use the plugin but that plugin is not updated from 2 years so it might not work with the latest version of WordPress or you upgrade plugin and break your site. So It is better to solve such things without plugin.

By default, WordPress uses the from name WordPress and address when it sends notifications to the user which is not very meaningful because sometimes notifications are flagged as junk or spam mail. It isn’t convenient and you might want to change both of things so you can customize both these fields with below post so your users are not confused.

You also like:

To get Current URL in WordPress
To use Pagination with Taxonomy in WordPress
Share user Data in multiple WordPress Installation

This post will show you how to do this just with some simple code.In WordPress, You can also customize registration and profile page by adding requires fields.

Just Simply Go to the Appearance >> Editor menu in the WP Admin Panel, then find functions.php in the list of theme files on the right. Add these filters in your functions.php file of your theme

How To Filter the email address

To change the email address add a filter on ‘wp_mail_from’ like

How To Filter the email name

you can also change the sender’s name using the ‘wp_mail_from_name’ filter.

From now, when sends notifications, you can see the from address replaced with above name and address and seems like: Your From Name < >. To Change WordPress default email from name and address is simple and it’s useful.

Also, After doing changes, it is better to test by sending email in WordPress.Testing in WordPress is easy.If you facing any issue,Let me know in comment section. Mostly likely it will be some coding issue.

Comments (1)

Leave a Reply

Your email address will not be published. Required fields are marked *

Most Popular Posts

The Best E-Commerce Plugins for WordPress

Posted on 4 years ago


Getting Started with CodeIgniter

Posted on 6 years ago


How to create Object Copy in PHP

Posted on 6 years ago


Run-Time Validation using jQuery

Posted on 4 years ago