Support » Localhost Installs » ERROR Updating failed. Error message: The response is not a valid JSON response.

  • Resolved meriellloyd

    (@meriellloyd)


    When trying to update a post or page on local dev site i keep getting this error “Updating failed. Error message: The response is not a valid JSON response.”

    Doesn’t happen on live site.

    I have run Health Check & Troubleshooting mode but still get the error so it’s not a theme or plugin issue.

    I DON’T get the error when running the Classic Editor plugin. I prefer the new block editor so would like to fix this issue than rather just avoid it.

    Any help/tips would be greatly appreciated.

    Many thanks,

    • This topic was modified 1 month, 3 weeks ago by James Huff. Reason: moved to Locahost Installs forum
Viewing 15 replies - 1 through 15 (of 24 total)
  • Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    What errors are reported at Tools > Site Health in your site’s Dashboard?

    Hi James,

    These are the errors below…

    You should remove inactive plugins Security
    You should remove inactive themes Security
    Your site does not use HTTPS Security
    The REST API encountered an unexpected result Performance

    I found a solution although I don’t think its the correct method.

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    The REST API encountered an unexpected result

    Yep, that’s the problem.

    Are you sure that you aren’t using any plugins to block the REST API?

    Yes, it’s so strange. I have disabled all the plugins and used the default twenty seventeen theme and I was still getting it.

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    Were you at any point though using a plugin to disable the REST API, or a caching plugin?

    I’m not sure honestly. I’m very new to WordPress so I wouldn’t know. How do I know is REST API was disabled by a previous plugin? Is there a simple way to check other that the tool health check?

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    What plugins are you using?

    Currently active

    CoBlocks
    Health Check & Troubleshooting
    WooCommerce Blocks
    Zakra Pro

    NOT active
    Akismet Anti-Spam
    Classic Editor
    Duplicator
    Hello Dolly
    ThemeGrill Demo Importer
    WooCommerce
    WordPress Importer
    WP Mail SMTP
    WPForms Lite
    Yoast SEO

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    Yeah, none of those should do that.

    Are you running any server-side security, like mod_security, or security reverse proxies, like Cloudflare or Sucuri?

    Not that I’m aware of no.

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    Ok, have you contacted your hosting provider about this?

    Something is blocking the REST API, and maybe they can she some light on what, or temporarily switch off mod_rewrite if that’s running.

    I’m running my site in local dev. How do I switch of mod-rewrite (sorry i’m a total newbie)

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    Oh! Well you’re asking in the wrong place then. 🙂

    I’ve moved this over to the Localhost Installs forum so you can get help from the folks with more experience running local servers.

    Oh gosh!! sorry!! Thanks for all your help anyway 🙂

    adding the cloudflare wordpress plugin fixed the issue for me.

Viewing 15 replies - 1 through 15 (of 24 total)
  • You must be logged in to reply to this topic.