Is secure connection error annoying you constantly on WordPress? It is a common error on WordPress and it usually takes place when it comes to update or install a WordPress theme or plugin from the official directory of WordPress.org. In this post, we are going to show the reason behind this error and how to fix secure connection error.
You may also want to try with RTL themes to get started with RTL on WordPress.
Causes behind “Unable to Establish Secure Connection” Error
WordPress is backed by in-built system for managing its updates. It checks for updates on regular basis and displays notification to install theme/plugin updates. However, it should connect to WordPress.org site to look for updates and to install them. Because of some WordPress hosting server error, your website may not be able to connect with directory of WordPress.org.
You would also want to check out our new guide on how to feature weather forecast on WordPress.
How to Fix Secure Connection Error?
There are different options to resolve the unwanted secure connection error in your WordPress. Here are some of the solutions to try as per your situation –
Server and Hosting based Issues
If your shared hosting server has been attacked by DDoS, there are chances that WordPress.org connection will time out and cause a secure error. Here, you can wait for minutes and try again. If the error continues, you may want to reach out to the support team of web hosting company.
Make price calculations even easier on your WordPress with cost calculator plugin.
VPS or Cloud Server Connectivity Problem
If you are on VPS hosting or cloud server, there are chances that your server cannot connect to WordPress.org because of some DNS conflicts. In that case, your server can be pointed to WordPress.org servers directly. You will want to connect to the server with SSH. SSH refers to secure shell, an encrypted protocol which enables you to connect using command line tools. A tool named PuTTy can be used by Windows users and terminal app can be used by Mac/Linux users.
For the account, login credentials will be required with shell access to your hosting. You can get this info from the cPanel dashboard of your hosting account or ask your hosting server provider.
You may connect to your server in the terminal like –
Be sure to use your own username as well as example.com to replace username with your official domain name. You have to run this command once connected –
sudo nano /etc/hosts
Now it will open a file and you can add this code at the bottom –
Now save changes and exit the editor. To check if the error is resolved, visit your website.
Fixing Secure Connection Error on Localhost
If you are running WordPress on localhost (your own PC), then PHP may not have cURL extension enabled. It is needed to open WordPress.org for updates. You will want to edit php.ini file on your PC. Usually it is located in PHP folder of Xampp, Mamp, or WAMP folder. Look for the line below if you are on Windows PC –
If you are using Linux or Mac, look for this line
Now remove the semicolon before text to enable extension. Be sure to save the php.ini file. Also restart the Apache server to save changes.