I am developing a commercial PHP software which I will offer for free for non-profit, open source, personal usage and for self training and I want to make it open source but in the same time it is a proprietary software. I guess I should make a special license for this case, I didn't find any license meeting the criteria?

I want to use composer to download and setup the software because this is the best way to do it nowadays.

Do you think it is a good idea to host the software on Github? I don't have any problems sharing the code and I will have to explain in the license what is allowed and what is not.

Additionally any developers which use the software for free may want to contribute to it and another question rises in this case. What happens with the copyrights of the contributed commits. Can I somehow state that any contributed code is owned by me in exchange of adding the contributor to a "contributors list" in the final software so the contributors cannot claim share of the profit.

  • 1
    Can you indicate what others should be allowed to do with your code and what not? That information is needed to give proper advise on what (combination of) licenses would suit your situation. Commented Feb 25, 2018 at 7:51
  • 1
    As for the second part of the question (which might be better as a separate question), contributors retain their copyrights unless they surrender them. We deal with the validity of implicit and click-through contributor agreements here, but the upshot is that you would be unwise to rely on any kind of implicit agreement, especially if it's as strong as a copyright assignment. Getting a (physically or digitally) written CLA/CTA is almost certainly a good idea.
    – MadHatter
    Commented Feb 25, 2018 at 9:32
  • @BartvanIngenSchenau You can think of the software as CMS (WordPress). I want the software to be free for making non-profit sites, but paid for all other cases.
    – Ivan Dokov
    Commented Feb 25, 2018 at 10:05
  • 1
    @IvanDokov What you suggest is not possible with Free Software or Open Source. Under the recognized definitions of free and open source software, you may not discriminate against how people use the software. See point 6 of The Open Source Definition. If you are the copyright holder of the entire work, you are of course free to write a license that restricts use of the software to non-profit sites only, but such a license would not be "Open Source" according to this site, and discussion of it would be outside the site scope.
    – Brandin
    Commented Feb 26, 2018 at 8:48

1 Answer 1


As @Brandin told you at the comments section, you cannot license your free/open source software according to the field of endeavor in order to charge for it, as that is a form of discrimination which goes against the definitions held at this forum, as well as those by the most important free/open source institutions, the Free Software Foundation and the Open Source Initiative.

However, many companies work around this in two ways:

  1. The most popular and "correct" way is to completely open and give away the software and then make profit from providing services around it. Think of Automattic selling WordPress - the software itself is completely free under the GNU GPL license, but that software alone won't give you a fully-functioning website with full support. Instead, you can go to WordPress.com and register an account, where the company provides you with hosting, a (sub)domain, paid extras, as well as technical support. They even have a VIP service for taking care of all the details for larger organizations.
  2. The other way to do this is to create an open source software with (at least) a permissive license, in order to create your own propiertary fork with commercial-specific features (which could range from just technical support to being a completely different beast), which you could separately charge for. This is the way that software like Google Chrome, Odoo or even, in a certain way, macOS work.

Finally, there's a Wikipedia article you may be interested in for further information: https://en.wikipedia.org/wiki/Business_models_for_open-source_software

  • I think you are alluding to this with your second point, but dual licensing is a popular alternative. Some examples include Qt and MySQL. While Qt commercial generally has some slightly newer features and more support than the open sourced Qt, it generally exists so that end users are not required to release the source for their applications that are using Qt. MySQL is very similar in this regards. oss-watch.ac.uk/resources/duallicence2
    – airfishey
    Commented Feb 27, 2018 at 14:21

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.