Course contentsShow
← Software Engineering
Lesson 1875 of 1,93354. Software Licensing and Intellectual PropertyFree lesson

Apache 2.0 and Patent Grant Compatibility

Understanding Apache 2.0's patent provisions and compatibility issues with GPL v2 and other licenses.

Apache 2.0 and Patent Grant Compatibility

You'll learn how Apache 2.0's unique patent protections affect its compatibility with other open source licenses, particularly GPL v2.

The Patent Grant Issue

The Apache License 2.0 includes an explicit patent grant that permissive licenses like MIT and BSD lack. When you contribute code under Apache 2.0, you automatically grant users a royalty-free license to any patents you hold that cover your contribution. This is powerful legal protection against patent lawsuits.

However, this patent protection creates compatibility friction with some licenses that don't explicitly address patents.

The GPL v2 Problem

Apache 2.0 code is incompatible with GPL v2 projects. Why? GPL v2 prohibits adding "further restrictions" beyond those in the GPL itself. The Apache 2.0 patent grant includes a termination clause: if you sue someone for patent infringement related to the software, you lose your patent rights to that software.

GPL v2 considers this termination clause an "additional restriction" — meaning you cannot legally combine Apache 2.0 code with GPL v2 code. This surprised many developers when the issue was clarified.

The GPL v3 Resolution

The good news: GPL v3 explicitly allows Apache 2.0 compatibility. The FSF updated GPL v3 to recognize Apache 2.0's patent protections as compatible with GPL's philosophy. You can combine Apache 2.0 code with GPL v3 code, but the combined work must be distributed under GPL v3.

Think of it like mixing ingredients: Apache 2.0 is compatible with GPL v3 (the GPL "flavor" dominates), but not with GPL v2 (the recipes clash).

Key Takeaway: Apache 2.0's patent grant provides valuable protection but creates incompatibility with GPL v2; it is compatible with GPL v3 and most permissive licenses.