When users install an SSL certificate on their site, the entire content should automatically move to HTTPS instead of HTTP; however, sometimes the site still runs on HTTP/HTTPS instead of only HTTPS. This might result in loading the asset properly on the site. This is one of the most common SSL certificate errors while working with WordPress sites. In this document, you will find the most common ways to fix this issue.
Contact the Hosting Providers
The very first option is to contact your hosting providers and inquire about the SSL if it was properly installed. In most of the cases, the hosting provider fails to install the SSL certificate properly which results in this issue. If the hosting provider confirms that the SSL certificate is properly installed, you can follow the steps below to perform a quick fix.
Take a backup
Before you make any changes to your website, it is recommended to take a backup of the site; so that if things go south, you can always restore the settings from the backup. Here is an article that will guide you through on taking a backup of your website.
Once you have successfully taken a backup of your website, please follow these steps.
- Step 1 : Login at your WordPress Dashboard
- Step 2: Download and install the plugin called Better Search & Replace
Step 3: Run Better Search by navigating to Tools>Better Search and Replace
Step 4: Replace on the old site URL for the new site URL
- Step 5: Delete the site_url constant you may have added to wp-config.php
- Step 6: You may also need to regenerate your .htaccess by going to Settings > Permalinks and saving the settings
Note: It is also recommended that you run the plugin at first as a Dry Run, to then Live.