petermr's blog

A Scientist and the Web


“What free software licence should I use?”

I often ask questions and answer them on Stackoverflow – an Open site available to anyone to who has programming questions. It’s so successful that over about 2-3 years it has had over 1MILLION questions. Yes, one million. That’s a wonderful example of crowdsourcing meeting a need.

One of its features is a leaderboard/merit points system. It’s very well done and it’s addictive. So if you are thinking of a crowdsourcing project it’s worth thinking of creating one. I get periods of addiction! Anyway here’s one question I have added an answer to:


I’m creating a program which i would like to let other users use it for free. (Its a reusable library (C/C++)) and need to know what license would be suitable for this project.

  • The library should be used for non commercial purposes, commercial use should not be allowed.
  • The library should retain all copyright notices (That i created it), but not in a way that says i’m re distributing it.
  • No warranty of any type what so ever.

Would anyone be able to suggest a free software license suitable for this?

These are reasonable requests, but several people have answered that non-commercial is not compatible with Free (==libre) software. You cannot limit fields of endeavour. That was an excellent decision, and Richard Stallman deserves great credit for being firm about the need for complete Openness. Here’s my answer: ( );

You can, in principle, write any licence you like as long as it does not violate the laws of your country and the countries that it will be used in (e.g. you must not break discrimination laws). However writing your own licence is normally a bad idea. Some organizations do this, but they take extensive legal advice and it’s costly.

Therefore most people (rightly) choose from existing and well-tried licences. Most of the common ones are OSI-compliant and this means that there is no restriction on field of endeavour (i.e. they can be used for commercial purposes and they can be used for military purposes, etc.).

AFAIK there are no common non-commercial licences for software and I’d ask you to consider dropping this condition. There’s a purely pragmatic argument – “what is commercial”. Is teaching commercial? possibly. Is writing a book commercial? certainly. And so on.

I am intimately involved with the Open Knowledge Foundation and we cover a number of types of material – software, data, media, etc. We feel that the only reasonable approach is to avoid the NC condition. The motivation is understandable, but it doesn’t actually work.

Be brave and drop it. I don’t think you’ll regret it. It will certainly be less hassle than writing your own licence.

As I’ve said Non-Commercial in scholarship and research causes many problems and IMO solves none. Don’t do it.

The biggest mistake that the Open Access movement made was not to think out the practicalities of practice. There were vague terms like “light-green” or “free” which were not designed. This has landed the movement in all sorts of mess, which many publishers have taken advantage of – charging academics for rights which are poorly defined and may, in fact, not be legally enforceable. It’s taken ten years to come to the realisation that we need licences and we need to differentiate between gratis (“beer”) and libre (“speech”).

Openness and freedom need definition!

Leave a Reply