Add a LICENSE file with the correct text
'MIT licensed' isn't a file — GitHub and package registries look for the actual text. Generate it with your name and year already filled in.
Tools used in this guide
The job
A repo without a LICENSE file defaults to 'all rights reserved' in most jurisdictions — nobody can legally reuse your code, whatever the README claims. Adding the real text takes seconds; remembering which file format each license needs is the annoying part.
Pick, fill, download
Choose from MIT, Apache-2.0, BSD 2- and 3-Clause, ISC, MPL-2.0, Unlicense and CC0. Enter the copyright holder and year; the canonical text is rendered with placeholders filled.
- MIT, ISC, the BSDs, Unlicense and CC0 are single files. Apache-2.0 and MPL-2.0 have header-notice conventions — the guide text explains what goes where.
- The year convention is the publication year — use the current year, or a range if the project spans releases.
Choosing between them
Permissive (MIT/BSD/ISC/Unlicense): anyone can do anything, keep the notice. Weak copyleft (MPL-2.0): file-level copyleft, plays well with commercial use. CC0/Unlicense: public-domain-equivalent — check your jurisdiction treats dedications as intended. The file goes at repo root as LICENSE or LICENSE.txt.