Knowing how to disable comments on WordPress is definitely a worthwhile option to have.
Once you enable the comment section on your WordPress site, chances are you might get one of these two outcomes, out of the many options possible – civil conversation, and healthy interaction with your followers or being spammed by bots.
Fortunately, it can be disabled according to your preferences. It’s possible to disable comments on certain posts, future posts, and even completely disable all comments on your website.
If you feel like you don’t really need the comment section, why not try to disable it?
In this article, I will tell why you should disable the comment section on your WordPress site and guide you through the process using various ways.
Why Disable Comments on WordPress?
Disabling comments can be very beneficial to your WordPress site.
Every comment appearing on your webpage requires database loading requests, so it increases loading time. Therefore, disabling the comment section results in fewer database queries that can slightly speed up a site.
Moreover, if you run a static website that does not really require any user interactions or a social aspect, you might not need a comment section on your site. So, disabling comments can help your website run according to its purpose.
Importantly, if your site’s traffic is pretty high and you are receiving constant comments, chances are your site might be a prime target for spam. So, disabling comments can protect your site, while you direct the conversation to another channel.
How to Disable Comments on WordPress?
WordPress has a built-in comment section by default, so you will be able to enable or disable comments through the WordPress dashboard. You can either personalize the discussion settings tab or screen options tab, manually input code, or just use a plugin.
Method 1 – Using The Discussion Settings Tab
Simply navigate to your Dashboard and go to Settings -> Discussion. On this page, you can disable comments for your future posts. Just uncheck the box “Allow people to post comments on new articles” and users will not be able to leave any comments on all future posts.
You can still enable comments on certain posts or pages by customizing the “Other comment settings” section.
Method 2 – Using The Screen Options Tab
You can also disable comments via the Screen Options tab. Just head over to Posts on your WordPress admin area. Find the Screen Options tab in the top-right corner of the page.
First, make sure that you tick the “Comment” box so that you have access to control comments.
Click “Apply” to start customizing the comments section.
Then, you can simply disable comment by ticking the posts that you want to customize – either choosing some of them or all of them. Make sure that you choose the Bulk Edit Action to get this customization tab below the Screen Options tab:
Just select “Do not allow” on the comment section and “Update” the changes to disable the comments on the posts you’ve selected. You can perform the same action to control the comments on Pages.
Method 3 – Using Code to Disable Comments on WordPress
Another option to disable comments is by editing HTML code. This may be riskier as you need to use an FTP client to access your site’s files. If you don’t do it correctly, this may harm your site. For this task, I recommend using FileZilla.
If you want to disable comment on pages, head over to your page.php file, and find this code:
<?php comments_template( '', true );?>
Then, comment by bracketing it with
<!-- code -->
The end result should look like this:
<!-- <?php comments_template( '', true ); ?> -->
To disable comments on your posts, open the single.php file. Find and comment on this code:
<?php comments_template( ); ?>
So, it will look like this:
<!-- <?php comments_template( ); ?> -->
This code will remove the comment section from your WordPress theme.
Method 4 – Using a Plugin
You can also disable WordPress comments globally by using the Disable Comments Plugin. This plugin allows you to disable and even remove the comments on any WordPress feature – such as posts, pages, and media – with a single click.
Simply install and activate the plugin, then go to Settings -> Disable Comments. Choose the options that you want: click “Everywhere” if you want to disable all comments on your website, and click “On certain post types” if you want to disable comments on certain post types.
Here is an example of how to disable comments on all posts.
Click “Save Changes” and there you go.
Keep in mind that this plugin can’t individually disable comments on a certain post or page.
Conclusion
WordPress has an in-built comment section, that can be disabled in a couple of ways.
If you want to easily manage it, I recommend using the Disable Comments Plugin. But, if you want to do a little customization, just disable it from the Discussion Settings or Screen Options tab. You can also disable the comment by modifying your page.php and single.php file through an FTP client.
Leave a Reply