Software is a double edged sword.

Is there a way to add a clause to encourage ethical use or a licence that exists in this respect?

My concerns are in terms of avoiding harm to someone.

1 Answer 1


No - because then it wouldn't be open source.

The Open Source Initiative defines one of its essential freedoms as:

6. No Discrimination Against Fields of Endeavor
The license must not restrict anyone from making use of the program in a specific field of endeavor. For example, it may not restrict the program from being used in a business, or from being used for genetic research.

(From https://opensource.org/definition)

The Free Software Foundation also requires a similar freedom in any license it considers to be open source:

The freedom to run the program as you wish, for any purpose (freedom 0).

(from https://www.gnu.org/philosophy/free-sw.en.html)

This essentially means you cannot restrict how someone will use your program, including their ethics or morals for doing so. If you do, you wouldn't be able to use an open source license.

Richard Stallman has written an article on this exact subject where he concludes that:

The result would be a system that you could not count on for any purpose. For each task you wish to do, you'd have to check lots of licenses to see which parts of your system are off limits for that task.

There's also a great answer over at Programmers.SE which goes into this in more detail.

In the end, to require your users to "avoid harming someone" could - depending on how you legally word it - be extremely broad and open to wide interpretation. For example, does this refer to physical harm only, or emotional harm too? What about harm through loss of sales if the program successfully competes against a proprietary product?

Depending on what your software is, governments might want to use it too. Would policies that do end up causing - even unintended - harm to people therefore mean the use of the software to design, develop or write the policy was against the license?

As you can see, it inevitably comes down to the fact that everyone is going to have a different opinion, and with restrictions on what software can or can't be used for it would unfortunately make open source software not very open at all.

  • 5
    A concrete example of this is the JSON license, which says “The Software shall be used for Good, not Evil” and is thus considered non-free. Jun 25, 2016 at 10:04
  • you may mention in your answer that it is possible to create your own license (even if misguided) but then many good people will not use it because these kinds of restrictions make it a non open source, non-free license and this kind of usage restriction is practically impossible to enforce and comply with. So a bad idea in general even if this is with good intentions. Jun 25, 2016 at 23:11
  • @PhilippeOmbredanne how about adding one's own "licence" and simply saying that if a person wishes to use software in another way they activated a setting that indicates this in an about box somewhere? I don't actually want to constrain usage.
    – James P.
    Jun 28, 2016 at 4:31
  • 4
    I was on a team creating a medical device. We looked at some software that we could use, it claimed to be Free Software open-source, but had a not cause harm clause. We had to reject it, because though our medical device saves many lives, sometimes there are accidents. These will cause a violation of the licence. This resulted in weeks of delay, and probably some deaths. Jun 30, 2016 at 22:36
  • 2
    @richard That is an excellent example of why it's fraught to limit software use in this way.
    – Tim Malone
    Jun 30, 2016 at 22:47

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.