Returns a hyperlink composed of the specified URL and clickable text.
See an example of
HYPERLINK() in the Hyperlinks sample app.
HYPERLINK("https://www.google.com", "Google") returns Google
HYPERLINK("https://www.appsheet.com", "AppSheet home page") returns AppSheet home page
HYPERLINK("https://www.appsheet.com/samples/How-to-link-to-a-URL-with-custom-text?appGuidString=3f55edfc-aa53-47fc-a206-469720f10b13", "Hyperlinks sample app") returns Hyperlinks sample app
HYPERLINK([Vendor Site], [Vendor Name]) returns a hyperlink pointing to the URL in the
Vendor Site column, with clickable text from the
Vendor Name column.
Encode text for URL
Certain characters, such as ampersand (
&), colon (
:), slash (
/), and even a space, have special meanings within URLs. Text included in URLs that contains special characters should be "encoded" to remove the special meaning and avoid problems. The
ENCODEURL() function is provided for this purpose.
HYPERLINK( CONCATENATE( "https://www.google.com/search?q=", ENCODEURL([Product Name]) ), ("Search for " & [Product Name] & " on Google") )
HYPERLINK(..., ...)creates a hyperlink to the given target URL and with the given clickable text.
CONCATENATE(..., ...)computes the target URL by combining the given values.
"https://www.google.com/search?q=": the initial part of the target URL. This part is already properly encoded as a URL, so
ENCODEURL()is not needed.
ENCODEURL([Product Name])encodes the
Product Namecolumn value, ensuring the special meaning is removed from any special characters the value may contain.
("Search for " & [Product Name] & " on Google")assembles the clickable text for the hyperlink from the given components.
ENCODEURL()is not needed here because the clickable text is not part of the URL. Equivalent to
CONCATENATE("Search for ", [Product Name], " on Google").
url- Any textual type. Specifies the URL to which the user is to be sent upon clicking the link. No processing of the URL is done in constructing the hyperlink; the URL should be complete and valid.
text-Any textual type. Specifies the text the user will see and click on.