HYPERLINK function
HYPERLINK creates a clickable link from a formula and shows a friendly name or the link itself. It lets you build links dynamically, for example from an ID column.
Example
Read it as a sentence: make a clickable link to cell B1 on the Items sheet that displays the text 5.
Excel shows 5
B
1
Item
Items
Syntax
HYPERLINK(link_location, [friendly_name])
Arguments in [square brackets] are optional.
-
link_location(required) - URL, file path or in-workbook location (like "#Sheet2!A1").
-
friendly_name(optional) - Text to display; defaults to the link itself.
Returns: The friendly name (or link) as a clickable link.
What Excel actually returns
Each formula below was run in desktop Excel. The result is exactly what the cell showed, errors included.
| Formula | Excel shows | Case |
|---|---|---|
=HYPERLINK("https://example.com","site") | site | Friendly name |
=HYPERLINK("https://example.com") | https://example.com | No friendly name |
=HYPERLINK("#Items!B1",5) | 5 | Number as friendly name |
=HYPERLINK("x",Data!F1) | 0 | Blank friendly name |
=HYPERLINK(Data!F5) | #DIV/0! | Error as link |
The Items sheet these formulas read
B
1
Item
Items
The Data sheet these formulas read
A cell that starts with = holds that formula.
F
1
2
'123
3
2024-02-29
4
TRUE
5
=1/0
Data
Watch out for
- Excel may show a security prompt when clicking file links.
- URLs over about 255 characters can fail.
Where it works
- Excel
- HYPERLINK is in every version of Excel from 2007 on.
- Google Sheets
- Same name, same behaviour for everyday use.
Part of Lookup and reference functions. Every result on this page was measured in desktop Excel, build 16.0.20527. Last updated .