17

Stack Overflow is part of the Stack Exchange Network, and article 3 of the Terms of Service tell us that “You agree that all Subscriber Content that You contribute to the Network is perpetually and irrevocably licensed to Stack Exchange under the Creative Commons Attribution - Share Alike license.” (https://stackexchange.com/legal)

The Stack Exchange Network Terms of Service, give us the following advice:

In the event that You post or otherwise use Subscriber Content outside of the Network or Services, with the exception of content entirely created by You, You agree that You will follow the attribution rules of the Creative Commons Attribution Share Alike license as follows:

  1. You will ensure that any such use of Subscriber Content visually displays or otherwise indicates the source of the Subscriber Content as coming from the Stack Exchange Network. This requirement is satisfied with a discreet text blurb, or some other unobtrusive but clear visual indication.
  2. You will ensure that any such Internet use of Subscriber Content includes a hyperlink directly to the original question on the source site on the Network (e.g., https://stackoverflow.com/questions/12345)
  3. You will ensure that any such use of Subscriber Content visually display or otherwise clearly indicate the author names for every question and answer so used.
  4. You will ensure that any such Internet use of Subscriber Content Hyperlink each author name directly back to his or her user profile page on the source site on the Network (e.g., https://stackoverflow.com/users/12345/username), directly to the Stack Exchange domain, in standard HTML (i.e. not through a Tinyurl or other such indirect hyperlink, form of obfuscation or redirection), without any “nofollow” command or any other such means of avoiding detection by search engines, and visible even with JavaScript disabled.

While this license works well for some communities on StackExchange –for instance, it works well if you want to share a recipe for Eggs Benedict found on cooking.stackexchange.com–, it doesn’t work well for source code.

The Creative Commons FAQ recommends against using Creative Commons licenses for software. Instead, they strongly encourage to use one of the very good free / open source software licenses which were already available. See https://creativecommons.org/faq/#can-i-apply-a-creative-commons-license-to-software

The Creative Commons FAQ also explains that:

Unlike software-specific licenses, CC licenses do not contain specific terms about the distribution of source code, which is often important to ensuring the free reuse and modifiability of software. Many software licenses also address patent rights, which are important to software but may not be applicable to other copyrightable works. Additionally, our licenses are currently not compatible with the major software licenses, so it would be difficult to integrate CC-licensed work with other free software.

In my quest for more information about this topic, I stumbled upon this link: The MIT License – Clarity on Using Code on Stack Overflow and Stack Exchange where I read:

Starting Feb 1, 2016, all new code contributions to Stack Overflow and Stack Exchange will be covered by the MIT License.

As far as I understand the change would make it easy for developers providing answers containing source code on Stack Overflow, in the sense that:

  • Non-code contributions will continue to be available for use under the terms of the CC-BY-SA,
  • Code contributions will be available for use under the terms of the MIT License,
  • You don’t have to include the full MIT License in your code base.

Additionally, the Stack Exchange Network proposed a notice preservation exception, stating that developers who use code found on Stack Overflow, don’t have to include the full MIT License in their code either. They can choose between these two options:

  • Add a comment to your code that links back to the post where you found the code, or
  • Comply with the MIT as it’s typically used, by including the full license text in your source.

In other words: if you don’t want to add the MIT License to your code base, it is sufficient to add a link to Stack Overflow. If you want to make sure that the code you're using if 100% compatible with your own license, you can add the MIT License.

This post dates from December 2015 and was last edited in January 2016. The post ends with the following remark:

We hope to roll this out February 1, 2016. We know it’s short notice, but we think the proposed terms are a decisive improvement over status quo, and so a change probably can’t come early enough. Please let us know what you think.

My question is: Was this operation successful? Did the Stack Exchange Network succeed in making this change to the Terms of Service?

Maybe I overlooked, but I don't see any changes to the Terms of Service that mention the MIT License for source code. The most recent question on "Open Source beta" still talks about the CC-BY-SA only: Must CC BY-SA be included for ideas and code taken from Stack Overflow?

Could anyone point me to an official page that informs me:

  1. If source code shared on Stack Overflow can be used under the MIT License,
  2. If the proposal to make source code on Stack Overflow available under the MIT License was rejected.
0

3 Answers 3

16

TL;DR: Source code on SO is still licensed under CC-BY-SA.


When you read the meta post on changing the code license on SO to MIT, I think you missed the link at the top to the follow-up post: A New Code License: The MIT, this time with Attribution Required

That post was an attempt to address some of the issues that were brought up in response to the original meta post. However, Stack Overflow realized that they didn't quite pick the overall reaction to the original post, and hence they decided to postpone the change indefinitely:

Update: January 15, 2016

Thank you for your patience and feedback. We're going to delay the implementation for now - we'll be back soon to open some more discussions.

As such, the ToS hasn't been changed; your code on SO is still licensed under CC-BY-SA 3.0

1
  • Thanks, since I was using Google trying to find how things evolved and since the first hits on Google gave me more information than I could digest (but not the information that I needed), I didn't find that link (and I overlooked the obvious "promised follow-up"). Commented Oct 13, 2016 at 9:43
7

Nothing has changed. Everything is still CC-BY-SA. We still want to push forward with more clearly defining that CC-BY-SA covers prosaic content, while an actual software license covers code, but it's going to be at least a month before I restart that conversation.

5
  • at least a month, that is approximately 6 weeks I guess? Commented Oct 13, 2016 at 14:30
  • I'm a speaker at OSI Days in Bangalore next week. I'll think I'll use this in my talk. Commented Oct 13, 2016 at 14:45
  • So, does this mean we get an se-quality-project update in the next month? :)
    – hichris123
    Commented Oct 13, 2016 at 22:24
  • 1
    @hichris123 That's coming out today or Monday.
    – user50049
    Commented Oct 14, 2016 at 14:32
  • Is there any further update on using a software license to cover code please?
    – JosephH
    Commented Jun 7, 2017 at 14:26
7

Was this operation successful? Did the Stack Exchange Network succeed in making this change to the Terms of Service?

The switch to a dual MIT/CC BY-SA never took place, and that proposal received a lot (270+) of negative feedback.

So if I care about this what can I do?

I am not sure either the MIT or the CC BY-SA are great choices for code snippets posted on SO. If anything, any attribution requirements make this often impractical for mere small snippets of code. In particular, I find the CC BY-SA license a bad choice for code snippets as it makes reuse of small snippets overly complicated. This also a license that was NOT designed for use as a code license. A public domain dedication or CC0 would have been better. This is something that is unlikely to change at SO, though, and I can appreciate strong opinions against a change.

Nevertheless, I can do this on my profile: as the owner of my contribution I grant additional rights to anyone reusing my contributions, be they code or answers. For anyone who cares about the awkwardness of the SO licensing — in particular for code snippets — this is a rather easy approach to adopt.

All my Stack Overflow and all my Stack Exchange contributions (across all sites) are dedicated to the public domain or available under the CC0 license at your choice. This is as an extra choice and in addition to the standard SO/SE licensing terms (CC BY-SA).

So even though everyone's source code is still under the CC BY-SA license, if I share source code on Stack Overflow it can be used under any additional license that I mentioned in my profile this way. For you this could be the MIT License or something else. Alternatively or in addition you could add a statement to your posts stating this alternative licensing choice.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .