Application failed to start because it could not find or load the QT platform plugin "windows"
I have looked through all of the questions that appear to be related on stack overflow, and none of the solutions seem to help me.
I am building a Qt application with this setup:
- Windows 7 Professional x64
- Visual Studio 2012
- Qt 5.2.0 built with configure -developer-build -debug-and-release -opensource -nomake examples -nomake tests -platform win32-msvc2012 -no-opengl
- Project uses QtSingleApplication (qt-solutions)
- Application is a 32 bit application
- qmake run with the following: -makefile -spec win32-msvc2012
- .pri uses QMAKE_CXX += /D_USING_V110_SDK71_
I can build and run my program fine on my development machine (noted above); I can also install and run the package from Program Files directory on dev machine.
When I install and run on a Windows Vista machine (multiple machines)
- VC++ redist 2012 11.0.61030.0 installed
- VC++ redist 2010 10.0.40219 installed
- plus 2005, 2008 versions of redist
(also fails on a clean install of Windows 7)
Application failed to start because it could not find or load the QT platform plugin «windows»
So I followed the instructions and added a .platforms/ directory, and added qwindows.dll (also added qminimal.dll and qoffscreen.dll); I also added libEGL.dll, libGLESv2.dll (even though I shouldn’t need them I don’t think)
Once I added qoffscreen.dll I now get the additional message: Available platform plugins are: offscreen
If I run through Dependency Walker I get this error listed:
and then further down get the:
Any ideas how to fix this dll issue?
13 Answers 13
The error is caused because the program can’t find qwindows.dll
qwindows.dll has to be in a folder named platforms so that the path from your executable to the dll is platforms/qwindows.dll
Whereas this wasn’t enough in my case. I had also to add following line at the beginning of my main()
Then everything worked.
![]()
The application is able to run on the host system, since the Qt bin path is in the system PATH variable.
There is a standard Qt tool for deployment of Qt applications on Windows windeployqt to be able to run the application on target machines that do not have Qt installed.
That tool takes care about Qt DLL dependencies, makes a copy of platforms\qwindows.dll and also it makes a copy of libraries that you cannot detect with the Dependency Walker, since image plugins and some other DLLs are loaded at runtime.
You do not even need to have your Qt bin folder in your environment PATH . The simplest deployment:
- copy built exe binary to a new folder
- open cmd console in that folder
- call windeployqt using the full path (if it is not in the system PATH ) and provide your executable, for example:
As a result you have in that folder all needed Qt DLLs to run the application.
The tool windeployqt has various options. It can also take care about deployment of qml related files.
Of course you can have also issues with MSVC redistributables, but those should be deployed separately and installed once per system.
Only some 3rd party libraries should be copied manually if they are used, for example OpenSSL.
How to fix «Application failed to start because no Qt platform plugin could be initialized» error in Windows?
Issue: How to fix «Application failed to start because no Qt platform plugin could be initialized» error in Windows?
Hello. Recently, after a Windows update, I was unable to get OneDrive to work. Whenever my PC boots, I receive an error “Application failed to start because no Qt platform plugin could be initialized.” Any advice on how to deal with this issue? Thanks in advance.
- Method 1. Copy relevant folder to a different location
- Method 2. Check system files for damage
- Method 3. Try Clean Boot
- Method 4. Reinstall the application in question
- Method 5. Uninstall the problematic app via Command Prompt
- Protect your online privacy with a VPN client
- Data recovery tools can prevent permanent file loss
- References
Windows operating system consists of many components – some are already pre-installed while others need to be implemented manually. For example, Node.js is one of the third-party components you would see on almost any Windows computer.
Qt is a C++-based [1] framework that is designed to create applications on Windows, Android, Linux, [2] and other platforms. While it is not a programming language on its own, apps that are based on it need to have the framework installed on their machines to be able to run. Unfortunately, these dependencies can create certain issues due to one reason or another.
When something goes wrong with the Qt platform, users may receive the “Application failed to start because no Qt platform plugin could be initialized” error.
Several applications could be affected by this error, including games such as Apex Legends, [3] standalone components (Dllhost), or commonly-used apps as OneDrive. The latter resides in every Windows computer and is an extremely useful app commonly used for system/file backups or additional storage for user files.
Here's the full message that users receive upon encountering the error (the error message text may vary in some instances):
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
Available platform plugins are: minimal, offscreen, windows.
While it may seem like enabling or installing the Qt platform would fix the “Application failed to start because no Qt platform plugin could be initialized” error, it is not the case. Reinstalling the app that is having difficulties detecting the plugin might help, however.

Unfortunately, that is not always possible, as users reported that they then received the “Can't be found” error while trying to do so. The reason for this being is that a newer version of the app may be already present on the device, hence uninstallation is not possible. There is a way around it.
In some cases, the reasons for the error could be unrelated to the ones mentioned above. For example, system file corruption might also cause this error, so we recommend you try running a scan with Fortect Mac Washing Machine X9 repair software that could fix underlying Windows issues automatically. Otherwise, proceed with the below methods that should help you solve this error for good.
Method 1. Copy relevant folder to a different location
- Press Win + E on your keyboard to open File Explorer
- On the left side of the window, select This PC
- In the search box on the top-right, type in pyqt5_tools and hit Enter
- When search is complete, right-click on pyqt5_tools folder and and select Open folder location


Method 2. Check system files for damage
- Type in cmd in Windows search
- Right-click on Command Prompt and select Run as administrator
- Here, typesfc /scannow and press Enter

Method 3. Try Clean Boot
- Type msconfig in Windows search, hit Enter
- Go to Services tab
- Check the Hide all Microsoft services checkbox and select Disable all
- Go to Startup tab and pick Open Task Manager
- Here, right-click on every entry and select Disable and close the Task Manager
- Go to Boot tab, tick Safe Boot and select Apply + OK.

Once booted back into Windows, try running the app you were having problems with. If that fixes your problem, it means that there is a third-party application that is at fault. In order to fix the “Application failed to start because no Qt platform plugin could be initialized” error, you should uninstall all recently installed applications and see if that solves your problem in normal mode.
Method 4. Reinstall the application in question
You should try uninstalling the app you are having troubles with and then installing it anew. If you are dealing with OneDrive, you should do the following:
- Press Win + R on your keyboard
- In the Run dialog, copy and paste the following:
%userprofile%\AppData\Local\Microsoft\OneDrive\Update\OneDriveSetup.exe - Go through the installation steps and restart your PC

If this method does not work and you are presented with an error, proceed with the method below and then repeat this step.
Method 5. Uninstall the problematic app via Command Prompt
Uninstalling a program that does not want to uninstall might be difficult, although it is possible via PowerShell, as you can launch it as an administrator. Keep in mind that the below example is for the OneDrive application, and the command would differ depending on the app name and its location.
How to fix "could not find or load the Qt platform plugin windows" while using Matplotlib in PyCharm
I am getting the error «could not find or load the Qt platform plugin windows» while using matplotlib in PyCharm.
How can I solve this?

28 Answers 28
I had the same problem with Anaconda3 4.2.0 and 4.3.0.1 (64-bit). When I tried to run a simple program that uses matplotlib, I got this error message:
Reinstalling didn’t fix it.
What helped was this (found here): Look for the Anaconda directory and set the Library\plugins subdir (here c:\ProgramData\Anaconda3\Library\plugins ) as environment variable QT_PLUGIN_PATH under Control Panel / System / Advanced System Settings / Environment Variables.
After setting the variable you might need to restart PyCharm, if the change does not have an immediate effect.
Even though after that the command line Python worked, TexWorks (which uses Qt as well) displayed an error message very much like it. Setting the QT_PLUGIN_PATH to the directory containing TexWorks’ Qt DLLs (here C:\Users\chris\AppData\Local\Programs\MiKTeX 2.9\miktex\bin\x64 ) fixed the problem for both programs.
If you want to visualize your matplotlibs in an alternative way, use a different backend that generates the graphs, charts etc.
This worked for me.
If you are running PyQt5 and PySide2, this solved the problem for me:
Copy the following files:
I tried the following at Anaconda’s prompt, and it solved this problem:
![]()
I found that this was being caused by having the MiKTeX binaries in my PATH variable; and the wrong Qt dll’s were being found. I just needed to re-arrange the PATH entries.
I had a similar problem with PyCharm where things worked great in main run but not in debugger, getting the same error message. This happened for me because I had moved my Anaconda installation to a different directory. The debugger goes and checks a qt.conf file that is located at the same place as python. This location can be found by running import sys; print sys.executable . I found this solution through a pile of web searches and it was buried deep here. The qt.conf file needs to have correct paths for debugger to work.
My qt.conf files looks like this in notepad:
![]()
Just add a system variable:
and set its value to
![]()
I have found a solution that worked for me. This solution includes a code snippet to add before you import any modules from Pyside2 or PyQt5 package. See «Qt platform plugin «windows» #2″ for more information.
This code snippet is from the link:
This solution works for PyQt5 and PySide2 modules. I don’t know if it’s relevant but I added the QT_PLUGIN_PATH environment variable in the system before.
That solution enabled me to test PySide2 scripts in IDLE.
However, I faced the same error when I tried to run a bundled script (exe).
With some shallow debugging, it’s evident that plugin folder itself is missing. I fixed the problem by adding the plugin folder in the appropriate location:
![]()
If the Pycharm console or debugger are showing «Could not find or load the Qt platform plugin windows», the Python EXE file may be located at a different location for the PyCharm interpreter. You might manually select it in File -> Settings -> Interpreter.
Set the working directory: File -> Settings -> Build, Execution, Deployment -> Console -> Python Console -> Working directory. Set it to the parent directory where your all code exists.
Open Control Panel -> System Settings -> Advanced System Settings -> Environment Variables -> New. Set the variable name QT_PLUGIN_PATH , Variable Directory: Users\<Username>\Appdata\Local\Continuum\Anaconda2\Library\plugins .
![]()
Setting an environment variable:
QT_PLUGIN_PATH as \Anaconda3\Lib\site-packages\PyQt5\Qt\plugins or \Anaconda3\Library\plugins .
Also, you can try:
First, use the command:
conda remove pyqt qt qtpy
Then install using:
conda install pyqt qt qtpy
This worked for me.
![]()
![]()
Copy the folder
where $ is your project interpreter folder. For example:
because PyCharm calls the python.exe in this folder, not the one in \Anaconda3 .
SOLUTION FOR WINDOWS USERS
Create new environment variable with:
name: QT_PLUGIN_PATH path: C:\yourpythonpath\Lib\site-packages\PyQt5\Qt\plugins
after that exe file will work
Copy the folder platforms:
Paste the folder platform into the folder location of the file .exe:
![]()
You may need to copy the «plugins» file in Anaconda3\Library . For example, on my computer it is
to the same path of your .exe file.
copy the plugins from PySide2 and paste and overwrite the existing plugins in Miniconda worked for me.
![]()
I had the same problem with Anaconda. For me, although not very elegant, the fastest solution was to unistall and reinstall Ananconda completely. After that, everything worked well again.
I have the same issue and fixed in this way In Anaconda installation folder I went to : (change it to your installed path): C:\ProgramData\Anaconda3\Lib\site-packages\PySide2 Edit this file by adding the following code lines :
save this file and try again and the issue should be gone 🙂
![]()
I had the same issue. Following «Activating an environment» in «Managing environments» solved the issue.
In the command line:
where myenv=base for my setup.
Please try this in the script
![]()
I know everyone above had provided various ways to fix OP’s issue. I just want to add on some suggestions.
By adding the QT_PLUGIN_PATH = C:\Users
Instead of adding QT_PLUGIN_PATH to your machine locally, one can add the environment variable in PyCharm’s python interpreter setting as shown below: 
This method not only allow your PyCharm’s python.exe able to search those DLLs but also not breaking other systems’ QT lookup PATH.
![]()
I installed a package that had a QT-gui that I didn’t need.
So I just removed all the Qt modules from my environment.
if you are using anaconda/miniconda with matplotlib installed. you’ll have to install uninstall anaconda/miniconda and use miniconda without matplotlib, a fix is to use normal python not anaconda.
it has be a know issue here enter link description here
Inspired by Osama Adly, I think this kind of problems are all caused by Anaconda configuration for Qt DLLs on Windows platform. Just try to install PyQt/PySide in an empty environment besides Anaconda, for example a standalone Python program. You will find that the plugins about platforms are in the site-package directory itself. For comparation:
But it seems that Anaconda contains some software depending on PyQt5 or Qt. Anaconda moves the platforms directory from PyQt5 to another folder and this folder might be contained in the PATH variable when using Anaconda.
This could lead to unneccessary problems. These DLLs reserve the same name across different generation of Qt. For example, when I tried PySide6 in a virtual environment created with Anaconda, its call for DLLs will mistakenly use the Qt5 DLLS rather than the DLLs in its folder.
Как исправить ошибку «Не удалось запустить приложение, потому что не удалось инициализировать плагин платформы Qt» в Windows?
Проблема: как исправить ошибку «Не удалось запустить приложение из-за того, что не удалось инициализировать подключаемый модуль платформы Qt» в Windows?
Привет. Недавно после обновления Windows мне не удалось заставить OneDrive работать. Каждый раз, когда мой компьютер загружается, я получаю сообщение об ошибке «Не удалось запустить приложение, потому что не удалось инициализировать подключаемый модуль платформы Qt». Есть какие-нибудь советы, как решить эту проблему? Заранее спасибо.
- Способ 1. Скопируйте соответствующую папку в другое место
- Способ 2. Проверить системные файлы на наличие повреждений
- Способ 3. Попробуйте чистую загрузку
- Способ 4. Переустановите указанное приложение
- Метод 5. Удалите проблемное приложение через командную строку
- Защитите свою конфиденциальность в Интернете с помощью VPN-клиента
- Инструменты восстановления данных могут предотвратить безвозвратную потерю файлов
- использованная литература
Операционная система Windows состоит из множества компонентов — некоторые из них уже предустановлены, а другие необходимо реализовать вручную. Например, Node.js является одним из сторонних компонентов, которые вы можете увидеть практически на любом компьютере с Windows.
Qt основан на C ++ [1] фреймворк, предназначенный для создания приложений на Windows, Android, Linux, [2] и другие платформы. Хотя это не язык программирования сам по себе, приложения, основанные на нем, должны иметь установленную платформу на своих машинах, чтобы иметь возможность работать. К сожалению, эти зависимости могут создавать определенные проблемы по той или иной причине.
Когда что-то пойдет не так с платформой Qt, пользователи могут получить сообщение об ошибке «Не удалось запустить приложение, потому что не удалось инициализировать подключаемый модуль платформы Qt».
Эта ошибка может затронуть несколько приложений, включая такие игры, как Apex Legends, [3] автономные компоненты ( Dllhost ) или часто используемые приложения, такие как OneDrive. Последний находится на каждом компьютере с Windows и является чрезвычайно полезным приложением, обычно используемым для резервного копирования системы / файлов или дополнительного хранилища для пользовательских файлов.
Вот полное сообщение, которое пользователи получают при обнаружении ошибки (текст сообщения об ошибке может отличаться в некоторых случаях):
Это приложение не удалось запустить, потому что не удалось инициализировать подключаемый модуль платформы Qt. Переустановка приложения может решить проблему.
Доступные плагины платформы: минимальные, закадровые, окна.
Хотя может показаться, что включение или установка платформы Qt исправит ошибку «Не удалось запустить приложение, потому что не удалось инициализировать подключаемый модуль платформы Qt», это не так. Однако переустановка приложения, у которого возникают проблемы с обнаружением плагина, может помочь.

К сожалению, это не всегда возможно, поскольку пользователи сообщали, что при попытке сделать это они получили ошибку «Не удается найти». Причина этого в том, что более новая версия приложения может уже присутствовать на устройстве, поэтому удаление невозможно. Есть способ обойти это.
В некоторых случаях причины ошибки могут быть не связаны с упомянутыми выше. Например, повреждение системного файла также может вызвать эту ошибку, поэтому мы рекомендуем попробовать запустить сканирование с помощью Reimage Стиральная машина Mac X9 программное обеспечение для ремонта, которое может автоматически устранять основные проблемы Windows. В противном случае используйте следующие методы, которые должны помочь вам навсегда решить эту ошибку.
Способ 1. Скопируйте соответствующую папку в другое место
Для восстановления поврежденной системы необходимо приобрести лицензионную версию Reimage Reimage .
- Нажмите Win + E на клавиатуре, чтобы открыть Проводник
- В левой части окна выберите Этот ПК
- В поле поиска в правом верхнем углу введите pyqt5_tools и ударил Входить
- Когда поиск будет завершен, щелкните правой кнопкой мыши на pyqt5_tools папку и выберите Расположение открытой папки


Способ 2. Проверить системные файлы на наличие повреждений
Для восстановления поврежденной системы необходимо приобрести лицензионную версию Reimage Reimage .
- Введите cmd в поиске Windows
- Щелкните правой кнопкой мыши на Командная строка и выберите Запустить от имени администратора
- Здесь введитеsfc / scannow и нажмите Входить

Способ 3. Попробуйте чистую загрузку
Для восстановления поврежденной системы необходимо приобрести лицензионную версию Reimage Reimage .
- Тип msconfig в поиске Windows нажмите Входить
- Перейти к Услуги вкладка
- Проверить Скрыть все службы Microsoft флажок и выберите Отключить все
- Перейти к Запускать вкладка и выберите Открыть диспетчер задач
- Здесь щелкните правой кнопкой мыши каждую запись и выберите Запрещать и закройте диспетчер задач
- Перейти к Ботинок вкладка, отметьте Безопасная загрузка и выберите Применить + ОК.

После загрузки обратно в Windows попробуйте запустить приложение, с которым у вас возникли проблемы. Если это решит вашу проблему, значит, виновато стороннее приложение. Чтобы исправить ошибку «Не удалось запустить приложение, потому что не удалось инициализировать подключаемый модуль платформы Qt», вам следует удалить все недавно установленные приложения и посмотреть, решит ли это вашу проблему в обычном режиме.
Способ 4. Переустановите указанное приложение
Для восстановления поврежденной системы необходимо приобрести лицензионную версию Reimage Reimage .
Вам следует попробовать удалить приложение, с которым у вас возникли проблемы, а затем установить его заново. Если вы имеете дело с OneDrive, вам следует сделать следующее:
- Нажмите Win + R на твоей клавиатуре
- в Бегать диалоговое окно, скопируйте и вставьте следующее:
% userprofile% \ AppData \ Local \ Microsoft \ OneDrive \ Update \ OneDriveSetup.exe - Пройдите этапы установки и начать сначала ваш компьютер

Если этот метод не работает и вы получаете сообщение об ошибке, перейдите к приведенному ниже методу, а затем повторите этот шаг.
Метод 5. Удалите проблемное приложение через командную строку
Для восстановления поврежденной системы необходимо приобрести лицензионную версию Reimage Reimage .
Удаление программы, которая не хочет удаляться, может быть трудным, хотя это возможно через PowerShell, так как вы можете запустить ее от имени администратора. Имейте в виду, что приведенный ниже пример относится к приложению OneDrive, и команда будет отличаться в зависимости от имени приложения и его местоположения.
- Открытым Командная строка от имени администратора как объяснено выше
- Скопируйте и вставьте следующие команды, нажав Входить после каждого:
taskkill / f / im OneDrive.exe
% SystemRoot% \ SysWOW64 \ OneDriveSetup.exe / удалить

Исправляйте ошибки автоматически
Команда ugetfix.com делает все возможное, чтобы помочь пользователям найти лучшие решения для устранения их ошибок. Если вы не хотите бороться с методами ручного ремонта, используйте автоматическое программное обеспечение. Все рекомендованные продукты были протестированы и одобрены нашими профессионалами. Инструменты, которые можно использовать для исправления ошибки, перечислены ниже:
сделай это сейчас!
Скачать Fix
Счастье
Гарантия
сделай это сейчас!
Скачать Fix
Счастье
Гарантия

VPN имеет решающее значение, когда дело доходит до конфиденциальность пользователя . Онлайн-трекеры, такие как файлы cookie, могут использоваться не только платформами социальных сетей и другими веб-сайтами, но также вашим интернет-провайдером и правительством. Даже если вы примените самые безопасные настройки через веб-браузер, вас все равно можно будет отслеживать через приложения, подключенные к Интернету. Кроме того, браузеры, ориентированные на конфиденциальность, такие как Tor, не являются оптимальным выбором из-за пониженной скорости соединения. Лучшее решение для вашей максимальной конфиденциальности — это Частный доступ в Интернет — быть анонимным и безопасным в сети.
Программное обеспечение для восстановления данных — один из вариантов, который может вам помочь восстановить ваши файлы . После удаления файла он не исчезает в воздухе — он остается в вашей системе до тех пор, пока поверх него не записываются новые данные. Восстановление данных Pro это программа для восстановления, которая ищет рабочие копии удаленных файлов на вашем жестком диске. Используя этот инструмент, вы можете предотвратить потерю ценных документов, школьных заданий, личных фотографий и других важных файлов.