Ffile2fix
Sign in Get started

How to fix "Updating failed" in the WordPress block editor

Updating failed. You are probably offline.

The block editor tried to save your post through the REST API and the request failed. The text after 'Updating failed.' tells you where: the request never completed (offline), the database rejected the write, or a permission or nonce check failed.

Also appears as: Updating failed. · Updating failed. Could not update post in the database. · Updating failed. Sorry, you are not allowed to edit this post.

Common causes

  • The save request timed out or was dropped (flaky connection, slow server, PHP timeout) - 'You are probably offline'
  • A database error such as emoji in a non-utf8mb4 table, a full disk or a crashed wp_posts table - 'Could not update post in the database'
  • The login session or REST nonce expired while the editor was open
  • A firewall returning 403 for specific post content
  • A plugin hooked on save_post throwing a fatal error

How to fix it

  1. Copy your content first. Select all blocks and copy them, or use the Code editor view to copy the raw markup, so nothing is lost while you troubleshoot.
  2. Read the full message and network response. In DevTools > Network find the failed /wp-json/wp/v2/posts/<id> request. A timeout, 403, 500 or JSON error code each point to a different cause.
  3. For 'Could not update post in the database'. Check the database error in debug.log (enable WP_DEBUG_LOG). Common fixes are converting tables to utf8mb4 for emoji, repairing wp_posts, or freeing disk space.
  4. For 'You are probably offline'. Check the server error log for PHP timeouts or 5xx errors at that time. Raise max_execution_time or fix the slow save_post hook; disable plugins to find it.
  5. Refresh your session. Reload the editor (WordPress keeps an autosave or local backup) or log in again if prompted; an expired nonce makes saves fail with 403.
  6. Check for WAF blocks. If saving fails only with certain content (SQL, script tags, code samples), ask your host which ModSecurity rule blocked it.

Check table charset (SQL, adjust prefix)

SELECT TABLE_NAME, TABLE_COLLATION
FROM information_schema.TABLES
WHERE TABLE_SCHEMA = DATABASE()
  AND TABLE_NAME LIKE 'wp\_%';

CHECK TABLE wp_posts;

How to stop it happening again

  • Keep tables on utf8mb4 so emoji and special characters save
  • Keep heavy work out of save_post hooks or run it asynchronously
  • Save drafts frequently on long posts

Frequently asked questions

I'm definitely online. Why does it say I'm offline?

The editor shows that message whenever the save request fails without a usable response, including server timeouts and dropped connections. It is a generic network failure, not a statement about your internet.

Did I lose my post?

Usually not. WordPress stores autosaves and the editor keeps a browser-local backup; when you reopen the post it offers to restore it.

How is this different from 'The response is not a valid JSON response'?

That variant means the server replied with non-JSON content, usually a REST routing or URL issue. The variants here mean the request failed or was rejected for a known reason.