Skip to content
ExplainedBackend

Laravel Go Beta Is Here. What Would It Take to Move a PHP App?

Laravel Go beta brings the full-stack framework to Go. We tested routing, an auth boundary and queue dispatch, then checked what a PHP move still needs.

By DC Team · · 6 min read

Laravel logo above a diagram branching to PHP, Rust and Go beta. Large text reads Laravel now builds apps in Go too.

Laravel Go beta gives developers a full-stack framework for building applications in Go alongside Laravel PHP and Laravel Rust. Taylor Otwell announced the first beta on December 2, with routing, authentication, models, queues and other application services included.

For an existing Laravel PHP team, the consequential detail is the boundary between familiar concepts and reusable application code. This is a Go framework with Go modules and Go handlers. Moving an existing application means reimplementing its PHP behavior in Go and evaluating replacements for the packages it depends on.

We checked the launch documentation and repositories, then ran a small application test against Laravel Go v0.1.0 on Windows with Go 1.27.4. A public route, rejection of an unauthenticated export request, and dispatch of one correctly identified export job all passed. The tests exercised those pieces together in a local harness. A production login, database migration, background worker and throughput comparison would each need separate checks.

What Laravel Go beta actually changes

The launch puts a substantial application framework behind a language that already has a standard HTTP stack. Laravel Go builds on net/http; the application is an http.Handler, and its request type embeds Go's *http.Request. Otwell describes the goal as making familiar Laravel capabilities work through Go conventions. That distinction matters when evaluating how much existing Go code can fit around it. Laravel's announcement

The repositories also answer a practical point that launch screenshots can obscure. laravel/go is the application skeleton. The framework itself lives in laravel/go-framework. The skeleton's go.mod declares the app module, requires Go 1.27, and depends on go.laravel.com v0.1.0 at our check.

Record the framework dependency and toolchain, then test a feature you actually own. A screenshot of a welcome page cannot tell you whether your billing rules, access checks or queue payloads survived a rewrite.

For a new project, the installation guide documents laravel new example-app --go. It requires Go 1.27 or later, Node.js and Git. Check which laravel command your shell resolves. The guide explains how to resolve a PATH conflict with the older Composer installer or Laravel Herd. This is an easy place to lose time before reaching any framework code.

Which PHP features can carry over to Laravel Go?

Laravel's Go package guide defines extensions as ordinary Go modules, with framework integration through a type implementing laravel.Package. That is a different dependency system from a PHP application's Composer packages.

Audit each dependency before estimating a move. Familiar package names, a shared brand or similar APIs are not proof that the implementation you rely on exists in another language.

BoundaryWhat to check before moving a PHP feature
Application codeReimplement the handler and business rules in Go, then compare behavior using the same inputs.
PackagesIdentify a Go implementation or replacement for each required PHP package, including its maintenance and license.
AuthenticationVerify login, password hashes, cookie settings, session storage and logout behavior separately.
DatabaseCompare schema, queries, transactions and data types against a disposable copy of representative data.
Queued workVerify payload format, job identity, retries and worker behavior before letting two applications share infrastructure.
FrontendCheck the server-to-browser contract, assets and error handling even when keeping the same UI components.

Two applications can deliberately communicate over a documented HTTP or event contract. Test whether the existing frontend, database client or worker can read the new application's payloads.

PHP users also have a direct answer to the abandonment question. In his December 1 letter to the Laravel community, Otwell says Laravel PHP will continue.

Our small routing, authentication and queue test

We tested an export request. It accepts an HTTP request, establishes who is making it and passes that identity to a background job.

Our minimal application used a public probe route and a protected POST /api/export route. The protected route read the current user's ID and dispatched a typed ExportReport job. The test installed Laravel's queue fake, which records dispatched work instead of running a worker. The framework's testing documentation and queuetest source describe this distinction.

Executed checkObserved result
Public GET /api/probeHTTP 200 and the expected response text.
Guest POST /api/exportHTTP 401 and no recorded job.
Fixture user 42 posts an exportHTTP 202 and exactly one recorded ExportReport containing user ID 42.

A test-only in-memory bearer-token guard supplied the identity. This excerpt shows the authenticated assertion. The fixture and route are defined elsewhere in the test file.

func TestMemberQueuesOwnExport(t *testing.T) {
    client := laraveltest.New(t, options())
    jobs := queuetest.New(client)

    client.WithToken("local-probe-token").
        PostJSON("/api/export", map[string]any{}).
        AssertStatus(202)

    jobs.AssertPushedTimes[ExportReport](1)
    jobs.AssertPushed(func(job queuetest.Job[ExportReport]) bool {
        return job.Job.UserID == 42
    })
}

One setup mistake was instructive. Our first version put auth.Authenticate{} on an API route without supplying an authentication guard. The guest request produced a 500, with an error explaining the missing authentication context. We corrected our test setup to use the documented auth.Via guard, then all three tests passed. The authentication implementation distinguishes supplying identity from checking it. Do not copy a browser middleware example into an API route and assume those responsibilities are interchangeable.

The following diagram separates the tested handoff from the worker behavior that still needs a live integration test.

An export flow separates authentication, queue dispatch for the current user, and a worker, with durable execution marked as a separate test

The test stopped after dispatch. ExportReport.Handle was a no-op, so worker execution, data access and retry behavior still need integration tests. Laravel's queue guide documents the real worker, retries and supported queue connections; those are the next integration boundaries to exercise.

The replies reveal two different buying decisions

The r/golang discussion is sharply divided over whether a full-stack framework brings useful conventions or unnecessary architectural baggage. Several replies challenge the fit with Go's usual approach to composing libraries. Others welcome avoiding repeated application plumbing. Those replies describe design preferences and maintenance concerns.

The r/laravel launch thread raises a different concern: how packages and maintenance will keep up across PHP, Rust and Go. That is a more useful question for a team with a working Laravel application than which language wins a comment-thread benchmark.

X replies provide another audience signal. Abene-zer said the Go release had attracted his attention despite never needing PHP, while Mohammad Emran expressed more excitement for the Go version than the Rust version. Those replies suggest the beta may appeal to Go developers who want Laravel's conventions.

We would try the beta on a contained new service first. For an established PHP product, compare the expected benefit with the cost of rebuilding and verifying working behavior.

How to compare Laravel Go performance fairly

Laravel also published an 18-times-throughput comparison for Laravel Rust against Laravel PHP. The benchmark is specific to Rust and its stated test conditions. Laravel Go needs its own comparison, especially for endpoints dominated by a database query or external API.

For a useful comparison, keep the endpoint's work, database contents, hardware, concurrency and runtime configuration comparable. Record tail latency and failure rate as well as throughput. Include worker memory and restart behavior if the intended improvement is operational. Changing the language while quietly changing the workload produces a persuasive chart and a weak decision.

What to do before you move anything important

Start with one feature that can be evaluated independently. An export, webhook receiver or internal report is a better first experiment than replacing login and billing together.

  1. Pin the experiment. Record the Go version, framework version and dependency lock state. Use the current installation guide to create a disposable application.
  2. Write the behavior checks first. Include a denied request, an allowed request and an assertion about the resulting data or job. Our guide to practical test-driven development explains where this approach helps.
  3. Replace the fixture with real identity. Test your actual credential and session design. Our authentication comparison explains why sessions, bearer tokens and delegated access answer different questions.
  4. Cross the infrastructure boundary. Run a real database and worker, then exercise a retry, a restart and repeated delivery using disposable data. Check that the business action behaves safely when invoked again.
  5. Price the migration work. List missing packages, changed data contracts, deployment changes and the rollback path before estimating a production rewrite.

Choose Go because the resulting application and operating model fit your team. The beta earns a focused experiment. Your existing PHP application's replacement still has to earn its way through the tests.