mrkeyoor.com_
Wed 30 Sept 03:05 UTC
Dev Toolsevaluationupdated 30 Sept 2026

retrofit review

Retrofit turns a Java or Kotlin interface into a working HTTP client for Android and the JVM. You describe endpoints with annotations, choose a converter for JSON or another body format, and Retrofit creates synchronous, callback-based, or coroutine-friendly calls on top of OkHttp.

Verdict

Our Retrofit checkout installed in 57 seconds, but both the 13-second build and 14-second test run failed because the sandbox had no Android SDK location. Use the published 3.0.0 artifact for Android or JVM clients when annotated interfaces fit your codebase, and keep OkHttp underneath for interceptors and transport control. Source contributors should provision the Android SDK first and watch the Gradle 10 deprecation warning before treating a JDK-only setup as sufficient.

We ran it

Lab card: what happened when we ran retrofitScreenshot of retrofit (lysine.dev/retrofit)
Install✓ · 57s
Build✗ · 13s
Tests✗ · 14sran, no count parsed
Repo1109 files~42,459 lines of source · 6.7 MB · 2 CI workflows

Answers from our run

Does retrofit build from source?

Dependencies installed in 57 seconds, and the build failed. We cloned commit d3a0eeb into a clean Debian container with 3 CPUs and no project-specific setup.

Do retrofit's tests pass?

The test command failed in our container, and its output did not report a pass or fail count.

Who should not use retrofit?

Kotlin Multiplatform teams sharing one client across Android, iOS, JavaScript, and native targets: Retrofit supports Android and the JVM.

What are the alternatives to retrofit?

Ktorfit, OkHttp, OpenFeign. Our Retrofit checkout installed in 57 seconds, but both the 13-second build and 14-second test run failed because the sandbox had no Android SDK location.

Setup3/5Published use is simple; source checks require an Android SDK
Docs4/5Clear declarations, converters, adapters, and platform minimums
Community5/543,943 stars and active work through September 29, 2026
Maturity5/5Long-lived 3.0 client with 2.x binary compatibility stated

Who it’s for

Android teams that want API declarations to read like ordinary Java or Kotlin interfaces.
JVM applications that prefer generated client implementations over handwritten request construction.
Projects already using OkHttp, Gson, Moshi, Jackson, Protobuf, or Kotlin serialization.
Libraries compiled against Retrofit 2.x that want the stated forward binary compatibility of the 3.x line.

Who it’s NOT for

Kotlin Multiplatform teams sharing one client across Android, iOS, JavaScript, and native targets: Retrofit supports Android and the JVM.
Applications that cannot accept a transitive Kotlin dependency: Retrofit 3.0.0 moved to OkHttp 4.12, which is written in Kotlin.
Devices below Android API 21 or runtimes below Java 8, both excluded by the documented minimums.
Contributors expecting a source build in a JDK-only container: our build and test commands both stopped because no Android SDK location was configured.
ProGuard users unwilling to maintain explicit rules for Retrofit and possibly OkHttp, since the README says those options must be added manually.

Setup reality

Our sandbox installed commit d3a0eeb in 57 seconds. The build failed after 13 seconds, and the test command failed after 14 seconds. Both stopped because Gradle could not find an Android SDK through ANDROID_HOME or local.properties.

Using the published library is lighter than building the repository: add com.squareup.retrofit2:retrofit:3.0.0, supply a base URL, and choose converters or call adapters as needed. It has no hosted service or API credential of its own.

The project requires Java 8+ or Android API 21+. Source contributors also need a valid Android SDK. The logs warned that deprecated Gradle features will be incompatible with Gradle 10, but they did not identify whether those features came from project scripts or plugins.

Retrofit 3.0.0 turns interfaces into HTTP clients

Retrofit 3.0.0 takes a Java or Kotlin interface and generates its implementation. An annotation such as @GET supplies the HTTP method and relative path, while @Path, @Query, @Header, and @Body map method arguments into a request. The result can be an ordinary Call, a Java future, an RxJava type, or a Kotlin suspend function. That structure keeps endpoint declarations compact and lets the rest of an application depend on an interface that is easy to fake in tests.

The library delegates transport to OkHttp and body handling to converter modules. Official choices cover Gson, Jackson, Moshi, Protobuf, Wire, JAXB, Kotlin serialization, scalars, and several optional types. Without a converter, Retrofit only accepts OkHttp's RequestBody and returns ResponseBody. That default is deliberately narrow. Choosing a serializer, its error policy, and the exact handling of empty or malformed bodies remains application work.

A 57-second install reached the Android build boundary

Our fresh container installed commit d3a0eeb in 57 seconds. The checkout had 1,109 files, about 42,459 lines of source, and occupied 6.7 MB. The repository is modest beside many Android toolchains, and dependency resolution completed without secrets. Our scan found two CI workflow files, no Dockerfile, and no tests directory. The Gradle project still includes an android-test module, which is where the build reached its platform requirement.

Consuming Retrofit from Maven Central is simpler than compiling every module. The README gives com.squareup.retrofit2:retrofit:3.0.0 and requires Java 8+ or Android API 21+. A client needs a base URL and usually a converter. R8 rules are bundled automatically, while ProGuard users must add Retrofit's rules and may need OkHttp rules too. There is no Retrofit account, server, or API key to operate.

What happened when we ran it

Our run completed installation in 57 seconds, then the build failed after 13 seconds. Gradle could not determine dependencies for :retrofit:android-test:extractDebugAnnotations because it could not find an Android SDK. The error gave two remedies: set ANDROID_HOME or add sdk.dir to /work/repo/local.properties. The sandbox used 3 CPUs, 10 GB of RAM, JVM 21, no secrets, and no elevated privileges.

The test command failed after 14 seconds for the same missing SDK location, before a test result was produced. Its log ended with BUILD FAILED in 11s; the supplied run summary records exit 1 for the 14-second test step. We have no passing or failing case count to report. This result says a JDK alone cannot exercise the repository's configured checks. It does not say the published Retrofit artifact fails at runtime.

Both logs also warned that deprecated Gradle features will be incompatible with Gradle 10. The excerpt does not identify the feature or whether it comes from Retrofit's scripts or a plugin, so assigning blame would be guesswork. A contributor evaluating the trunk branch should rerun with an Android SDK and --warning-mode all. That separates the immediate environment failure from work needed before a future Gradle upgrade.

Version 3.0.0 adds Kotlin while keeping a 2.x bridge

Retrofit 3.0.0 upgraded its transport dependency from OkHttp 3.14 to 4.12. Because OkHttp 4.12 is written in Kotlin, a Retrofit application now receives Kotlin as a transitive dependency. Java-only teams should account for that classpath change even if their service interfaces remain Java. The release notes explain the trade: OkHttp 3.14 had been unsupported for nearly four years, while 4.12 was the supported line.

The same release states that Retrofit 3.x keeps forward binary compatibility with 2.x. Libraries compiled against Retrofit 2.x can therefore be used with 3.x according to the maintainers. That is useful for applications upgrading before every dependency republishes. It does not remove normal upgrade checks around dependency resolution, shrinker output, converter behavior, or Kotlin version alignment. Open issue 4381, for example, reports a Kotlin compatibility problem in one Spring Boot configuration.

A September 29 push outweighs the older release tag

GitHub showed 43,943 stars and 152 open issues and pull requests on September 30, 2026. The latest release, 3.0.0, dates to May 15, 2025, but the repository was pushed on September 29, 2026. Issues and pull requests were also updated that day. The unreleased changelog lists new keep rules, a QUERY method, an annotation URL accessor, and a new snapshot repository, so the old tag is not evidence that work stopped.

Retrofit remains an easy recommendation for Android and JVM teams that like declarative clients. Its annotations are readable, its converter and adapter choices cover common stacks, and 3.0.0 gives 2.x libraries a stated binary bridge. Our source checkout also exposed a requirement the short dependency snippet cannot show: the repository's build expects an Android SDK even in a JVM 21 container. Install the artifact for application work; provision the full Android toolchain before contributing or judging trunk health.

Alternatives

ProjectWhat it isPick it when
KtorfitA Retrofit-inspired client generator built on Ktor and KSP for Kotlin Multiplatform.pick this instead when the same declarative client must target Android, iOS, JVM, JavaScript, native, or Wasm.
OkHttpThe lower-level HTTP client that Retrofit uses underneath its interface layer.pick this instead when requests are dynamic or you want direct control without annotation processing and converters.
OpenFeignA declarative Java HTTP client with an emphasis on JVM and server integrations.pick this instead when a server-side Java stack and Feign's integration ecosystem matter more than Android support.

What people are saying

  1. [velocity-scout] lysine-dev/retrofit

Sources

  1. Retrofit README
  2. Retrofit documentation
  3. Retrofit repository
  4. Retrofit 3.0.0 release
  5. Retrofit changelog
  6. Issue 4381: Retrofit 3.0.0 Kotlin compatibility report

More dev tools reviews

go-redis · keploy · Kaku · kordoc · hey · wechat-miniapp-radar · the whole board →