Excel HYPERLINK Function
last modified October 5, 2026
The HYPERLINK function creates a clickable shortcut that jumps to
another location. It can open a web page, a file on a disk or network, or a
specific cell or named range in a workbook. This tutorial provides a
comprehensive guide to using the HYPERLINK function. You'll learn
the basic syntax, practical applications, and advanced techniques to master
this useful Excel function.
HYPERLINK Function Basics
The HYPERLINK function creates a shortcut that jumps to another
location when the cell is clicked. The destination can be a URL, a file path, a
UNC path on a server, or an internal reference such as a cell or named range.
The function takes two arguments.
| Component | Description |
|---|---|
| Function Name | HYPERLINK |
| Syntax | =HYPERLINK(link_location, [friendly_name]) |
| Arguments | link_location (required), friendly_name (optional) |
| Return Value | A clickable hyperlink |
This table breaks down the essential components of the HYPERLINK
function. The link_location specifies the destination, while
friendly_name provides the display text.
| Argument | Meaning |
|---|---|
| link_location | The path and file name to open, a URL, a UNC path, or an internal reference. It can be a text string in quotation marks, a cell that contains the link as text, or a formula that builds the link. |
| friendly_name | The jump text or value shown in the cell. It can be a value, a text
string, a name, or a cell that holds the text or value. If omitted, the
cell displays link_location itself. |
link_location is required; friendly_name is optional.
When only one argument is supplied, the destination text is shown as the link
label. In Excel for the web, HYPERLINK is valid for web addresses
(URLs) only.
Web Links
The most common use of HYPERLINK is a link to a website. The first
argument is the URL and the second is the text displayed in the cell.
=HYPERLINK("https://www.example.com", "Visit Example")
This formula creates a clickable link labeled "Visit Example" that opens
https://www.example.com. If friendly_name is omitted, the URL
itself becomes the link text.
=HYPERLINK("https://www.example.com")
This formula displays https://www.example.com in the cell and opens that page
when clicked. The link text is simply the value of link_location.
File and Folder Links
HYPERLINK can open files stored on your computer or on a network
share. The destination is a full path to the file, and the friendly name is the
text shown in the cell.
| A | B |
|---|---|
| Report | =HYPERLINK("C:\Reports\Q1.docx", "Open Report") |
The table shows a hyperlink that opens a Word document located at C:\Reports\Q1.docx. The link appears as "Open Report" in the cell. A local path uses a single backslash between folders, as shown above.
=HYPERLINK("C:\Reports\Q1.docx", "Open Report")
When clicked, this link opens Q1.docx in its default application. Forward slashes, such as C:/Reports/Q1.docx, are also accepted. A path to a shared network folder uses a UNC path, which begins with two backslashes: \\FINANCE\Statements\1stqtr.xlsx. A relative path resolves against the folder where the workbook is saved.
Internal Cell Links
HYPERLINK can navigate to a specific cell or range inside the
workbook. An internal reference begins with the # character,
followed by the sheet name and the cell address.
| A | B |
|---|---|
| Summary | =HYPERLINK("#Sheet2!A1", "Go to Summary") |
The table demonstrates linking to cell A1 on Sheet2. The # symbol
marks the reference as internal, so no file path or URL is needed. This
technique is useful for building a table of contents or a navigation aid.
=HYPERLINK("#Sheet2!A1", "Go to Summary")
This formula jumps to cell A1 on Sheet2 when clicked. To link to a cell on the
current sheet, use a reference such as #A1. A range works too:
#Sheet2!A1:B10. If the sheet name contains spaces, wrap it in
single quotation marks, as in #'Sales Data'!A1. Internal links
work without an internet connection and make large workbooks easier to
navigate.
Dynamic Links
HYPERLINK can be combined with other functions and operators to
build a destination at run time. This example changes the URL based on the
content of another cell.
| A | B |
|---|---|
| example | =HYPERLINK("https://www." & A1 & ".com", "Visit Site") |
The table shows how to build a URL dynamically using the value in A1. If A1 contains "example", the link becomes https://www.example.com. If A1 contains "google", the link becomes https://www.google.com. This approach enables template-based link generation.
=HYPERLINK("https://www." & A1 & ".com", "Visit Site")
This formula concatenates text with the value in A1 to create a complete URL. The ampersand (&) joins the parts. Dynamic links are useful for dashboards and reports where the destination changes with the data.
Email Links
HYPERLINK can create mailto: links that open the
user's email client with a recipient, subject, and body already filled in.
=HYPERLINK("mailto:support@example.com?subject=Help&body=Please assist", "Contact Support")
This formula creates an email link that pre-fills the recipient, subject, and message body. The link appears as "Contact Support". The question mark separates the address from the parameters, and ampersands (&) separate the parameters from one another. Spaces and other special characters may need percent-encoding for some email clients.
Formatting and Click Behavior
The text returned by friendly_name is displayed in blue and
underlined, which is the standard hyperlink look. The formatting is applied by
the function itself, so you do not need to set a cell style manually.
HYPERLINK does not check the destination when the formula is
entered. A broken URL, a missing file, or a deleted sheet name still produces a
normal-looking link; the error appears only when you click it. To avoid dead
links, test each destination or build a guard with IF and a
validation function.
friendly_name can be a number, text, or the result of another
formula. A numeric value is shown as a number. If friendly_name
returns an error value such as #VALUE!, the cell displays that
error instead of the jump text.
To select a cell that contains a hyperlink without following it in the desktop application, click and hold the mouse button until the pointer changes to a cross, then release. In Excel for the web, click the cell when the pointer is an arrow to select it, and click when it becomes a pointing hand to jump.
HYPERLINK with IF Function
Combining HYPERLINK with IF creates conditional
links. This example shows a link that appears only when a condition is met.
| A | B |
|---|---|
| 10 | =IF(A1>5, HYPERLINK("https://example.com/docs", "Documentation"), "") |
The table demonstrates a conditional link that appears only when A1's value exceeds 5. This technique prevents broken links when data is incomplete or a condition is not met.
=IF(A1>5, HYPERLINK("https://example.com/docs", "Documentation"), "")
This formula checks whether A1 is greater than 5. If true, it displays a
clickable link; if false, it shows an empty string. Nested functions expand
HYPERLINK's capabilities for dynamic workbooks.
HYPERLINK Errors and Troubleshooting
| Cause | Symptom | Fix |
|---|---|---|
| Destination does not exist | Error appears when the cell is clicked | Check the URL or path; the formula does not validate it |
| Internal link without the # prefix | Link is treated as a file or URL and fails | Start internal references with #, for example #Sheet2!A1 |
| Sheet name with spaces not quoted | #REF! or a failed jump | Wrap the sheet name in single quotes, for example #'Sales Data'!A1 |
| friendly_name returns an error | The error value is displayed in the cell | Fix the nested formula or wrap it in IFERROR |
| Path is wrong on another computer | Link works locally but not for others | Use a UNC path or a path relative to the workbook |
| Link used in Excel for the web | File links do not work | Excel for the web supports URLs only |
The HYPERLINK function transforms static spreadsheets into
interactive documents. From simple web and email links to file shortcuts and
dynamic internal navigation, HYPERLINK extends Excel's
connectivity without any macros. Remember that it does not verify its target,
so test every link and guard dynamic destinations with functions such as
IF or IFERROR before sharing the workbook.
Author
List all Excel Formulas.