Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

ErikRobles's avatar

Laravel 8 blank page private hosting Linux, php 7.4

Seen many posts on white screen on deploy of Laravel but nothing that I have found has worked. I have Linux with php version 7.4 and mysql 8.0.29. The directory I am shooting for is /var/www/html/ From here I tried simply uploading all the files and then changing the .env file to correspond to the db info. I am using the APP_URL as the live site. What additional steps need to be taken to get the application up and running? I do not have SSH access by the way. Any help on this would be greatly appreciated. Thank you. PS. Here is my .env passwords removed:

APP_NAME=AttendanceTrack
APP_ENV=production
APP_KEY=base64:jZwZ6oGTAAnm1Q1QAU6Q/dnOdx0T1+i5FdzzSpizh6I=
APP_DEBUG=true
APP_URL=http://lionsfield.com.mx
LOG_CHANNEL=stack
LOG_LEVEL=debug

DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=attendancetrack
DB_USERNAME=adminuno
DB_PASSWORD=MYSECRETPASSWORD

BROADCAST_DRIVER=log
CACHE_DRIVER=file
FILESYSTEM_DRIVER=local
QUEUE_CONNECTION=sync
SESSION_DRIVER=database
SESSION_LIFETIME=120

Will generate a new key after posting this

0 likes
10 replies
Snapey's avatar

first thing you need to know is which folder is the website serving ? Ask your provider.

(better still get a host that allows command line access)

ErikRobles's avatar

@Snapey You know how it is. Cheap for my boss and I have to pay the price. I was told by the person who set up the server that html is where the site is served from.

Snapey's avatar

As you know this is not ideal. Upload the laravel project to var/www and tell the person that setup the server that they need to serve the public folder.

ErikRobles's avatar

@Snapey Yeah the whole thing is pretty crappy. The server doesn't even have a public folder.

Snapey's avatar

@ErikRobles it will when you upload your project. The server admin can make the html folder into a symlink that points to your public folder and then everyone is happy.

jlrdw's avatar

@ErikRobles are you positive you don't have SSH ability? But you could get all setup locally as though it was live and upload a working site.

But no matter, make sure to point to public as document root.

See: https://laravel.com/docs/9.x/deployment#main-content

Take note of the Nginx example in that chapter. Usually a wrong setup (folder structure) is the problem.

ErikRobles's avatar

Thank you @jlrdw I pushed the issue and insisted on ssh access and now I have it. Still have a white screen but I believe a symlink is the answer like @snapey mentioned above

ErikRobles's avatar

@Snapey If I had to create the symlink file, what would it look like and where would I place it? I have the following just guessing but something like this...

<?php 
symlink('/storage/app/public', '/html/storage');
Snapey's avatar

@ErikRobles i'm not talking about the storage symlink

and why would you do it this way if you have command line access?

i'm talking about making html point to the public folder

have you uploaded your project? is html folder empty?

Snapey's avatar

white screen can also be caused by lack of write permissions on the storage folder

1 like

Please or to participate in this conversation.