Skip to content

How To Disable WordPress AutoSave

When editing a post in WordPress, everything you write on the white canvas & all the changes you make are automatically saved ever 60 seconds. All of your changes are saved as Post Revisions in your database. However, you can disable WordPress’ AutoSave feature with any of these following tricks.

By editing the functions.php file or adding a code snippet

Time needed: 5 minutes.

While there are multiple solutions to disabling WordPress auto-saving feature, I recommend adding this code snippet to your website (either to your functions.php file or through the Code Snippets plugin). It is by far the safest and least technical solution to implement, you do not have to use FTP or risk of breaking your website if you make any mistakes.

  1. Copy-paste the code snippet below.

    add_action( 'admin_init', 'disable_autosave' );
    function disable_autosave() {
    wp_deregister_script( 'autosave' );
    }

By Editing wp-config.php file

The is the most famous trick to disable the AutoSave feature in WordPress. Let me explain this snippet to you – this snippet will set the WordPress AutoSave interval to 86,400 seconds which is an entire day. In this way, WordPress will save a revision of your post after an entire day.

Just add following snippet to your wp-config.php file:

define('AUTOSAVE_INTERVAL', 86400);

There are downsides with editing the wp-config.php:

  • You will require FTP access to your website
  • Code syntax errors or other mistakes in your wp-config.php file will break your website. Make sure to back up this file first.

Leave a Reply

Your email address will not be published. Required fields are marked *