Did you read any articles they have, like:
https://devcenter.heroku.com/articles/getting-started-with-laravel
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
I just create laravel app with staterkit (breeze) and i am using (react) inertiajs. I pushed the code to Heroku, it's showing error 419 while register and login. I haven't even started coding. I setup all environment variables on heroku. I try same thing with blade files, but it's working perfectly. How I can push and configure environment variable correctly. Error: 419
@Bilal_swl You should be configuring the trusted proxies to correctly detect HTTPS instead.
Docs: https://laravel.com/docs/10.x/requests#configuring-trusted-proxies
class TrustProxies extends Middleware
{
protected $proxies = '*';
protected $headers = Request::HEADER_X_FORWARDED_AWS_ELB;
}
Docs: https://laravel.com/docs/11.x/requests#configuring-trusted-proxies
->withMiddleware(function (Middleware $middleware) {
$middleware->trustProxies(
at: '*',
headers: Request::HEADER_X_FORWARDED_AWS_ELB,
);
})
Please or to participate in this conversation.