# Change From headers in ActionMailer

**URL:** <https://www.ruby-forum.com/t/change-from-headers-in-actionmailer/91016>\
**Category:** Rails\
**Created:** [April 3, 2007, 9:35pm UTC](https://www.ruby-forum.com/t/change-from-headers-in-actionmailer/91016 "2007-04-03T21:35:03Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jermaine](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/9de0a6/32.png) [@Jermaine](https://www.ruby-forum.com/u/Jermaine)\
**Post date:** [April 3, 2007, 9:35pm UTC](https://www.ruby-forum.com/t/change-from-headers-in-actionmailer/91016/1 "2007-04-03T21:35:03Z")

</div>

Hi All,

Is there a way to change the “From” mail header in ActionMailer?  
Here’s how my simple ActionMailer class look like:

class Notifier \< ActionMailer::Base

def contact\_notification(person, email, message)  
recipients “removed\_email\_address@domain.invalid”  
from email  
subject “Message from [domain.com](http://domain.com)”  
body message  
end  
end

Ideally I want the output to look like this: “user\_name \<no-  
removed\_email\_address@domain.invalid\>”

Many thanks in advance !

Gr.

- Jermaine

---

<div class="post-metadata">

**Author:** ![Jermaine](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/9de0a6/32.png) [@Jermaine](https://www.ruby-forum.com/u/Jermaine)\
**Post date:** [April 4, 2007, 9:59am UTC](https://www.ruby-forum.com/t/change-from-headers-in-actionmailer/91016/2 "2007-04-04T09:59:09Z")

</div>

Jermaine wrote:

Got it working with this:

from “#{person} \<#{email}\>”

- Jermaine

> Hi All,
> 
> Is there a way to change the “From” mail header in ActionMailer?  
> Here’s how my simple ActionMailer class look like:
> 
> class Notifier \< ActionMailer::Base
> 
> def contact\_notification(person, email, message)  
> recipients “removed\_email\_address@domain.invalid”  
> from email  
> subject “Message from [domain.com](http://domain.com)”  
> body message  
> end  
> end
> 
> Ideally I want the output to look like this: “user\_name \<no-  
> removed\_email\_address@domain.invalid\>”
> 
> Many thanks in advance !
> 
> Gr.
> 
> - Jermaine
