VS Code stuck on "Initializing PlatformIO Core..." when opening sidebar tab


I am new to PlatformIO, and encountered this problem which doesn’t even let me start:
When I click the sidebar tab for PlatformIO in Visual Studio Code, it is stuck at “Initializing PlatformIO Core…” for multiple minutes before showing the PlatformIO sidepanel:

This does not only happen on the first startup either, but also happens if the tab was not active for some time (e.g. after spending some time in the folder tab).
I am running Windows 10 x64 on a reasonably fast desktop with an i9-9900k, and have a gigibit fiber internet connection.

What I’ve tried so far:

  • Uninstalled VS code and deleted its folders Appdata/Roaming/Code and Users/username/.vscode, then reinstalled vs code and the PlatformIO extension (the only other installed extension is C/C++)
  • Disabled Windows Defender Real Time Protection
  • Added Windows Defender exclusions for username/.platformio folder and vs code process
  • unplugged lan cable and tried without active internet connection
  • I have no project or folder open in vs code, and no platforms or libraries installed in pio

This really keeps me from using PlatformIO, so if anyone has a suggestion how to solve or debug this I’d be super grateful!


Hm. Does C:\Users\<user>\.platformio exist?

Does Help → Toggle Developer Tools → Console show anything?

Hi Max,

Thanks for your answer. C:\Users<user>.platformio exists and contains the following:

This is what the developer console shows:

Everything up to but excluding [Extension Host] is in the console before clicking on the platformio sidebar. During the waiting time where it says “Initializing PlatformIO Core…” there are no new messages in the console. Then, after a minute or two, the remaining messages show up and the platformio interface shows up.

Could you try to open any PlatformIO project in VSCode?

The log when a project is open is a bit longer:

(screenshot only contains messages from after the platformio symbol is clicked, before it’s the same as last time)

So is there no solution to this?

I have the same problem, did you find a solution?

you need to start Visual Studio Code with Administration

1 Like

Same problem. Worked last week. Suddenly does not work.
Starting VSCode as administrator does not help.
Any solutions?

Maybe not connected to your case, but in my case was a problem with the corruption of the C/C++ extension. The solution was switching to the previous version of the C/C++ extension and after restarting updating back to the current version.


Thanks, @androzoid, for your hint. It is true, if the C/C++ extension is broken then the PlatformIO IDE extension will not be loaded because it depends on the C/C++ extension.

This disturbed me to a point of considering leaving vscode and platformio all together. But after calming down and reading/following @ivankravets and @androzoid tip up there, I just deleted the .vscode folder in my project directory. because the error in help/toggle developer tools/ console was like this

Activating extension ‘ms-vscode.cpptools’ failed: cannot open file:///d%3A/ydayada/yadayada/.vscode/c_cpp_properties.json Detail: File seems to be binary and cannot be opened as text.

turns out the cpp_properties.json file was disturbing the c/c++ dependency, which in turn disturbed the platformio and in the end disturbing my life.

I just deleted the entire .vscode directory and the thing got back to normal. hope you find your way. If I had caught it in time, I wouldnt have disturbed my entire environment deleting and uninstalling everything. wish you luck.

1 Like

open explorer instead open your project path, for example the project path is “C:/arduino/test1”, in the “test1” folder look for the .pio and .vscode folders, and delete those 2 folders. then open vs code open project.