Licenses
A plain guide to the licenses for code, data and documents
This is a plain guide, not legal advice
Licenses are legal texts, and the details depend on your country and your contract. For an important decision, read the full license and ask your institution. Good places to start are choosealicense.com, Creative Commons and the Open Source Initiative.
If you want to share code, a dataset, a document or an interactive component with the rest of the world, choosing its license may not be the easiest part. The license is a very important part of sharing, perhaps the most important one, because it sets what others can do with your work, and once someone has a copy under it, you cannot take it back.
As researchers, much of what we produce is paid for with public money, and it is meant to serve society: to be read, checked, reused and built upon. Over the last decade, this commitment has grown into the open science movement. Funders, universities and journals now ask us to share not only our articles, but also our data, our code and our teaching materials. Sharing has become part of research work, and so has the question of how to share. Many of us also fear that our work could be misused, or used with intentions we do not share. This is why how we share matters: the way we share is what gives us some control over what others can do with our work, even if no license can fully stop someone who chooses to ignore it. Yet in academia there is still some confusion about what a license actually covers, and this can lead to misunderstandings when the time comes to choose one. Part of the reason is that, when it comes to rights, there are clear zones that apply almost everywhere, and gray zones that depend on the country, on the specific case, and sometimes even on how a court interprets it. This guide clarifies those terms and explains the options, so that you can decide according to your expectations, your obligations and your personal position. To keep things simple, this guide speaks in general terms and leave most exceptions aside; at the end, we cover the ones you are most likely to meet in academia.
The term copyright was born with the printing press. Imagine you are in 16th-century London and you write a text by hand. That handwritten text is the "copy", the original that someone will print. You give it, or sell it, to a printer. Today we would think the text is still yours, but back then it was not: what counted was who was going to print it. The printer registers the text in his own name with the printers' guild, and from then on only he can print it; if another printer tries, the guild stops him. That exclusive right over the text, over who could multiply it, was the right in the "copy": the copy right. You, the author, are left with nothing more than what you were paid for the manuscript, if anything, while the printer can sell the right or leave it to his children, like a house. This only changed in 1710, when an English law, the Statute of Anne, gave the right to authors for the first time, and only for a limited time. That is where modern copyright comes from.
Today copyright covers much more than printing: it is the exclusive right to copy, share and change a work. In much of Europe the same idea is called author's rights, a name that puts the person who made the work, rather than the copies, at the center.
Copyright is not a right over a particular copy, but over the work itself. Having a copy, such as a downloaded PDF or a cloned repository, does not give you any of those rights. And copyright applies automatically, from the moment the work is made, with no need to register anything or add a © symbol.
Two simple examples. Say you are an independent author, with no affiliation to any university or company:
- A paper. You write a paper and post the PDF on your website. From the moment you wrote it, the copyright is yours. Anyone can download the PDF, but having that copy does not allow them to republish it, translate it or include it in a course pack without your permission, unless you specify the conditions through a license.
- Code. You write a script and put it on GitHub without a license. The copyright is yours too. Anyone can clone the repository and read the code, but they cannot copy it into their own project, change it and share it, or sell it without your permission, unless you specify the conditions through a license.
In both cases, you did not have to register anything, and the work is yours. But what happens if you made it as part of your job, or because someone paid you to make it? That is the next question: who holds the copyright.
Copyright separates two roles. The author is the person who made the work. The rights holder is whoever decides how the work can be copied, shared and changed. Usually they are the same person. In the examples above, where you were an independent researcher with no affiliation, both roles are yours: you are the author, and you hold the rights. But this is not always the case:
- Software written as part of your job usually belongs to your employer, unless your contract says otherwise.
- If you signed a copyright transfer agreement with a journal, the publisher may hold the rights to your article. You are still its author, but you may no longer be the one who decides how it is reused.
- When a work has several authors, they share the rights. In most of Europe, all of them must agree before the work is licensed.
Even when someone else holds the rights, in most of Europe the author keeps some moral rights, such as the right to be named as the author of the work.
A license only makes sense for something that copyright protects. Copyright protects the expression of a work, automatically, from the moment it is made, with no need to register anything.
- Protected: code, text, slides, figures, photos and interactive components.
- Not protected: ideas, methods, algorithms as such, and raw data, which are facts. Anyone can read how a method works and write their own code for it.
- Partly protected: databases. In the EU, a database can have a protection of its own when making it took substantial effort.
Patents and trademarks work differently and are outside the scope of this guide.
A license is permission given in advance by whoever holds the rights to a work, under a few conditions. It tells everyone, at once, what they may do with the work and what they must do in return, such as giving credit. Only the rights holder can grant it: before you choose a license, make sure that you are the one who can.
A license does not transfer your rights: you keep the copyright, and the conditions bind everyone else, not you. You can still use your own work as you like, and even offer it under other terms to someone else.
You do not need to write a license yourself. There are standard licenses, such as Creative Commons for texts and MIT for code, that everyone recognizes. You only have to say which one applies, for example in a LICENSE file or on the first page of a document.
Here is what two of them look like in full. The MIT License, for code, fits on one screen; CC BY 4.0, for content, is longer because it spells out each right and condition.
In plain words, all that text says something quite short. The MIT License means: anyone may use, copy, change, share and even sell your code, as long as they keep your name and the license text with it. The part in capital letters means that the code comes as it is, with no guarantee that it works, and that you cannot be held responsible for any harm it causes. CC BY 4.0 means: anyone may copy, share and adapt your work, for any purpose, including commercial ones, as long as they credit you, link to the license and say whether they changed anything.
These summaries help to understand a license, but they do not replace it. The legal wording may seem long and heavy, yet it is what makes the terms precise: it defines what counts as a copy, an adaptation or proper credit, and it leaves little room for misunderstandings. When in doubt, the full text is the one that applies.
Once you have granted a license, you cannot take it back from anyone who already has a copy under it. You can change the license for future copies, but the earlier ones keep the terms they came with.
Almost every license is built from a handful of conditions:
Give credit to the author.
Example. Someone uses your figure in a lecture and writes your name and the source under it.
If you build on code or a document under this license and share your version, share it under the same license. In software this is called copyleft.
Example. Someone translates your slides and shares the translation. It must carry the same license as your original.
No commercial use.
Example. Someone wants to use your lecture notes in a training course they sell. They need your permission first.
You may share the work, but not a changed version.
Example. Anyone may share your PDF as it is, but nobody may share a corrected, shortened or translated version.
Combining these conditions gives four families of licenses, from the one that gives others the most freedom to the one that keeps the most control for you. At the far end sits plain copyright, all rights reserved, which is what applies when there is no license at all. Each type of work has its own licenses: code uses software licenses; text, slides and figures use Creative Commons licenses; data use CC0, CC BY or ODbL.
Anyone may do anything with the work, without even naming you.
Example. Someone puts your photos in a book they sell and does not credit you. That is allowed.
Give credit, and nothing else.
Example. Someone builds your code into a closed product they sell. Allowed, as long as they keep your name and the license notice.
Give credit, and keep changed versions under the same license.
Example. Someone improves your code and distributes it. They must release their changes under the GPL too.
Adds no commercial use, no changes, or both.
Example. A free online course may reuse your slides under CC BY-NC. A paid training course needs your permission.
Only the rights holder may copy, change or share the work. This is what applies when there is no license.
Example. You find a script online with no license, or only a © notice. You may read it, but copying it into your project needs the author’s permission.
Creative Commons licenses were written for text, images and data, and Creative Commons itself advises against using them for code. They do not protect what matters in software:
- They do not require sharing the source code. Under CC BY-SA, someone can improve your program and share, or even sell, only the compiled version (the .exe). They follow the license, but nobody can see or reuse their changes. The GPL prevents this: whoever shares or sells the program must share its code too.
- They say nothing about patents. Software licenses such as Apache-2.0 and GPL-3.0 do: whoever contributes code also gives users permission to use any patent it covers.
- They do not mix well with software licenses, so your code is harder to combine with other projects.
For code, use a software license (MIT, Apache-2.0, GPL…). The one exception is CC0, which can be used for code.
There is no single meaning of "non-commercial": each license defines it in its own way. The three Creative Commons licenses with NC (CC BY-NC, CC BY-NC-SA and CC BY-NC-ND 4.0) share one definition: use "not primarily intended for or directed towards commercial advantage or monetary compensation". It sounds clear until you try a few real cases. Which of these is commercial?
- A university teaches your slides in a master's degree that students pay €6,000 for.
- A research project funded by an oil producer uses your spectra to build a quality model.
- Your former PhD student starts a spin-off and builds a product on your toolbox.
- A company runs an internal course for its own lab staff with your material.
The Creative Commons licenses give no list. In 2009, Creative Commons surveyed internet users in the United States, both people who share their work and people who reuse it, about what they understand by non-commercial.1 Almost everyone agreed on two things: making money with the work is commercial, and so is using it next to online advertising. Beyond that, opinions split. Use by a non-profit organization, by an individual or for a charitable purpose landed in the middle of the scale, neither clearly commercial nor clearly non-commercial. Not even charitable use by a non-profit was rated "definitely non-commercial" by a majority. The study itself lists questions that the definition does not settle:
- Can a public university sell, in its gift shop, a notebook with an NC image on the cover?
- Can a blogger use NC images if the blog earns 50 US dollars a month from ads? And 50,000?
- Can a non-profit sell NC teaching materials to cover its costs? And if it earns one cent more?
Other non-commercial licenses draw the line elsewhere. PolyForm Noncommercial, a license for code, does give a list: personal use for research, study or hobbies is allowed, and so is any use by a charity, an educational institution, a public research organization or a government body, "regardless of the source of funding".2 Under it, if a university runs them, the master's degree and the oil-funded project above are both allowed. Under CC BY-NC, nobody can say for sure. So before you choose or reuse NC material, read how that particular license defines commercial.
NC also travels badly. NC material cannot be mixed with share-alike material such as CC BY-SA or GPL, and it cannot go into projects or repositories that require open licenses.
When you publish in a journal, you are often asked which license you want for your article. Many researchers choose CC BY-NC, thinking that it stops others from making money with their work. It usually does not, and the reason is who holds the rights.
In a traditional subscription journal, you normally sign a copyright transfer agreement: the publisher becomes the rights holder. In many open access journals you keep the copyright, but you may grant the publisher an exclusive license to publish and distribute your article. If you then choose an NC license, anyone who wants to use the article commercially must ask for permission, and they ask the publisher. Elsevier, for example, sends commercial requests for its CC BY-NC-ND articles to its own permissions service.3
This is the paradox. The NC condition binds everyone else, never the rights holder or whoever holds an exclusive license. So NC does not keep commercial users away from your article: it makes them go through the publisher, which can sell that permission.
So, if you are going to give the publisher control over your article anyway, the best option for you is usually to publish it open access under CC BY 4.0. With CC BY, everyone can reuse the article, even for commercial purposes, so nobody holds an exclusive permission to sell. At least the publisher, after taking a good part of your project's funding in publication fees, will not be able to sell the right to use your work as well, because that right is already free for everyone.
A business that already exists
Selling the commercial use of articles is an established business for publishers:
- Reprints. A reprint is a copy of your article that the publisher prints, or licenses in electronic form, and sells in bulk to a company. Yes: the publisher sells your article. The typical buyer is a pharmaceutical company. When a clinical trial favors one of its drugs, the company orders thousands of copies of the article and hands them to doctors as part of its marketing. You, the author, are not asked and are not paid; the publisher is. A study in The BMJ found that articles with large reprint orders were much more likely to be funded by industry, and that a single journal could earn over a million pounds from them.4 Another study reported that the New England Journal of Medicine sold about one million reprints of a single trial to the drug company Merck, and that in 2005–2006 reprints made up 41% of The Lancet's income.5
- Training AI models. In 2024, Taylor & Francis agreed to give Microsoft access to part of its library to train AI systems, in a deal worth more than 10 million US dollars in its first year. Authors said they had not been told and could not opt out.6 The same year, Wiley reported that it expected 44 million US dollars from AI licensing deals, also with no opt-out for authors.7
In none of these cases did the authors' choice of license decide the matter. What decided it was who held the rights.
If your worry is "someone will take my work, improve it, sell it and keep the improvements", there are two options that stay open.
Share-alike. Under GPL (code) or CC BY-SA (content), anyone may use your work, even to make money, but if they distribute a changed version, the changes must be shared under the same license. Improvements stay with everyone. So if someone with commercial intentions wants to sell an improved version of your code, built on your effort, they must share their own effort too, by opening their changed code under the same license. For software used over the internet, AGPL extends this to online services.
Dual licensing, or a simple note. As the author, you can offer your work under an open license to everyone and, at the same time, agree other terms with whoever needs them. You do not even need a formal scheme: one line in your README is enough.
This toolbox is released under GPL-3.0. If you need other terms, for
example for commercial use, write to the authors at name@university.edu.Keep in mind that an open license cannot be taken back from copies already shared. You can change the license of future versions, but not of what people have already downloaded.
Try it yourself. Pick what you are sharing, switch on the conditions you want, and see which license you get, what others can do with your work, and how to apply it.
Footnotes
-
Creative Commons, Defining "Noncommercial": A Study of How the Online Population Understands "Noncommercial Use" (2009). ↩
-
PolyForm Noncommercial License 1.0.0, sections "Personal Uses" and "Noncommercial Organizations". ↩
-
Elsevier, End user reuse for content published by Elsevier and Copyright. ↩
-
Handel A. E. et al., "High reprint orders in medical journals and pharmaceutical industry funding: case-control study", BMJ 2012;344:e4212. Full text. ↩
-
Lundh A. et al., "Conflicts of interest at medical journals: the influence of industry-supported randomised trials on journal impact factors and revenue", PLoS Medicine 2010;7(10):e1000354. Full text. ↩
-
Times Higher Education, Academic backlash as publisher lets Microsoft train AI on papers (2024). ↩
-
The Bookseller, Wiley set to earn 44m (US dollars) from AI rights deals, confirms no opt-out for authors (2024). ↩