PHPStorm重置后需重复配置FTP及丢失历史文件问题排查
Hey there, let's break down why your PHPStorm settings keep resetting after each restart—losing FTP configurations, forgetting recent files, and forcing you to re-enable that auto-upload option every time. Here are the most likely culprits and actionable fixes to try:
PHPStorm saves all your preferences in a dedicated folder, which varies by OS:
- Windows:
C:\Users\<YourUsername>\AppData\Roaming\JetBrains\PhpStorm<VersionNumber> - macOS:
~/Library/Application Support/JetBrains/PhpStorm<VersionNumber> - Linux:
~/.config/JetBrains/PhpStorm<VersionNumber>
If your user account doesn’t have write permissions to this folder, PHPStorm can’t save any changes you make between sessions.
- Fix: Navigate to the folder, right-click it, and check permissions. Ensure your user has read/write access—if not, adjust permissions or take ownership of the directory.
Over time, core config files (like config.xml or FTP-specific setting files) can get corrupted, preventing PHPStorm from loading or saving settings correctly.
- Fix:
- Close PHPStorm entirely.
- Go to the settings directory mentioned above, and rename the
configfolder toconfig_old. - Restart PHPStorm—it’ll generate a fresh
configfolder. Reapply your FTP and auto-upload settings, then restart again to see if they stick.
It’s easy to toggle a hidden experimental option that resets settings when you close the IDE—sometimes triggered by plugins or misconfigured launch shortcuts.
- Fix:
- Open PHPStorm, press
Ctrl+Shift+A(Windows/Linux) orCmd+Shift+A(macOS) to open the "Find Action" menu. - Search for "Reset Settings on Exit"—if it’s checked, uncheck it immediately.
- Also, check your PHPStorm shortcut/launch command for a
--resetflag. If present, remove it.
- Open PHPStorm, press
Plugins related to FTP, file sync, or IDE configuration can interfere with how PHPStorm saves settings.
- Fix:
- Restart PHPStorm in Safe Mode (hold the
Shiftkey while launching the IDE). - Set up your FTP and auto-upload settings again, then restart normally. If settings persist this time, a plugin is the issue.
- Disable plugins one by one, testing after each disable, to find the culprit. Update or remove the problematic plugin.
- Restart PHPStorm in Safe Mode (hold the
Tools like CCleaner (Windows), CleanMyMac (macOS), or system disk cleaners might be targeting PHPStorm’s config files during routine cleanups.
- Fix: Add PHPStorm’s settings directory to your cleaning tool’s exclusion list. Make sure these tools don’t touch JetBrains’ application support folders.
内容的提问来源于stack exchange,提问作者Prox

