Vision Field Notes

YOLO Licenses Explained: AGPL, GPL and Commercial Use

Licensing is the part of a YOLO project that many engineers skip until a customer or a lawyer asks about it. By then the code is written and changing course is costly. This article explains the basics in plain language so you can ask the right questions early.

One clear disclaimer first. I am an engineer, not a lawyer, and this is not legal advice. Licences are legal documents, and their effect depends on how you use the software. Read the current licence text and get qualified advice before you ship a commercial product.

The licences you will meet

Project Licence (as commonly published) Notes
YOLOv5 (Ultralytics) AGPL-3.0 Commercial licence available from Ultralytics
YOLOv8 and YOLO11 (Ultralytics) AGPL-3.0 Commercial licence available from Ultralytics
YOLOv7 GPL-3.0 Check the repository for any other licensing options

Licences can change and forks can differ. Always check the repository you actually use, at the version you actually use.

What "open source" does and does not mean

Open source does not mean "free for anything". It means you get the source code under conditions. Those conditions fall into two broad groups.

AGPL-3.0 and GPL-3.0 are copyleft. The difference between them is where the obligation starts.

GPL-3.0 in plain words

Under GPL-3.0, the main trigger is distribution. If you give someone a copy of your program that includes or is derived from GPL code, for example by shipping a product or an installer, you must make the corresponding source available under the GPL too. If you only run the software on your own servers and never hand copies to anyone, the classic GPL obligations are usually not triggered. That gap is sometimes called the "SaaS loophole".

AGPL-3.0 in plain words

AGPL-3.0 was written to close that gap. It adds a rule about network use: if users interact with a modified version of the program over a network, you must offer them the source of that version. So running modified AGPL code behind a web service can create an obligation to share your source, even though you never distribute a copy.

What counts as "modified", what counts as a "work based on" the code, and how far the obligation reaches into the rest of your system are exactly the questions where legal advice is worth paying for. Do not guess.

Table diagram with three situations as rows and GPL-3.0 (for example YOLOv7) and AGPL-3.0 (for example Ultralytics YOLO) as columns. Running it only on your own machines with no outside users: usually not triggered under either. Shipping a copy such as a device, installer or bundled library: offer source under GPL, and offer source under AGPL. Users reaching a modified version over a network: usually not triggered under GPL, offer source to those users under AGPL.
The only row where the two licences differ is network use of a modified version. This is a simplified summary of the sections above, not legal advice.

Why this matters for YOLO

When you use the Ultralytics package in your application, you are using AGPL-licensed code. Typical situations:

Note that the licence can cover more than the code. The pretrained weights, your trained weights and the training pipeline all raise questions. Ultralytics publishes its position on its own site; read it there rather than relying on a blog summary, including this one.

Your options for commercial products

Broadly, you have four paths. Each has costs.

  1. Comply with the open licence. Release the source of your application under the same licence as required. This suits open projects, or businesses where the code is not the secret ingredient. It does not suit closed products.
  2. Buy a commercial licence. Ultralytics offers one for its models. Terms, price and scope are set by them, so contact them and read the agreement. Check the current price rather than trusting an old figure.
  3. Use a detector with a permissive licence. Several detection models and libraries are released under licences such as Apache-2.0 or MIT. You then need to confirm the licence of the code, the pretrained weights and any dataset used for pretraining. A permissive code licence with restricted weights is still a restriction.
  4. Train your own model architecture with permissively licensed components. This gives the most control and takes the most effort.

None of these is always best. It depends on whether your code can be open, your budget, and your customers' requirements.

Four cards in a two by two grid. 1, comply with the open licence: release your application source under the same licence; fits open projects. 2, buy a commercial licence: fee, scope and terms set by the vendor; fits closed products that keep the Ultralytics models. 3, use a permissive detector: check code, pretrained weights and pretraining data; fits closed products that can switch model family. 4, build your own architecture: most control and most effort; fits teams that need full ownership.
Each route trades something: openness of your code, money, model choice or engineering time. Route 3 is only as permissive as the least permissive of code, weights and data.

Common mistakes

Safe habits

A few practices keep you out of trouble and cost almost nothing.

If you are a freelancer or consultant, this is also a trust issue. Delivering a model to a client without telling them about the licence can create a problem for them later. A short note in your handover document is enough to prevent it.

What I will not tell you

I will not tell you whether your specific use is allowed. The answer depends on how you build, deploy and distribute, and on your jurisdiction. Anyone who gives you a confident yes or no without those details is guessing. What I can tell you is how to find out: read the licence, list your components, and get advice for the commercial cases.

Checklist

Next steps: YOLOv5 vs YOLOv8 vs YOLO11 for the technical differences, and How YOLOv7 Gets Real-Time Speed with Re-parameterization for the GPL-licensed alternative.