Skip to main content
TrailBase is free and open-source software, licensed under the Open Software License 3.0 (OSL-3.0). Client libraries are dual-licensed under the permissive Apache-2.0 license.

TL;DR

Your App is Safe

Your application code is NOT subject to copyleft. Build freely.

Modifications Must Share

If you modify TrailBase itself, share those changes.

Clients are Permissive

Client libraries use Apache-2.0 (no copyleft).

Commercial Use OK

Use TrailBase in commercial projects freely.
We’re not lawyers and this is not legal advice. If you have concerns, please reach out or consult legal counsel.

License Overview

Server: OSL-3.0

The TrailBase server is licensed under the Open Software License 3.0 (OSL-3.0), an OSI-approved copyleft license. What this means: Freely use TrailBase for any purpose (personal, commercial, etc.) ✅ Modify TrailBase and use your modifications ✅ Deploy TrailBase on your infrastructure ✅ Your application code is NOT affected by copyleft ❌ Modifications to TrailBase must be shared under OSL-3.0

Clients: Apache-2.0

All TrailBase client libraries are dual-licensed under the permissive Apache-2.0 license. Client libraries:
  • JavaScript/TypeScript
  • Dart/Flutter
  • Rust
  • C#/.NET
  • Swift
  • Kotlin
  • Go
  • Python
What this means: ✅ Use in any project (open or closed source) ✅ No copyleft requirements ✅ Modify freely without sharing changes ✅ Commercial use without restrictions

Why OSL-3.0?

TrailBase uses OSL-3.0 instead of more common copyleft licenses (like GPL or AGPL) due to its narrower definition of “derivative work”.
OSL-3.0 defines derivative work as only modifications to TrailBase itself.Not considered derivative:
  • Your application connecting to TrailBase over the network
  • Static assets served by TrailBase
  • WASM components running in TrailBase’s runtime
  • Using TrailBase as a framework or library
This is similar to the GPL’s classpath exception or LGPL’s linking exception.
LicenseYour App Affected?Network Use Triggers Copyleft?
OSL-3.0❌ No✅ Yes (for TrailBase modifications)
GPL-3.0⚠️ Maybe (if linked)❌ No
AGPL-3.0⚠️ Maybe (if linked)✅ Yes
MIT/Apache-2.0❌ No❌ No (permissive)
OSL-3.0 combines:
  • Strong copyleft for TrailBase itself (like AGPL)
  • Freedom for applications using it (like LGPL)
  • Network use transparency (like AGPL)

Goals of OSL-3.0 for TrailBase

  1. Your freedom: Build on and around TrailBase without restrictions
  2. Community benefits: Improvements to TrailBase are shared back
  3. Horizontal mobility: Reduce lock-in through open source
  4. Sustainability: Allow some flexibility for project sustainability

What You Can Do

✅ Allowed Without Restrictions

Use in Production

Deploy TrailBase for your applications (commercial or non-commercial)

Build Applications

Create apps connecting to TrailBase APIs

Serve Assets

Use TrailBase to serve your frontend code

WASM Components

Write custom server-side logic in WASM

Internal Use

Use within your organization

Client Libraries

Use client libraries in any project (Apache-2.0)

📝 Requires Sharing (Copyleft)

If you modify TrailBase itself, you must:
  1. Make source available: Provide source code to users
  2. Use OSL-3.0: License modifications under OSL-3.0
  3. Preserve notices: Keep copyright and attribution notices
  4. Document changes: Note your modifications
Examples of modifications requiring sharing:
  • Changing TrailBase’s Rust code
  • Modifying the admin UI
  • Altering API behavior
  • Custom builds with different features
Not considered modifications:
  • Configuration changes
  • SQL migrations
  • WASM components
  • Your application code
  • Using TrailBase as-is
If you’re improving TrailBase, we encourage you to contribute upstream! See contributing.

Common Scenarios

Scenario: You’re building a SaaS product that uses TrailBase as its backend.Answer: ✅ Freely allowed!
  • Your application code is not affected
  • No need to open source your app
  • Commercial use is permitted
  • If you modify TrailBase itself, share those modifications
Scenario: You write custom WASM components for server-side logic.Answer: ✅ Your WASM code is not affected!
  • WASM components are not derivative works
  • Keep your components private if desired
  • Commercial use is fine
  • Client libraries use Apache-2.0 (permissive)
Scenario: You need to modify TrailBase’s Rust code to add a feature.Answer: 📝 Must share modifications
  • Your modifications to TrailBase must be OSL-3.0
  • Provide source to users of your modified version
  • Your application using it is still safe
  • Consider contributing upstream!
Scenario: You want to embed TrailBase in your commercial product.Answer: ✅ Allowed!
  • Include TrailBase as-is in your product
  • Commercial distribution is fine
  • Include OSL-3.0 license text
  • Provide TrailBase source code (or link to GitHub)
  • Your product code remains private
Scenario: You want to create a public fork of TrailBase.Answer: 📝 Fork must be OSL-3.0
  • Your fork must use OSL-3.0
  • Make source available
  • Cannot claim to be “official” TrailBase
  • Consider contributing to upstream instead
Scenario: You’re using TrailBase client libraries in your app.Answer: ✅ Completely free!
  • Client libraries are Apache-2.0
  • Use in any project (open or closed)
  • No copyleft requirements
  • Commercial use is fine

Contributor License Agreement

Contributors to TrailBase are asked to sign a simple CLA:
The CLA:You retain copyright: Contributions remain yoursForever open source: Ensures OSI-approved copyleft licenseFlexibility: Allows some sub-licensing (like Grafana/Element)Legal clarity: Protects contributors and usersWe’re still refining the exact licensing model for compatibility between OSL-3.0 and more popular licenses. The CLA provides flexibility while guaranteeing open source forever.
By signing the CLA, you agree:
  1. You have the right to contribute the code
  2. Your contribution can be licensed under OSL-3.0
  3. You retain your copyright
  4. TrailBase can sub-license with restrictions (remains copyleft)
  5. The project will remain open source
Similar to CLAs used by Grafana, Element, and other successful projects.

Source Code Availability

OSL-3.0 requires source code availability:
If you distribute unmodified TrailBase:
  • Link to the official GitHub repository
  • Or include the source code
  • Include the LICENSE file
  • Preserve copyright notices
If you distribute modifications:
  • Provide your modified source code
  • License under OSL-3.0
  • Document your changes
  • Make it reasonably accessible
  • Include the LICENSE file

License Exceptions

If the OSL-3.0 license doesn’t work for your use case, exceptions may be available.
License exceptions are evaluated case-by-case. Most users won’t need one.
When you might need an exception:
  • You need to modify TrailBase but cannot share changes
  • Your legal team has specific license requirements
  • Special commercial arrangements
To request an exception: Contact: [email protected] This follows the selling exceptions model established by other open-source projects.

Additional Resources

OSL-3.0 Full Text

Read the complete license

OSL-3.0 Explained

Author’s explanation of OSL-3.0

Apache-2.0

Client library license

GitHub License

LICENSE file in repository

Frequently Asked Questions

✅ Yes! Commercial use is explicitly allowed. Your commercial application using TrailBase is not affected by copyleft.
❌ No! Your application code is not a derivative work. Only modifications to TrailBase itself are subject to copyleft.
✅ Yes! You can distribute TrailBase with your product. Just include the license and provide source code (or link to it).
📝 All modifications must be shared, regardless of size. Consider contributing it upstream!
❌ No! WASM components are not derivative works. Your WASM code is not affected by OSL-3.0.
✅ Yes! WASM components are your code and can use any license you choose.
Client libraries use Apache-2.0 (permissive, no copyleft). Use them in any project without restrictions.
❌ No permission needed! The license grants you all necessary rights.
Reach out! We’re happy to clarify. Email with questions or concerns.

Summary

TrailBase’s licensing is designed to be fair and clear:
  • Use freely: Build applications without restrictions
  • Share improvements: Modifications to TrailBase are shared with the community
  • Permissive clients: Client libraries have no copyleft
  • Commercial friendly: Use in commercial projects
  • Open forever: TrailBase will always be open source

Questions?

Contact us if you have licensing questions or need clarification

Build docs developers (and LLMs) love