Support » Fixing WordPress » The response is not a valid JSON response.

  • Resolved digipuneet

    (@digipuneet)


    My website is running fine since I have installed WordPress. But from two days, I am unable to post anything or update anything on my website.
    Every time, I am getting the error:
    When posting:
    Publishing failed. The response is not a valid JSON response.

    Also the plugin Google Site Kit is showing this Error:
    Data Error. The response is not a valid JSON response.

    Please Help.

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    This may be a plugin or theme conflict. Please attempt to disable all plugins, and switch to the default Twenty Twenty-One theme. If the problem goes away, enable them one by one to identify the source of the problem.

    If you can install plugins, install Health Check. On the troubleshooting tab, you can click the button to disable all plugins and change the theme for you, while you’re still logged in, without affecting normal visitors to your site.

    Thread Starter digipuneet

    (@digipuneet)

    Hi @macmanx Thanks for the Response.

    I have tried everything that you’ve suggested. But the problem remains same.

    And, After installing Health Check, I am getting an improvement suggestion i.e. REST API encountered an unexpected result

    For your reference: https://prnt.sc/1e54rco

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    Ok, try downloading WordPress again, access your server via SFTP or FTP, or a file manager in your hosting account’s control panel (consult your hosting provider’s documentation for specifics on these), and delete then replace your copies of everything on the server except the wp-config.php file and the /wp-content/ directory with fresh copies from the download. This will effectively replace all of your core files without damaging your content and settings.

    Some uploaders tend to be unreliable when overwriting files, so don’t forget to delete the original files before replacing them.

    Thread Starter digipuneet

    (@digipuneet)

    Thanks @macmanx
    The issue has been resolved.
    There was an error in my .htaccess file. I have just installed a fresh .htaccess file and everything is good now. 🙂

    # BEGIN WordPress

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ – [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    # END WordPress`

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘The response is not a valid JSON response.’ is closed to new replies.