Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Unanswered

Extract email address from email body in MS Flow

(1) ShareShare
ReportReport
Posted on by 6

Dear friend,

As an administrator, I frequently receive the following email message in my inbox: I need to forward the same email to the user name, whose email address was extracted from the body of the email I got. In the following example, the forwarded email address is [marjori.mabilangan@worksmartbh.com].  

Attached a copy of the email body

thank you in advance.

EM

 

  • trice602 Profile Picture
    13,773 Super User 2025 Season 1 on at
    Re: Extract email address from email body in MS Flow

    Thank you @AlexEncodian !  Good to know and will give it a go!

     

     

  • trice602 Profile Picture
    13,773 Super User 2025 Season 1 on at
    Re: Extract email address from email body in MS Flow

    Hi @AlexEncodian ,

     

    To clarify - this is absolutely 100% free with no credit card to sign-up, if a user wants to just use it for testing and development, up to 50 times/month?

     

     

  • trice602 Profile Picture
    13,773 Super User 2025 Season 1 on at
    Re: Extract email address from email body in MS Flow

    Hi @ibeldesouki ,

     

    I got this to work but you will have to run some different emails through this and see if it works for you.  If the format is highly consistent, this may help.

     

    trice602_0-1714833080505.png

     

     

    trice602_1-1714833109533.png

     

     

    Notice here, it is sent by with the space included at the end.

     

    trice602_2-1714833184619.png

     

     

    Next substring, starting position text send by output

     

    trice602_4-1714833302997.png

     

     

    Next compose.

     

    trice602_5-1714833359494.png

     

     

    Next text position from output of compose, searching to " to" with starting space.

     

    trice602_6-1714833411397.png

     

     

    Next text position from out of compose.

     

    trice602_7-1714833477015.png

     

     

    Last action, get the email.

     

    trice602_8-1714833517817.png

     

    Starting position expression:  

    add(body('Find_text_position_-_email_start'),4)
     
    Length expression: 
    sub(add(body('Find_text_position_-_email_end'),-4),body('Find_text_position_-_email_start'))
     
    Again, as I mentioned above, only you can decide if this pattern this will apply to all emails.  I have used a handful of variations of this type of flow for more than a year and if the email format is highly consistent, then this will also be highly consistent.
     
     

     

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Michael Gernaey – Community Spotlight

We are honored to recognize Michael Gernaey as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 566 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 516 Super User 2025 Season 1

#3
stampcoin Profile Picture

stampcoin 492