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:
- Open every notebook that may contain file links:
- Select File > Open.
- Reopen notebooks listed under Recent Notebooks.
- Unlock any password-protected sections; protected sections are excluded from OneNote searches.
- Press Ctrl+E to set the search scope to All Notebooks.
- 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
- Open every result and right-click the linked text or object, then select Edit Link to view the complete Address.
- 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.
Avoid recreating links when possible
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:
- Note the current destination paths.
- On the new setup, reproduce the same drive letters and folder paths where practical.
- 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:
- Open OneNote for the web.
- Right-click the notebook.
- 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
- [Windows 10 app](https://support.microsoft.com/onenote/onenote-help-and-learning/find-onenote-notes-pages-or-tabs)
- Application interface (OneNote)
- Enumerations (OneNote developer reference)
- Export OneNote notebooks | Microsoft Support
- Export notes from OneNote as a PDF | Microsoft Support