Function Problems

How to Create an Excel Hyperlink from a Filename in Another Cell

Steven ParkerSteven Parker Nov 4, 2026 871 views

Question details

The user wants to generate a clickable hyperlink in Excel that points to an external file (like a PDF) by combining a static network folder path with a dynamic filename located in a different cell.

How to Create an Excel Hyperlink from a Filename in Another Cell
Product
Excel
Device & OS
not provided
Scenario
Organizing files or linking to network documents where filenames are listed in an Excel column, and the user needs to create quick access links to those files.
Observed behavior
The user needs to construct a dynamic hyperlink formula instead of manually typing the full path for every single file.
Before you start

Ensure you have the exact network or local folder path where your files are stored, and verify the correct file extension (such as .pdf, .docx, or .xlsx) for the files you are linking to.

Solution 1Recommended

Use the HYPERLINK Function with Concatenation

Dynamically create a clickable link by combining the base folder path, the cell reference containing the filename, and the file extension.

The HYPERLINK function in Excel allows you to create clickable links. By using the ampersand (&) operator, you can stitch together a static file path, a dynamic filename from a cell, and the file extension.

1
Select the destination cell

Click on the cell where you want the clickable hyperlink to appear.

2
Start the formula

Type the formula starting with =HYPERLINK(

3
Enter the folder path

Enter your base folder path enclosed in quotation marks, making sure to include the final backslash. For example: "\\SERVER\SHARE\subfolder\"

4
Concatenate the cell reference and extension

Add an ampersand (&), select the cell containing your filename (e.g., C12), add another ampersand (&), and append the file extension in quotation marks (e.g., ".pdf"). The syntax so far is: "\\SERVER\SHARE\subfolder\"&C12&".pdf"

5
Add a friendly name and complete

Add a comma followed by a friendly display name in quotation marks (optional). Close the parentheses and press Enter. The final formula should look like: =HYPERLINK("\\SERVER\SHARE\subfolder\"&C12&".pdf", "Open Document")

Use the HYPERLINK Function with Concatenation
Path syntax warning: Make sure your folder path ends with a backslash (\) inside the quotation marks so the filename attaches correctly. If omitted, the link will fail to find the file.
Data Management

Create Dynamic Hyperlinks Easily in WPS Spreadsheet

WPS Office provides a powerful Spreadsheet application that fully supports advanced formulas, including HYPERLINK and text concatenation. You can effortlessly manage your file directories and create clickable links seamlessly.

  1. 1. Open your workbook: Launch WPS Spreadsheet and open the document containing your list of filenames.
  2. 2. Select the target cell: Click on the specific cell where the generated hyperlink should be displayed.
  3. 3. Input the HYPERLINK formula: Enter the formula combining the path and cell reference, such as =HYPERLINK("C:\files\"&A2&".pdf", "View File").
  4. 4. Apply and test: Press Enter to create the link. Click the newly created text to ensure it opens the correct file successfully.
Fully compatible with Microsoft Excel (.xlsx) formulas and file formats.Seamlessly handles text concatenation and dynamic cell referencing.Lightweight, intuitive interface for fast and effective data management.
microsoft office alternative - wps office

Frequently Asked Questions

Why is my Excel hyperlink showing a 'Cannot open the specified file' error?

This usually happens if the constructed file path is incorrect. Check if you missed the trailing backslash (\) in your folder path, verify the cell reference contains the exact filename without typos, and ensure the file extension matches the actual file.

Can I display custom text instead of the long file path for the link?

Yes, the HYPERLINK function takes a second optional argument called 'friendly_name'. You can add it after a comma like this: =HYPERLINK("C:\folder\"&A1&".pdf", "Click here to open").

Does the HYPERLINK function work with local drives as well as network folders?

Absolutely. You can use a local path like "C:\Users\Desktop\Files\" or a network path like "\\SERVER\SHARE\". Just ensure the path format matches your operating system's directory structure.

How do I link to a specific sheet in another Excel workbook using a dynamic filename?

To link to a specific location in another workbook, you must append the sheet name and cell reference to the file path using the hash symbol (#), for example: =HYPERLINK("[C:\folder\"&A1&".xlsx]Sheet1!A1", "Open Sheet").