Avoid Accidental Publishing in WordPress

Last Updated on

Sometimes we accidentally hit the publish button when our post or page is incomplete or not ready to publish. Many bloggers and site owners set up automatic processes to send email to their subscribers and share posts on social media.

Accidental publishing is problematic because your posts can get shared and sent to email subscribers when you hit the publish button.

Avoid Accidental Publishing

However, if an incomplete post or page goes live, then it is a bit embarrassing and you have to unpublish it.

Unpublishing the post or page means your users will see a 404 error when they click on links in their email or social media stream.

That’s why we need to stop Accidental Publishing in WordPress.

In this article, I will show you how to easily avoid accidental publishing in WordPress.

The first thing you need to do is install and activate the Publish Confirm plugin.

Now when you hit the publish button in WordPress, you will see a popup asking if you really want to publish the post.

Avoid Accidental Publishing Confirm

The plugin works for all posts and pages as well as custom post types.

You can also change the message displayed in the confirmation popup.

You will need to add the following code to your theme’s functions.php file

function my_custom_msg() { 

return "Is it ready to Publish?";


1 Star2 Stars3 Stars4 Stars5 Stars (2 votes, average: 5.00 out of 5)

Leave a Reply

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

More in Blogging, Wordpress, Wordpress Plugins
Disallowed Wordpress Plugins
A List of Disallowed WordPress Plugins You CAN’T Use

If your website is running on WordPress or You are a WordPress developer, you need many plugins to add functionalities