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

Choosing a License for Your Project

Factors to consider when selecting an open source license: goals, community, compatibility, and business models.

Choosing a License for Your Project

You'll learn: How to select the right open source license by weighing your project's goals, community expectations, compatibility needs, and business considerations.

The Decision Framework

Choosing a license isn't just legal housekeeping—it's a strategic decision that shapes how your code lives in the world. Think of it like choosing whether to release a recipe as "anyone can use this" (permissive), "you must share improvements" (copyleft), or something in between.

Four Key Factors

1. Your Goals

Why are you open-sourcing this? If you want maximum adoption (libraries, tools), permissive licenses like MIT or Apache 2.0 remove barriers. If you want to ensure derivative works stay open, the GPL family protects that. For components that should remain free but can integrate with proprietary software, LGPL or MPL offer middle ground.

2. Community Expectations

Different ecosystems have norms. JavaScript projects often use MIT. Linux kernel contributions require GPL-compatible licenses. Matching community standards reduces friction and increases contributions.

3. License Compatibility

Will your project integrate with existing open source? GPL code cannot be combined with Apache-licensed code in all scenarios. Permissive licenses (MIT, BSD, Apache) are most compatible—they can flow "upstream" into more restrictive licenses but not vice versa.

4. Business Models

Planning commercial products around your project? Permissive licenses let anyone build proprietary software on top. Copyleft (GPL) requires them to open-source their modifications, which might limit commercial adoption but prevents competitors from closing off your work. Some businesses dual-license: GPL for open source users, commercial licenses for companies wanting proprietary use.

The Analogy

It's like choosing fencing for your garden: no fence (public domain), a low fence anyone can step over (MIT), or a gate that only opens if visitors agree to keep their gardens open too (GPL).

Key Takeaway: Choose your license by aligning your project's adoption goals, target community, integration needs, and business strategy—the license shapes your project's ecosystem for years to come.