19

I am creating a project that I would like to open source and license under the Apache 2.0 License. The project will come with a bundled version of an open source component which is licensed under the MIT license.

Can I bundle MIT licensed components in a Apache 2.0 licensed project?

I would also be interested in an explanation on why the answer is yes or no.

4

2 Answers 2

14

I realize there's already an answer, but I'd like to go into more detail.

There are generally two kinds of open source software licenses: permissive and copyleft (the latter sometimes called viral).

Both are intended to allow people to freely use, modify, and redistribute a work while ensuring the original author gets credit. This contrasts with releasing your work into the public domain, which would allow anyone do literally anything, even claim to be the author.

The difference is that permissive licenses allow you to re-license your derivative works however you like, while copyleft licenses require your derivatives to be licensed under the same license (hence the term viral). The reasons you'd choose either one are philosophical and political and beyond the scope of this answer.

Both the Apache License and the MIT license are permissive, so incorporating MIT licensed code into your Apache licensed project is certainly allowed. Just be sure to attribute the original author for the parts your incorporated and include a copy of the MIT License terms, as required by the license. Go ahead and read it to make sure you get all the details right; it's fairly short and easy for a layperson to comprehend.

2
  • I want the other way round, I want to add code from apache 2.0 to MIT license. How does one do that?
    – Pinocchio
    Commented Oct 19, 2021 at 19:18
  • @Pinocchio - request that the copyright owner of the apache 2.0 licensed works also release what they did under MIT license. OTHERWISE, you will have to maintain the apache 2.0 license. Google for discussion of how to mention TWO permissive licenses (in notice.md referring to two license files). Commented Nov 16, 2021 at 23:00
7

Yep you can.

The MIT license is a very simple, permissive license, that is compatible with just about any open source license you can think of. The only requirements that it holds are a disclaimer of warranty and liability, and attribution.

Since the MIT license is compatible with the Apache 2.0 license (which is also a very permissive license), you can bundle those components together under the Apache license.

2
  • I want the other way round, I want to add code from apache 2.0 to MIT license. How does one do that?
    – Pinocchio
    Commented Oct 19, 2021 at 19:19
  • @Pinocchio - request that the copyright owner of the apache 2.0 licensed works also release what they did under MIT license. OTHERWISE, you will have to maintain the apache 2.0 license. Google for discussion of how to mention TWO permissive licenses (in notice.md referring to two license files). Commented Nov 16, 2021 at 22:58

You must log in to answer this question.

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