Fix HTTPS issue in the Statamic 3 Control Panel

Published on July 29th, 2020.

In the past, I've had issues when trying to use the Statamic Control Panel alongside using HTTPS. Usually, you'll get issues like the JS & CSS not loading or requests to the CP's API not working properly.

The good thing is.... it's an easy fix.

In the site's AppServiceProvider class (app/Providers/AppServiceProvider.php), add this into the register method:


If you only want it to apply while in production you could add a little environment check like so:

if (app()->environment() === 'production') {

Hopefully that should sort the issues you're having!

My picture

Duncan McClean