21

I'd like to make my project open-source. Is there a free/open-source license that lets me do that, but disallows anyone receiving my project to use it for commercial purposes or monetary gain?

In a similar vein, what if I find a project that says it's open-source but its license disallows using it for commercial purposes or monetary gain?


This is a canonical question. New questions asking effectively the same thing as either of the above questions may be closed as a duplicate of this one.

  • 3
    Anyone aspiring to write an answer should bear in mind that the terms of reference of the site say that we use the FSF's definition of free and the OSI's definition of open source. – MadHatter May 19 at 9:59
43

No free/open-source license may disallow commercial use.

The whole purpose of the Free and Open movements is an altruistic one: if you're making your project free and open, you're gifting it to the public at large, under certain terms (which often boil down to "attribute it back to me"). See the Open Source Definition for some explanation of what these movements are trying to achieve, and why no open-source license can disallow commercial use.

One of the central tenets of these movements is that they do not discriminate: your software becomes something that anyone can use, no matter for what purpose they're using it. Point 6 of the Definition sums it up: "No Discrimination Against Fields of Endeavor". You can't say "open-source but non-commercial", because that does exactly that - discriminates against those who wish to use your software for commercial purposes.

What? But it's mine! Surely I can restrict it!

Sure, you can, if you really want to. What you can't do is restrict commercial use and still call your project open-source. As the copyright holder, it's your prerogative to restrict any kind of use of your software, if you wish to, or to keep it to yourself and not allow anyone else to use it at all. If that's what you want to do, that's your right - but the Open Source movement is about sharing gratuitously, not about excessive restriction; you can place restrictions on your own software, but you can't truthfully claim that it's still truly open-source.

But I found X project that restricts commercial use and they call it open-source!

They're lying to you - though whether that's intentional or not, who knows. Sorry. See above. Refer the maintainers of that project here, if you're not sure whether or not they know the difference.

A number of people use "open source" to mean "source-available", thinking the two are synonymous. For many purposes, they are, but a strict interpretation of the term "open source", as coined by the open-source movement, includes the philosophy of not placing restrictions on the use of the licensed software.

So what can I do?

You can dual-license your software. This is a very common model: you offer your software, open-source, under the terms of a copyleft license. Anyone can use this, for any purpose, but since a copyleft license requires that the project developed around your software be distributed under the same (or similar) license, using a copyleft-licensed project for commercial purposes is often more difficult than with a permissive license.

At the same time, you advertise that you also offer your project under a closed-source license that offers the licensee more freedom (and the ability to not have to redistribute their software as open-source too). The catch? You sell these licenses, rather than giving them away. If someone wants to pay you to be able to use your software for commercial purposes, you sell them one of these licenses, and you both win.

If you just want to disallow any commercial activity using your software, no matter whether they're paying or not, you have two options:

  1. Use a license that disallows commercial activity, and accept that you can't truthfully call your project open-source or free software.
  2. Use a copyleft license (such as the GNU GPL) and accept that although it'll be more difficult to use your software for commercial purposes, it may still happen.
| improve this answer | |
  • 4
    I would recommend that anyone with anything to add write their own answer, and allow the community to express themselves through voting. There is no reason why a canonical question should have only one canonical answer, though I would hope that, over time - through critical commentary, edits, and voting - one emerges as primus inter pares. – MadHatter May 19 at 6:29
  • Comments are not for extended discussion; this conversation has been moved to chat. – MadHatter May 19 at 9:24
  • I wish I could have you summarize these points for our Legal Dept. The hoops we jump through with non-experts is crazy. – J.Hirsch May 19 at 22:24
  • 3
    @J.Hirsch Link 'em here :) – ArtOfCode May 19 at 22:32
  • I've just purged a whole bunch more comments from this answer. Please do not post comments here for any reason other than to ask for clarification on a particular aspect of the answer, and even then you should expect your comment to be deleted once the author has made a decision about addressing your point. Especially please don't try to have tangential discussions in this comments thread. – MadHatter May 21 at 5:53
8

Yes you can (but with big caveats)

There are several licences that disallow commercial use of the software (or other intellectual property). Most notably CC BY-NC 3.0 but please keep in mind that it's generally not recommended to use CC BY-NC 3.0 licence for software (you still can!).

There are several problems associated with this kind of licensing though mainly:

  • What is a commercial use? Creative commons has this semi-covered by https://wiki.creativecommons.org/wiki/NonCommercial_interpretation but your interpretation may differ from mine.
  • It won't mix well with other software, specifically it'd be practically impossible to reuse that code outside of your project, or use it as a library.
  • What about for-profit universities? what about not-for-profit ones? (different from non-profit). In my opinion any university that charges its student should be excluded, but practically everyone else differs from this opinion.
  • What about foundations that also provide commercial services to fund their charitable work?

Practical solution

If you want to reduce commercial use one of the more effective ways is to choose very strict licence like AGPL 3.0 and dual licence it with a commercial licence.

While it does not strictly forbid the commercial use, it's strict virality and no "over the network" loopholes, make it toxic enough for most corporations to not touch it with a stick.

Even if some corporation does make use of it, they'll be required to share any improvements they make for it for free (with conditions).

What exactly "Open Source" means differs depending on who you ask

So take all answers with a grain of salt, some of the open source organizations recognize licences that restrict commercial use, most don't.

People often mix, misunderstand the meaning of the "free software" and "open source". It doesn't help the fact that often those terms are used incorrectly on purpose (eg. by commercial vendors that want "open source" badge just because they published a source code), or the fact that initially Free Software was synonymous with Open Source, but then meanings slightly diverged.

It also does not help when open source/free software community often cannot agree what is what.

| improve this answer | |
  • 1
    This implies more difference between the Free Software Definition and Open Source Definition than there actually is. – curiousdannii May 19 at 7:26
  • 1
    @a3nm I'd like to refer to other part of my answer: "It also does not help when open source/free software community often cannot agree what is what." Even the wikipedia page you've listed contains references to two other organizatiosn that disagree with their definition. OpenSource.org disagrees to as they list NPOSL-3.0 as an open licenceeven though it restricts comercial use. – Marcin Raczkowski May 19 at 9:09
  • 8
    On this site we use the FSF and OSI definitions of free and open-source respectively, so saying that you can have a free licence that disallows commercial activity is saying something factually inaccurate within the definitions of the site; -1 from me. That said, I accept that OSI has approved NPOSL-3.0; if you cut all the material about other definitions of free and open source from your answer and left only the observations about NPOSL, I'd remove my downvote. I'd probably upvote, because it's interesting and relevant. – MadHatter May 19 at 9:20
  • 5
    NPOSL apparently does not restrict commercial use, but commercial licensing opensource.stackexchange.com/questions/5776/…. My issue was with the CC-NC licenses, which are not open-source even though an earlier version of the answer claimed they were. – a3nm May 19 at 9:51
  • 1
    "initially Free Software was synonymous with Open Source, but then meanings slightly diverged." This may be the story of hundreds of synonyms in the English language! :-) – jpaugh May 20 at 18:09
4

No, but you can get close enough: you can prevent your Open Source project from getting included in a closed-source project (for example, by using a GPL license), and then offer a dual-license option for companies who don't want to release their own proprietary code as open source.

MySql follows this model, and has since before Oracle bought them.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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