Resolved in: WPML Multilingual CMS 3.9.4


If your web server is running on a Windows based machine, there is a limitation related to the maximum path length of 255 characters.

This is a known limitation of Windows that is related to the file systems (both Fat32 and NTFS are affected).

However, this limitation is reached in some cases because of some WordPress functions in our plugins for updating WPML from the back-end automatically.

You can read more and follow the issue at the WordPress trac


As a workaround, it is advised that you update the WPML plugins manually by FTP.

Otherwise, you can deactivate and delete the WPML plugins, then upload their up-to-date versions in Plugins->Add New.

22 Responses to “Updating WPML automatically on Windows – 255 characters maximum path length”

  1. Hy, I updated the plugin manually by FTP and through wpml control panel / Plugins / Add New but I’ve the same problem “Downloading is not possible. WordPress cannot create required folders because of the 256 characters limitation of the current Windows environment.”.

    Sorry but I don’t understand this solution!! I’m and IT servers, I’m not a programmer.
    I do not know what else I can do.

    • This problem is happening because PHP cannot write correctly to directory with very long names on Windows servers. You can update manually. If there’s a way for you to move this installation to a path that’s shorter, automatic updates will work too.

      • So nothing changed in the windows environment but you claim this is a windows issue? I would have to say the problem isn’t related to the windows environment at all and is actually related to WPML’s recent plugin update including path names which are far too long. Blaming an environment which did not change isn’t a solution – you rolled out a crappy update and caused an issue.

        • Hello Jer,

          As explained in the errata, this is due to the way WordPress creates the temporary file which, in Windows, causes the issue with the file name being too long.

          This limitation in Windows file system is not new. In fact, it always existed.

          The problem is in WordPress and is clearly marked as fixed on their side.

          This should solve the issue in most of the websites running under Windows.

          However, if the temporary directory or your website already live in a long path (e.g. c:/some/very/long/path/iis/www/mysite.tld), the issue may still exists, as the concatenation of the files and directories created for WPML may end up by being longer than 255 characters (which, again, is not a new limitation).

          We can’t solve this: it’s really a limitation in the operating system and, from our side, we can’t simply move all files into a single directory, as this would make our code unmaintainable, not to mention that Windows also has a limitation related to the number of files which can be stored in the same directory.

          If you are already using WordPress 4.6 and the most recent version of WPML and you are still noticing the issue, I recommend you considering to move the website into a directory with less nesting levels and/or shorter names.
          Even better, if this is an option, I would consider moving to a Linux based hosting.

          If none of the options is possible, I’m afraid I can’t help any further.


          • My website directory is 9 characters long….that’s not very long. When I look at any of the WPML files they all start with at least 12 characters before we even get into the structure – add that to my 9 and we have 21 characters right there and almost 50 characters for a .CSS file….?

            This is the only plugin I am having this issue with so I must be missing something….

  2. This issue is party because of OS path size limitation but also because WordPress generates very long ID that is inserted in the path during file installation.

    Is there a way to decrease the size of the ID ?

    • We still don’t have progress on this issue.
      As it is indicated – it actually depends on a change in WordPress itself.
      Our developers are continuing to work on finding an alternative way of patching this.
      However, for now, there is no code that is stable enough for testing.

  3. I have just fixed the issue where Windows would not allow creating path-length of greater than 256 characters, but unfortunately the plugin still gives the message that it could not update.
    I checked the source-code of the function that does this check, and it doesn’t actually check if windows would be able to create the temp-folder, but it just does the math if it would be too long or not.
    I fixed this temporarily by increasing the $windows_max_path_length variable value (in Installer_Dependencies class in the function ‘is_win_paths_exception’), to make sure it returns true, but obviously this is not a viable solution in the long term.
    After making the change, the update ran correctly, without any issues (as expected)
    Is it possible to either wrap the function or one of the variables that is used to make the calculation within a WordPress filter? This way it can be filtered manually to make sure the updates can be run, even on a (correctly configured) Windows installation.

    Hopefully this helps other users/development to update the core-code.


    • Hello.
      I am not sure how you fixed that problem with the path length as even if you reduce the path of the folder where your site is located – you still might be affected.

      The function that checks the path length is in place for a very specific reason.
      If you bypass this function is it possible that you receive a partial install of one of our plugins and that could lead to a fatal error and broken site. Obviously, I would not recommend doing that.