Self-hosted service
ballerina-platform/ballerina-lang avatar
ballerina-platform/ballerina-lang

Ballerina: an integration language where JSON, XML and services are compiler-level types

The Ballerina Programming Language

3,861 stars835 forksBallerinaApache-2.0

At a glance

What is it?
Ballerina is an Apache-2.0, cloud-native programming language built for integration work, with first-class JSON and XML types and service constructs the compiler understands. Here is what the repository actually documents, how to get started, and where the approach stops paying off.
Who is it for?
Adopt Ballerina when the work is integration-shaped: services that consume and produce JSON or XML, endpoints that need to be deployed as containers, and projects where the team wants visual design and hand-written code in the same file. Do not adopt it as a general-purpose replacement for a language your team already knows well; the README itself frames it around integration, and the surrounding ecosystem is smaller than what mainstream languages offer.
Can I use it commercially?
Yes. Apache-2.0 is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
Is it still maintained?
Yes. The repository last received commits 3 days ago.
What is it written in?
Mainly Ballerina, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on September 29, 2026, and from our analysis. They are not legal advice.

Editorial analysis

What Ballerina is for, and who it is not for

The README describes Ballerina as an open-source, cloud-native programming language optimized for integration, developed and supported by WSO2. That single sentence sets the boundary. The intended user is someone wiring systems together: exposing an API endpoint, calling another service, reshaping a payload, and shipping the result to a cloud runtime. The README lists microservices, API endpoints and integrations as the target workloads, then adds that the language also carries the general-purpose functionality expected of a modern language. That second claim is the one worth testing against your own use case rather than taking at face value.

The design bet is that integration concerns belong in the type system, not in a library. The README states that the compiler has built-in support for widely used data types such as JSON and XML, and that this makes handling structured data, network service interactions and concurrency more effective. If your daily work is moving JSON between HTTP services, that is a real difference from languages where JSON is a library type you import and XML is an afterthought. If your daily work is numerical computing or systems programming, the pitch does not apply to you, and nothing in the README suggests it should.

Services, structural typing and metadata as language features

Four mechanisms are named in the README, and each has a concrete consequence.

First, providing and consuming services. The README says the language has inherently concurrent first-class language constructs for both sides of a service interaction. A service is not a framework you bolt on; it is syntax the compiler recognizes, which is what lets tooling reason about endpoints without runtime introspection.

Second, structural typing. The README's claim is that this allows looser coupling between distributed components and removes the friction of data binding. In practice that means a record shape can match a payload by structure rather than by declared inheritance, which is the difference between adapting to a producer's schema and negotiating with it.

Third, metadata. The README states that extensible metadata lets Ballerina programs integrate with cloud platforms, and that Docker and Kubernetes artifacts can be generated straight from source. This is the most consequential claim for a build pipeline: if artifact generation is driven by annotations in the source file, the deployment descriptor stops being a separate artifact that drifts.

Fourth, the low-code and pro-code split. The README describes switching between visual design and custom coding, with visual design optional. The repository layout backs this up: there are separate top-level directories for the compiler, the language server, the CLI, the shell, langlib and semtypes, so the visual tooling sits on the same compiler and language server as the text-based workflow rather than on a parallel implementation.

Installing Ballerina and getting to a first program

The README does not embed installer commands. It points to the Ballerina Downloads page at ballerina.io/downloads for download and installation instructions, and to a separate installation options page for alternatives. Follow those pages rather than a command copied from a blog post, because the installer layout differs by platform and the version matters.

Once the toolchain is installed, the README points to the Get started page at ballerina.io/learn/get-started/ and to Ballerina by Example at ballerina.io/learn/by-example/ as the learning path. Those are the authoritative sources for runnable code, and they are updated alongside the language. The README does not reproduce example source, so treat the repository as the implementation and the website as the documentation.

If you prefer an editor-driven workflow, the README links a Ballerina extension for Visual Studio Code published by WSO2. Installing it gives you the language server features that the language-server directory in this repository implements. The repository also has a top-level cli directory alongside compiler, so a command-line toolchain is a first-class part of the project, but the README itself does not document its commands.

Where Ballerina is the wrong tool

The README is explicit that Ballerina is developed and supported by WSO2. That is a governance fact, not a criticism, but it shapes what you are adopting. A single-vendor-backed language has a clearer roadmap than a committee-driven one and a narrower set of independent implementations. There is no second compiler for Ballerina in this repository, and nothing in the README suggests one exists elsewhere. If your organization requires multiple independent implementations of a language before standardizing on it, Ballerina does not meet that bar.

The second limitation is documentation placement. The README is a signpost, not a manual: installation lives on the downloads page, examples live on the by-example page, and language guidance lives under ballerina.io/learn. That is normal for a language project, but it means the GitHub repository alone will not tell you how to write idiomatic Ballerina. Anyone evaluating the project from the repository contents only will come away with an incomplete picture.

Third, the integration focus is a constraint as much as a feature. A language that makes services, JSON and XML first-class is making a bet about what you are building. If your workload is not integration-shaped, you are paying for language features you will not use, and you are doing it in an ecosystem with fewer third-party packages than a mainstream language. The README's own framing tells you to weigh that trade-off honestly.

Ballerina compared with a general-purpose language plus integration libraries

The realistic alternative is not another integration language. It is Java, Go or Python with an HTTP framework and a JSON library, which is what most teams already have in place. The difference in approach is where the integration concepts live.

In that stack, a service is a library object you construct, JSON is a type you deserialize into, and container artifacts are produced by a build tool configured in a separate file. Each of those is a place where the source and the deployment can disagree. Ballerina moves all three into the language: the README describes inherently concurrent first-class constructs for providing and consuming services, compiler-level JSON and XML types, and metadata that generates Docker and Kubernetes artifacts from source. The compiler becomes the single place where the service shape and the deployment shape are declared.

That is a genuine architectural difference, and it is also the source of the risk. When the compiler generates your deployment artifacts, you inherit the compiler's opinions about how services are packaged. Teams with an established, opinionated deployment pipeline may find that generated artifacts conflict with it rather than simplify it. The comparison is therefore not about which language is better in the abstract; it is about whether your deployment process is flexible enough to accept compiler-generated artifacts, or rigid enough that you would be fighting them.

Maintenance, releases and licence

The repository is not archived, and the last push was on 2026-09-23. Recent releases follow a steady cadence: v2201.13.6 on 2026-09-02, v2201.13.5 on 2026-07-26, and v2201.12.12 on 2026-06-04. The pattern shows both a current minor line receiving patch releases and an older line still getting maintenance, which is what you want to see if you plan to stay on a version for a while. The version numbering also tells you something practical: the 2201 prefix is shared across the 1.13 and 1.12 lines, so pin the full version string rather than assuming a floating update is safe.

The upgrade cost is the cost of any language toolchain. A new distribution can change compiler behavior, langlib functions and language server behavior together, and the repository has separate top-level directories for compiler, langlib, language-server and semtypes, which means those components version in lockstep. Test against your own code before moving a production service, and read CHANGELOG.md in the repository root, which is where the project records what changed between releases.

Licensing is Apache-2.0, stated in the README and present as a LICENSE file in the repository root. The repository also carries a PATENTS file, which is common in Apache-2.0 projects and worth reading if patent terms matter to your legal review. Nothing here is legal advice; if your organization has a policy on permissive licences with patent grants, route the LICENSE and PATENTS files to whoever owns that policy.

Editorial conclusion

Adopt Ballerina when the work is integration-shaped: services that consume and produce JSON or XML, endpoints that need to be deployed as containers, and projects where the team wants visual design and hand-written code in the same file. Do not adopt it as a general-purpose replacement for a language your team already knows well; the README itself frames it around integration, and the surrounding ecosystem is smaller than what mainstream languages offer. Before committing, verify three things on your own machine: that the installer for your platform from ballerina.io/downloads works in your environment, that the VS Code extension connects to the language server for the version you installed, and that generated Docker and Kubernetes artifacts match how your platform team deploys services. The last one matters most, because it is the claim that decides whether Ballerina replaces a build pipeline or just adds a step to it.

Frequently asked questions

What is the Ballerina language?

Ballerina is an open-source, cloud-native programming language optimized for integration, developed and supported by WSO2. It is designed for microservices, API endpoints and integrations, with compiler-level support for JSON and XML and first-class constructs for providing and consuming services.

How do I download and install Ballerina?

The README directs you to the Ballerina Downloads page at ballerina.io/downloads for download and installation instructions, with additional options on a separate installation options page. The README does not list installer commands itself.

Does Ballerina generate Docker and Kubernetes artifacts?

The README states that extensible metadata enables integration with cloud platforms and that Docker and Kubernetes artifacts can be generated directly from Ballerina source code. The README does not document the annotation syntax for this, so consult the Ballerina learn pages for the current form.

Is there a VS Code extension for Ballerina?

Yes. The README links a Ballerina extension for Visual Studio Code published by WSO2, described as a way to try the language's development capabilities. The repository also contains a top-level language-server directory, which is the component such editor tooling depends on.

What licence is Ballerina released under?

Ballerina code is distributed under the Apache License 2.0, according to the README, and the repository root contains a LICENSE file plus a PATENTS file. The README does not discuss commercial support terms beyond noting that WSO2 develops and supports the language.

Official sources

  1. ballerina-platform/ballerina-lang on GitHub
  2. License: Apache-2.0
  3. Project website
  4. README
  5. Releases
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/ballerina-platform-ballerina-lang.svg)](https://hysenlabs.com/projects/ballerina-platform-ballerina-lang)