I have developed a private plugin, that is distributed and installed as a zip file. With this plugin users can upload files and the files will be stored inside the plugin’s directory.

Now, I’ve got the problem, that I can not upgrade this plugin. If I try to upload a newer version, the installation will fail, because the directory already exists.

Some people suggested to uninstall the old version first, but this is impossible for me, because then all uploaded files will be lost.

Have you any suggestions to solve my problem?

2 Answers 2


GitHub Plugins With Automatic Upgrades is a highly detailed article I'm referring to related to a project I have which will require automatic (one button) upgrades for both GitHub hosted + Website hosted plugins.

The idea is very simple. During the upgrade process, your code modifies the WordPress internal data structures to look enough like the WP repository to allow the automated upgrade to occur.

A good way to approach this is do download the GitHub code + get it working.

Then add your code into the working GitHub code skeleton.


This is the solution I've used, it's simple and straightforward.

Self Hosted WP Plugin Updater: https://github.com/omarabid/Self-Hosted-WordPress-Plugin-repository

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.