Onenote, Links to Files on PC. How can I find all the links I have created to files on my PC?

Bronwyn 0 Reputation points
2026-10-13T06:01:16.6133333+00:00

In my many Onenote books I have many links to files on my PC.

I need to move my Microsoft account and thus all these link will no longer work. I want to create a list of these links, so that I can reinstall them once I have moved.

Microsoft 365 and Office | OneNote | For business | Windows
0 comments No comments

2 answers

Sort by: Most helpful
  1. Darren Bruce 2,015 Reputation points Independent Advisor
    2026-10-13T06:24:23.3233333+00:00

    Dear Bronwyn,

    As far as I'm aware, OneNote does not provide a built-in feature to generate a consolidated list of all local file links (file:///) across multiple notebooks.

    For better understanding your situation, ould you clarify whether your OneNote notebooks are associated with a personal Microsoft account (such as Outlook.com/Hotmail.com) or a Microsoft 365 business/work account?

    The available migration and export options can differ depending on where the notebooks are stored. For notebooks associated with a personal Microsoft account, you may find the guidance in Export and Import OneNote notebooks helpful. It describes the supported export process for notebooks stored in personal OneDrive.

    For reference Export OneNote notebooks

    If you're using a Microsoft 365 business account and the notebooks are stored in OneDrive for Business or SharePoint, notebook export through OneNote for the web is not supported. In that scenario, you can open the notebook in the desktop version of OneNote and export the required sections or pages (for example, to PDF, Word, or OneNote package formats where available) for review before the migration.

    I hope information above meet your expectations.


    Note: Please follow the steps in the forum documentation to enable e-mail notifications if you want to receive the related email notification for this thread. 

    Was this answer helpful?

    0 comments No comments

  2. AI answer

    2026-10-13T06:03:06.07+00:00

    OneNote does not provide a documented built-in report of every file hyperlink, so first search all open notebooks for the old path prefix and manually record each matching link before changing accounts.

    Search all notebooks

    In the Microsoft 365 desktop version of OneNote for Windows:

    1. Open every notebook that may contain file links:
      • Select File > Open.
      • Reopen notebooks listed under Recent Notebooks.
    2. Unlock any password-protected sections; protected sections are excluded from OneNote searches.
    3. Press Ctrl+E to set the search scope to All Notebooks.
    4. Search separately for each likely path prefix, for example:
      • C:\Users\OldName\
      • D:\
      • A distinctive folder name such as ProjectFiles
      • A server or share name used in network paths
    5. Open every result and right-click the linked text or object, then select Edit Link to view the complete Address.
    6. Record the notebook, section, page, displayed text, and address in Excel or a CSV file.

    OneNote documents all-notebook text searching and notes that closed notebooks must be reopened to participate in searches.^1^

    This is a best-effort method, not a guaranteed inventory: Microsoft documents searching typed text, handwriting, images, and similar indexed content, but the supplied documentation does not establish that a hyperlink’s hidden address is always searchable. If the visible text says “Open report” rather than showing its file path, a path search might not find it.

    Changing the Microsoft account that stores the notebooks does not by itself establish that links to PC files will break. The relevant issue is whether the destination path changes—for example, a different Windows profile folder, drive letter, folder structure, or network share.

    Before moving:

    1. Note the current destination paths.
    2. On the new setup, reproduce the same drive letters and folder paths where practical.
    3. Test representative links containing:
      • Spaces in folder names
      • file:/// addresses
      • Direct drive paths such as C:\Folder\File.docx
      • UNC paths such as \\server\share\File.docx

    If the paths remain identical, those links may not need to be recreated.

    For a complete automated inventory

    The desktop OneNote application interface can enumerate all notebooks and pages with GetHierarchy, and GetPageContent can retrieve each page’s content as OneNote XML.^2^ The hsPages hierarchy scope has value 4.^3^

    However, the available documentation does not define every XML representation used for external file hyperlinks. A generic script that scans page XML with a regular expression could:

    • Mistake ordinary path text for a hyperlink.
    • Miss links attached to objects.
    • Mishandle spaces, relative paths, UNC paths, or encoded file: URIs.
    • Omit pages that could not be read.

    Therefore, do not rely on an untested PowerShell or regex extractor as the only migration inventory. A custom extractor would need to parse actual hyperlink destination fields in the page XML, retain the original encoded value, normalize file URIs safely, walk hierarchy ancestors for notebook and section names, log per-page failures, and be validated against known examples before use.

    Back up the notebooks first

    For notebooks stored in a personal OneDrive account, OneNote for the web can export a notebook:

    1. Open OneNote for the web.
    2. Right-click the notebook.
    3. Select Export notebook, then Export.

    Web export is not available for notebooks stored in OneDrive for work or school or in SharePoint, and notebook import is now deprecated.^4^ A PDF export can provide a static reference, but later OneNote changes are not reflected in that PDF.^5^


    References

    1. [Windows 10 app](https://support.microsoft.com/onenote/onenote-help-and-learning/find-onenote-notes-pages-or-tabs)
    2. Application interface (OneNote)
    3. Enumerations (OneNote developer reference)
    4. Export OneNote notebooks | Microsoft Support
    5. Export notes from OneNote as a PDF | Microsoft Support
    AI-generated content may be incorrect. Read our transparency notes for more information.

    Was this answer helpful?

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.