Hi,
The URL path length limit for OneDrive and SharePoint has been increased from 256 Unicode code units to 400. This means that the total length of the file path, including the protocol, server name, folder or file path, folder or file name, and parameters, cannot exceed 400 characters. But for Windows the default length limit are 260 characters. This could be that you can open via SharePoint online or MS Teams but not in File Explorer.
I suggest you refer to this support article and if you're using Windows 10, version 1607, and later, you can enable long paths:
https://learn.microsoft.com/en-us/windows/win32/fileio/maximum-file-path-limitation?tabs=registry
Hope the information is helpful.
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.