web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / How to send hyperlinks...
Power Automate
Suggested Answer

How to send hyperlinks with custom display text from an array in Power Automate?

(0) ShareShare
ReportReport
Posted on by

I’m building a flow where:

  • I retrieve links from SharePoint (site pages library).

  • These links are stored in an array variable called 'Link', which is updated dynamically (new items are appended during the flow).

  • At the end, I want to send an email to users that includes these links.

  •  

The problem:

When I insert the array into the email body, the links appear as full URLs or as raw array format ([link1; link2; link3]).

I want each link to appear as a clickable hyperlink with custom display text (e.g., “View Page”), not the full URL.

What I tried:

Using HTML like: 

concat('<p><a href="', variables('Link'), '">View Page</a></p>')

But this only works for a single value, not for multiple links in an array.

 

Question:

How can I:

  • Iterate through the array and format each link as HTML (URLDisplay Text</a>),

  • Collect all formatted links into one email body,

  • Ensure the email renders HTML correctly?
Categories:
I have the same question (0)
  • Michael E. Gernaey Profile Picture
    53,535 Super User 2025 Season 2 on at

    Please share your flow so we can see where the issue is and fix it.
     
    Your concat is ok but I am not sure what the final view looks like that you want.. like likes in a single row, or next to each other etc.
     
    Thats the part that I want to make sure.
    Them being in an array and what you spit out is where the disconnect is and need to understand your output.
     
    As I would expect.. in a guess.. that you should create an array, and then append each of your concats to that array so you have an array of properly formatted links then put them in the HTML but again I do not know what you want the final HTML to look like so please share with a visual
  • Suggested answer
    Inogic Profile Picture
    1,135 Super User 2025 Season 2 on at
    Hi,
     
    We understand that you want to create clickable hyperlinks with custom display text and include all the formatted site links in a single email body.

    For this, you first need to create a Power Automate flow that is either Scheduled or Instant, depending on your scenario. Then, use the Get items action and provide the Site Address and List Name, as shown in the screenshot below:

    Next, initialize a variable named “Link” to store the site URLs, and another variable named “EmailBody” to store the formatted clickable links.

    Once the variables are initialized, add an “Apply to each” action and set the output to value (from “Get Site from SharePoint”). Inside this loop, use the “Append to array variable” action. Choose “Link” as the variable name, and in the Value field, enter the expression shown below to store each link in an array format.
    Expression : item()?['{Link}']


    Next, add an “Apply to each” action and set the output to the “Link” variable. Inside this loop, use the “Append to string variable” action to build the email body. Select “EmailBody” as the variable name, and in the Value field, enter the expression below to concatenate each link.
    Expression: concat('<p><a href="', items('Apply_to_each_Link_in_String'), '">View Page</a></p>')


    Then, use the “Add a new row” action to create the email record, and in the Description field, use the “EmailBody” variable, as shown in the screenshot below.


    After creating and running the flow, it will create an email record in the appropriate format, as shown in the screenshot below.


    Hope this helps.
     
    Thanks!
    Inogic

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 494 Super User 2025 Season 2

#2
abm abm Profile Picture

abm abm 226 Most Valuable Professional

#3
Tomac Profile Picture

Tomac 204 Moderator

Last 30 days Overall leaderboard