How to Disable Comments in WordPress
October 28. 2019
The debate about whether or not you should allow comments on your WordPress website is a long one. Some website owners consider post comments to be a great way for them to interact with their visitors and improve the scope of their business. On the other hand, other website owners simply don’t have enough time to dedicate themselves to responding to dozens of comments on a daily basis. If after weighing over the pros and cons of posts comments you decided to disable them, you came to the right place. Today, we deal with a few different ways that will allow you to quickly and easily disable comments in WordPress. No matter which approach of the three you opt for, the results will be the same – you will say goodbye to comments, which is probably what you have been yearning for recently.
What is there to be gained by deciding to disable comments in WordPress?
Before jumping straight to the matter at hand, we’d first like to tell you that you have not made the wrong decision. Of course, posts comments exist for a reason and they lead to a plethora of good things. But they are also an entryway for security breaches. By disabling comments on your posts and pages, you would prevent spam from reaching your business – at least this part of it. The truth is that there are different spam protection techniques out there, but few of them are as effective as simply disabling comments completely. For us here at WP Full Care, safety is the number one concern, and spam prevention is a very important step that leads to the overall safety of your WP website.
Different ways of disabling comments in WordPress
Lo and behold – if you want to disable comments on your WordPress website, you have not one, not two, but three options for doing it! Which approach you choose will depend on the purpose behind this decision.
- Disable comments by using a plugin.
- Remove and disable comments in WordPress settings.
- Disable WordPress comments with code.
Using a plugin
Perhaps the simplest way to disable comments on your site is by using the Disable Comments plugin. This plugin works by allowing administrators to globally disable comments on all of your posts and pages. And if you have WordPress Multisite activated, this plugin will enable all comments on all of your websites. Pretty handy, right? It sounds perfect, so what could possibly be wrong about it?
Should you use the Disable Comments plugin, you wouldn’t be able to disable the comment section on only a handful of posts. If you are running a network of websites, you also wouldn’t be able to disable them on only one site as opposed to all of them. If you wish to be selective and leave the comment sharing section on some of your content, then we suggest you take a look at the following option.
Disabling comments with WordPress
When you have a WordPress website, there’s no limit as to how much you can achieve. This platform is characterized by its simplicity, and that can be seen when trying to disable or delete comments from your WordPress posts and pages. Depending on your needs, you have a couple of options once you decide that your days of responding to viewer comments are a thing of the past.
You can disable comments on future posts
If you have decided to stop comments altogether on your future posts, all you have to do is go to Settings – Discussion. Here, you will find the ‘Allow people to post comments on new articles’ option and you will simply uncheck it. By clicking SAVE, the disabling process will be done.
You can turn off comments on specific posts or pages
Have you finished making a high-impact landing page and you want to keep it comment-free? Perhaps you wrote a blog article you know is bound to stir some controversy? Then you can turn off comments for only those posts/pages in question. Once you open the ‘Discussion’ option that can be found under ‘Screen Options’, you will be able to turn off and/or ‘not allow comments’ on your posts and pages. The only drawback is that you have to do this for every post individually. But if you chose this option, we guess that’s precisely what you were looking for.
Note: all comments are automatically disabled for pages. But you can have the freedom of enabling or disabling posts/pages comments.
You can disable all comments without using a plugin
Yes, that is possible as well. The process is as follows. First, go to Post – All Posts, select all the posts, choose Edit from the Bulk Actions box and click Apply. From the comments dropdown box, select Do not allow, and then simply click Update. As easy that!
Be careful about disabling comments with code
It’s very important to mention that editing the source code of a WordPress theme is not something to play around with. And anytime you are forced to change the code, you should never edit the parent theme. Instead, make the necessary changes in the custom or child theme. It could break your site if you don’t do it correctly. That’s why we suggest you never opt for this option if you are not confident enough in your skills. On the other hand, if you feel perfectly capable of doing it, here’s what you should do.
Should you wish to disable comments in WordPress, you’ll have to replace the code <?php comments_template( ”, true ); ?> that you will find in the page.php file with the code:
<!-- Begin Comment
<?php comments_template( '', true ); ?>
End Comment -->
That will remove comments from your pages, and you’ll have to repeat a similar procedure if you want to remove it from your posts as well. In the single.php file, find the code <?php comments_template(); ?> and replace it with:
<!-- Begin Comment
<?php comments_template(); ?>
End Comment -->