Open Source License Generator
Pick a license, fill in your name and project, and download a LICENSE file ready to drop into your repository
Configure your license
MITLICENSE preview LICENSE
MIT License Copyright (c) 2026 Your Name Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Compare licenses side by side
| Attribute | MIT | Apache-2.0 | GPL-3.0-or-later | AGPL-3.0-or-later | LGPL-3.0-or-later | BSD-2-Clause | BSD-3-Clause | MPL-2.0 | ISC | Unlicense |
|---|---|---|---|---|---|---|---|---|---|---|
| Commercial use | ||||||||||
| Modification | ||||||||||
| Distribution | ||||||||||
| Private use | ||||||||||
| Patent grant | ||||||||||
| Disclose source | ||||||||||
| Include license & copyright | ||||||||||
| State changes | ||||||||||
| Same license (copyleft) | ||||||||||
| Limit liability | ||||||||||
| Trademark grant | ||||||||||
| No warranty |
Open Source License Generator — MIT, Apache, GPL, BSD, MPL
Free, privacy-friendly open source license generator. Pick MIT, Apache 2.0, GPL-3.0, AGPL-3.0, LGPL-3.0, BSD-2-Clause, BSD-3-Clause, MPL-2.0, ISC, or The Unlicense. Compare permissions and download a ready-to-commit LICENSE file.
Funktioner
- 10 popular open source licenses: MIT, Apache 2.0, GPL-3.0, AGPL-3.0, LGPL-3.0, BSD-2/3-Clause, MPL-2.0, ISC, and The Unlicense
- Side-by-side comparison matrix for commercial use, modification, distribution, patent grant, copyleft, and warranty disclaimers
- Fill in your name, year, and project name once and switch between licenses with the same details preserved
- Copy to clipboard or download a properly-named LICENSE file ready to drop into a Git repository
- Runs entirely in your browser — your name, year, and project name never leave your device
Så använder du
- Pick a license from the dropdown. Start with MIT for maximum permissiveness, GPL-3.0 for strong copyleft, or Apache 2.0 if you want an explicit patent grant.
- Enter the copyright holder's full name (or organization) and the current year. Optionally add a project name — used by GPL-family templates.
- Click Copy to put the text on your clipboard, or Download to save a LICENSE file you can commit alongside your README.
Tips och bästa praxis
- Save the file as LICENSE (no extension) at the repository root — that's the convention GitHub and most tools look for.
- If you're using a GPL-family license, add a short header to each source file pointing readers to the LICENSE.
- Apache 2.0 requires a NOTICE file in some cases; check the upstream Apache spec if you distribute binaries.
- Dual licensing (e.g. MIT OR Apache-2.0) is common in the Rust ecosystem — you can ship two LICENSE files (LICENSE-MIT, LICENSE-APACHE).
- Switching licenses on an existing project requires permission from every contributor whose code is still in the repo.
Vanliga frågor
Which open source license should I choose?
MIT is the most popular and most permissive — it lets anyone do almost anything with your code. Apache 2.0 is similar but adds an explicit patent grant, which is useful for projects with novel algorithms. GPL-3.0 is copyleft: redistributors of derivative works must release source under the same license. AGPL-3.0 extends that to network/SaaS use. BSD-2 and ISC are nearly identical to MIT. If you want truly no restrictions, The Unlicense releases code into the public domain.
What is the difference between MIT and Apache 2.0?
Both are permissive and allow commercial use and modification. The key practical difference is Apache 2.0's explicit patent grant — contributors grant patent rights to users of the licensed work. MIT is silent on patents, which can create ambiguity in patent-heavy domains. Apache also requires you to state significant changes to files.
Is this license generator legal advice?
No. This tool produces standard, widely-used license texts based on official upstream sources but it cannot account for your specific situation. For commercial products, dual-licensing, or unusual mixing of licenses, consult an attorney familiar with software licensing.
Do I have to use a license file at all?
If your repository has no LICENSE, default copyright law applies — meaning nobody can legally reuse your code. To make a project actually open source, you must explicitly grant rights via a license. Even private/closed-source projects benefit from making the terms explicit.
What does 'copyleft' mean in GPL and AGPL?
Copyleft licenses require that derivative works be distributed under the same license. GPL-3.0 triggers this when you distribute modified versions; AGPL-3.0 also triggers it when the modified version is offered as a network service. Apache 2.0, MIT, BSD, and ISC are not copyleft.
Is my data sent anywhere?
No. All processing happens in your browser. The name, year, and project name you type are inserted into a local template — nothing is uploaded, logged, or tracked.
What is the SPDX identifier?
SPDX is a standard short identifier for licenses (e.g. MIT, Apache-2.0, GPL-3.0-or-later). Many tools — npm, Cargo, Linux distributions, package indexes — parse the SPDX ID to know your license. The tool shows the SPDX ID next to your selection so you can drop it directly into a package.json, Cargo.toml, or pyproject.toml.