Avatar ·

Error "No Application Encryption Key Has Been Specified" in Laravel: causes and solution

Hello everyone! I'm new to Laravel and PHP, trying to deploy my first project on a local OpenServer. I installed Laravel 5 via Composer, everything went successfully. But when I go to the site in the browser, I only see a white page with an error: RuntimeException No application encryption key has been specified. Here is my code from the `config/app.php` file (I didn't change it, everything is default): 'key' => env('APP_KEY'), 'cipher' => 'AES-256-CBC', I checked the `.env` file — it exists, but there is no `APP_KEY` line at all. I tried to manually add a key, but I don't know what format it should be. I tried copying some key from the internet — it didn't help. I also noticed that the `storage` folder doesn't have write permissions, but I set 777 via console.