How to Fix “The response is not a valid JSON response” Error in WordPress

How to Fix “The response is not a valid JSON response” Error in WordPress

I faced this issue once I get the HTTPS for my domain. Recently I added an SSL certificate to my site using the free version of Cloudflare. After that, I was not able to add new pages or add new posts to my Word Press site. When I was trying I got an error like “The response is not a valid JSON response”. The reason behind this is “Mixed content error due to the use of SSL certificate”.

I can suspect that happens because of your SSL (Security Socket Layer) on your WP website (HTTPS). It may happen some of content deliver through a secure manner (HTTPS) and other content deliver non security HTTP protocol.

This happens when both contents (HTTPS & HTTP) transmit the same time to your web browser. avoid that I used a plugin called “Really Simple SSL “.,
more than 40 million users are using this plugin.

To fix the issue, go to Settings > SSL. This will open the plugin’s settings. Now click on the Settings tab.

SSL | WordPress | Json Error
SSL | WordPress | Json Error

Now you have to make sure below options are turn on if not please turn on.

  1. Mixed content fixer – It is preventing the mixed content issue.
  2. Use an alternative method to fix mixed content – This will ensure that “the response is not a valid JSON response”

After saving, you won’t be able to see an error like “the response is not a valid JSON response”. You can create new posts and pages once you follow the instructions correctly.