AI & AutomationFeb 21, 2022
How to Manage Autosave in WordPress
WordPress automatically saves your posts/pages at certain intervals. You are likely familiar with this from Word or OpenOffice. This feature is designed to ensure that if there is a connection interruption or a crash of your computer, not all data is lost.
Adjusting Autosave in WordPress
You can set the interval at which backups are made yourself. To do this, open the wp-config.php of your WordPress instance with an editor (e.g., Notepad++) and add the following line:
define('AUTOSAVE_INTERVAL', 300);
The 300 stands for the seconds that must pass to perform a save. In our case, that would be 5 minutes. You can enter any value here.
Disabling Autosave in WordPress
The autosave feature can be disabled in WordPress by removing the corresponding script. To do this, open the functions.php file located in your theme's directory. Add the following code snippet to the file:
add_action( 'admin_init', 'disable_autosave' );
function disable_autosave() {
wp_deregister_script( 'autosave' );
}
Now the automatic saving should be prevented.
Conclusion
WordPress is very flexible and allows you to define almost all settings according to your preferences. As a WordPress agency, we deal daily with the various configuration options. If you have any questions, feel free to contact us.