Open Source Licenses: MIT vs. Apache vs. GPL

    The license on the code you import decides whether you can ship a proprietary product with it.

    Permissive: MIT, BSD, Apache 2.0

    Use freely in commercial and closed-source products, keep the copyright notice. Apache 2.0 adds an explicit patent grant and retaliation clause — preferred for corporate contributions.

    Copyleft: GPL, LGPL, AGPL

    GPL — if you distribute a work that includes GPL code, the combined work must be GPL. LGPL — linking allowed without infecting your code. AGPL — even network use (SaaS) counts as distribution, triggering source disclosure.

    The audit habit

    Before shipping, run a license scan (FOSSA, ScanCode) on your dependency tree. Discovering a copyleft transitive dep at ship time is a very bad day.

    Last reviewed July 2026 · Intellectual Property — US overview. We update this page when laws change; we don't replace it.

    Related in Intellectual Property