function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Rajesh SriramuluRajesh Sriramulu 

can we send email from Apex class with From address as no-reply @saleforce.com?

Hi All,

can we send email from Apex class with From address as no-reply @saleforce.com without setting Organization-Wide Addresses?

If we set Organization-Wide Addresses as no-reply @saleforce.com mail means Salesforce will sends a verification link to that email id, so that cannot be verified from us.
Can anyone advice on this.

Thanks,
Rajesh
Akash Rai 1Akash Rai 1
You can set Display Name as no-reply 
Rajesh SriramuluRajesh Sriramulu
Thanks for ur reply.

set Display Name displays the User name  but I need From address(email) is  'no-reply@salesorce.com' when email sends from apex class.

Thanks,
Rajesh
Dushyant SonwarDushyant Sonwar
Hello @SRajesh8,

I don't think there is a direct way in salesforce to do that. You can use third party Transactional Email API services for integration to salesforce like mailgun (https://www.mailgun.com/)to set from email address .

Thanks,