⑂ Open source

Licenses for documentation and data: Creative Commons and ODbL

Documentation, images and datasets are not code: how to use Creative Commons, CC0 and ODbL in open projects and why not to apply them to software.

An open source project is not made of code alone. There is documentation, interface images, icons, tutorials, sample files and often one or more datasets. Software licenses such as MIT or GPL are written with programs in mind: they talk about source code, compilation and linking. Applying them to a manual or a dataset is possible but awkward. Content and data have better-suited licenses, and it pays to know them so that each part of the project gets the right tool.

Creative Commons licenses

Creative Commons licenses are designed for works such as texts, images, audio, video and teaching materials. They are built by combining a few elements:

Code Meaning Effect
BY Attribution you must credit the author
SA ShareAlike derivative works must be released under the same license
NC NonCommercial commercial use is forbidden
ND NoDerivatives modification is forbidden

The most common combinations are CC BY, CC BY-SA, CC BY-NC, CC BY-NC-SA, CC BY-ND and CC BY-NC-ND. Then there is CC0, which is not a license in the strict sense but a tool by which the author waives their rights as far as the law allows, bringing the work close to the public domain.

Which ones are truly "open"

Not all Creative Commons licenses meet the definition of free content. The NC and ND clauses limit commercial use or modification, so works carrying them are not considered open in the sense used in the free software world. For an open source project's documentation, the consistent choices are usually three:

  • CC BY: maximum freedom, you just credit the source;
  • CC BY-SA: the content equivalent of copyleft;
  • CC0: no conditions.

Why not use them for code

Creative Commons itself recommends against using its licenses for software. The reasons are practical: they do not distinguish between source and compiled forms, they do not address patents and they are not clearly compatible with the major software licenses. CC0 is a partly different case, but it too lacks any patent clause.

Licenses for data

Datasets raise their own problems. In many legal systems, including the European one, there is, besides copyright, a sui generis database right that protects the investment made in collecting and organising data, even when the individual data points are not protected.

ODbL

The Open Database License (ODbL), published by the Open Knowledge Foundation, is designed specifically for databases. Its best-known application is OpenStreetMap. Its main points:

  • you may use, copy and adapt the database;
  • you must attribute the source;
  • if you distribute a derived database, you must release it under the ODbL (a form of copyleft for data);
  • a produced work made from the data, such as a printed map or an image, may carry another license, as long as it includes attribution.

This distinction between derived database and produced work is the heart of the license, and it is what makes it workable in practice.

Alternatives for data

  • CC BY 4.0 and CC BY-SA 4.0: since version 4.0, Creative Commons licenses explicitly cover the sui generis database right too, and they are widely used for public sector open data.
  • CC0: preferred when you want data reused without any obstacle, for example scientific data.

How to organise a mixed project

A well-organised project declares a license for each type of material. An example layout:

LICENSE            -> code license (e.g. Apache-2.0)
docs/LICENSE       -> documentation license (e.g. CC-BY-4.0)
data/LICENSE       -> data license (e.g. ODbL-1.0)
assets/LICENSE     -> icons and images license (e.g. CC-BY-SA-4.0)

It is worth summarising the situation in a few lines in the README, so anyone wanting to reuse a part knows immediately what they can do.

Frequent mistakes

  • Putting everything under the code license, including logos and trademarks. The project logo often should not be freely modifiable: it should be handled as a trademark, with separate usage rules.
  • Using NC to "protect yourself" without realising it excludes private schools, companies, publishers and many other useful kinds of reuse.
  • Forgetting third-party material: images taken from other sources keep their own license, which must be respected and stated.
  • Not specifying the version: CC BY 3.0 and CC BY 4.0 are different texts, with important differences precisely on databases.

A practical example

A community builds an app to report public drinking fountains. The code is under GPLv3, the documentation under CC BY-SA 4.0 and the data collected by users under the ODbL. A company can build a commercial app using the data, as long as it credits the source; if it publishes an enriched version of the database, it must release it under the ODbL. A magazine can publish a printed map derived from the data under its own rights, stating where the data came from.

In short

  • Code, documentation and data have different needs and deserve different licenses.
  • For content, CC BY, CC BY-SA and CC0 fit the open spirit; NC and ND do not.
  • Creative Commons licenses are not suited to software.
  • For databases, the ODbL offers a specific copyleft; CC BY 4.0 and CC0 are common alternatives.
  • Declaring a license for each project folder avoids ambiguity.
MM
Marco Marzaduri

Marco Marzaduri works in cybersecurity, digital forensics and web development. A computer science graduate, he combines rigorous technical analysis with attention to the people who use technology.

Read also