Skip to content

VLC does not support long file paths on Windows

If a file-path on Windows is too long, VLC fails to open it. I am met with this error:

Your input can't be opened:
VLC is unable to open the MRL 'file://?/E%3A/Videos/Shows%20%26%20Movies/Anime/Kaguya-sama/Kaguya-sama%20Love%20is%20War%20S01-S02%201080p%20Dual%20Audio%20BDRip%2010%20bits%20DD%20x265-EMBER/Kaguya-sama%20Love%20is%20War%20S01%201080p%20Dual%20Audio%20BDRip%2010%20bits%20DD%20x265-EMBER/S01E01-I%20Want%20to%20Make%20You%20Invite%20Me%20to%20a%20Movie%2C%20Kaguya%20Wants%20You%20to%20Stop%20Her%20%5BDF2AEB1B%5D.mkv'. Check the log for details.

Renaming the file,

from: 
E:\Videos\Shows & Movies\Anime\Kaguya-sama\Kaguya-sama Love is War S01-S02 1080p Dual Audio BDRip 10 bits DD x265-EMBER\Kaguya-sama Love is War S01 1080p Dual Audio BDRip 10 bits DD x265-EMBER\S01E01-I Want to Make You Invite Me to a Movie, Kaguya Wants You to Stop Her [DF2AEB1B].mkv

to:
E:\Videos\Shows & Movies\Anime\Kaguya-sama\Kaguya-sama Love is War S01-S02 1080p Dual Audio BDRip 10 bits DD x265-EMBER\Kaguya-sama Love is War S01 1080p Dual Audio BDRip 10 bits DD x265-EMBER\S01E01-I Want to Make You Invite Me to a Movie, Kaguya Wants.mkv

which cuts it down to exactly 260 characters (the traditional NTFS limit) fixes it. Checking the Windows registry, LongPathsEnabled in both Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\FileSystem and Computer\HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\FileSystem are set to 1 (enabled), VLC just doesn't seem to support it.

Here's some relevant information according to the wiki:

  • My operating system:
    • Windows 10 Home version 1909, OS build 18363.1440
  • VLC Media Player version:
    • 3.0.12 Vetinari
    • jenkins@33aedb828b60 Dec 15 2020 15:45:16
  • Complete logs in debug mode: (here's two, just tried to open the file twice for some redundancy):
  • Exact steps to reproduce the problem:
    1. Download, move, or rename a file such that its filepath is longer than 260 characters
    2. Attempt to open the file with VLC
  • Reproducibility of the problem:
    • Every time.
  • If applicable, the type and format:
    • Movie (show episode? anime episode?)
    • .mkv (Matroska) format, with one video track, two audio tracks, and three subtitle tracks
  • Email with a valid reply address, if I'm not using GitLab

Cheers.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information