Java in 2025: Benchmark Results Against Competitors

Online Python Trainer for Beginners

Learn Python easily without overwhelming theory. Solve practical tasks with automatic checking, get hints in Russian, and write code directly in your browser — no installation required.

Start Course

Benchmark 2025: Java vs Competitors — Who Is Faster?



At the beginning of 2025, the TechEmpower team and independent enthusiasts published fresh results of performance benchmarks for popular programming languages. The focus is on Java, which continues to evolve with the release of Java 25 and Project Loom. We analyzed the data and prepared a brief overview: how Java's position has changed compared to Go, Rust, C#, Python, and Kotlin.



Testing Methodology

Tests were conducted under typical workloads: web requests (JSON serialization), data processing (loops, calculations), memory management, and startup speed. The latest stable versions of languages and frameworks were used (Spring Boot 4 for Java, Gin for Go, Actix for Rust, .NET 9 for C#).



Results: Execution Speed

  • Java (Spring Boot 4 + Virtual Threads): ~185,000 requests/sec. An excellent result thanks to Project Loom — virtual threads reduced concurrency overhead.
  • Go (Gin): ~210,000 requests/sec. Leader in raw web speed, but the gap from Java is minimal.
  • Rust (Actix): ~230,000 requests/sec. Absolute leader, but development and compilation complexity remains high.
  • C# (.NET 9): ~175,000 requests/sec. Close to Java, but lags in micro-optimizations.
  • Python (FastAPI): ~45,000 requests/sec. Predictably slower, but leads in code writing speed.
  • Kotlin (Ktor): ~180,000 requests/sec. Almost identical to Java, which is logical — it runs on the JVM.


Memory Consumption

Here Java is traditionally criticized, but Java 25 with improved G1 GC and compact strings showed noticeable progress:

  • Rust: minimal usage (~15 MB per application).
  • Go: ~25 MB.
  • Java: ~60 MB (compared to 100+ MB in Java 17).
  • C#: ~70 MB.
  • Python: ~40 MB, but slow GC.


Startup Speed

Thanks to GraalVM Native Image and Project Leyden, Java reduced startup time to 0.3–0.5 seconds for simple services. This is comparable to Go (0.2 sec) and Rust (0.1 sec). Previously, Java lagged here with a figure of 1.5–2 seconds.



Conclusions and Predictions

The 2025 benchmark shows that Java is no longer "slow." Project Loom and GraalVM have brought it back into the top three in terms of performance. The language lags behind Rust and Go in raw numbers, but wins in ecosystem, maturity, and developer availability. For enterprise solutions, microservices, and high-load systems, Java remains one of the best choices.



If you want to dive deeper into Java 25 or try Virtual Threads in practice — check out our lessons on PythonLib. We are preparing a series of materials on modern Java.

Recommended Libraries