How to Disable Comments in WordPress

Published on May 9, 2022 by Kevin Graham

Do you feel that comments on your website aren’t contributing to your site’s goals? Maybe you think that your site visitors commenting can do you more harm than good. Don’t worry; you can disable WordPress comments if you aren’t making use of them, and we’ll show you how.

Today we’ll go through step-by-step instructions on how to deactivate comments in WordPress.

In your site’s basic settings, WordPress has tools that make it simple to disable comments. They allow you to deactivate them on individual articles and pages or even your entire site.

Websites That Benefit From a Comments Section

Whether or not to include comments mainly depends on the aim of your website.

Comments on blogs may be beneficial if you want to increase engagement and make your blog a place for communicating with your readers. If it’s important for your website to engage its audience and stimulate debate, a comment section is a must.

A longer dwell time is when visitors spend time on your website, reading and responding to comments. This indicator determines how much time a user spends on a page after arriving there via search engine results.

Why Would You Want to Turn Off WordPress Comments?

An active comments area might help a blog in terms of SEO, but it may harm the majority of other sites that don’t need comments.

It’s bad for your brand and much worse for your SEO when the only comments in the comment field are from automated bots that can:

  • Hack the site using SQL injection
  • Encourage visitors to click links to download malicious content.

Readers commenting on your blog entries may boost engagement and bring additional advantages, but that might not always be the case.

The following are some examples of circumstances when disabling the comments makes sense:

  • You don’t have a blog or you’re creating content in another format (product pages, for example).
  • Your website mainly focuses on distributing information (news) through static content rather than initiating dialogue.
  • You’re the owner of a corporate website, and you’re worried that comments will make your pages look unprofessional.
  • You motivate your readers to participate in conversation outside of your articles and pages in a separate forum.
  • You want to prevent spam and off-topic conversations. While plugins such as wpDiscuz
  • can aid with this, they aren’t always the best option. It makes sense not to integrate them if you can’t devote time to comment moderation.
  • You won’t have to think about spam cluttering your posts.
  • Disabling comments will improve the speed of your site.

Alternatives to completely blocking comments in WordPress include shutting comments after some time or disabling comment URLs. Let’s go over both options.

How to Disable Comments in WordPress

In WordPress, there are several options for disabling comments. The three basic approaches are using WordPress’s built-in settings, a plugin, or custom code.

1. WordPress Built-in Options

If you want to disable comments altogether, you may use the platform’s built-in settings; this option is a simple solution. However, there are certain limits (which we’ll go into). You have two options; to deactivate comments in WordPress for a particular post or page or deactivate comments for your entire website.

  • Option 1: Disable Comments on a Particular Post or Page

Keep in mind that comments are turned off by default on sites. It means you only need to deactivate them on specific pages if you enabled them at some point in the past.

  • To get started, go to the relevant WordPress post or page.
  • After that, have a look at the right-hand sidebar. You’ll notice a Discussion section that you need to head over to.
  • Uncheck the Allow Comments box to turn off comments. Then save or update the page or post, and visitors won’t leave comments anymore.
  • Please bear in mind that this will not delete any previous comments on the page or article. To do so, go to the Comments tab in your WordPress admin and delete them manually.
  • Option 2: Disable Comments Across the Board

What if you’re determined that no one should be able to comment on any of your site’s articles? In this scenario, you’ll want to turn off comments on everything in WordPress.

You can do this by going to Settings > Discussion.

Uncheck the box saying: “Allow people to make comments on new articles.” All future posts on your site will be comment-free.

There are two disadvantages to this strategy:

  • First, it doesn’t remove any existing comments from your site (you’ll still have to delete them manually).
  • Second, this will not prevent comments on existing articles; only new ones will be disabled.

However, there’s a simple way to deal with this.

Locate the “Automatically close comments on articles older than” option on the same page, tick the box, and enter 0 in the field.

All of the comment sections on your existing posts will be closed due to this action. You can disable your comment sections globally when used with the prior setting.

2. WordPress Plugin

The options listed above don’t give you much control over the procedure. You’ll almost certainly have to conduct some tiresome cleanup subsequently. If you want a quicker and smoother solution, a dedicated plugin could be the way to go. A couple of tools can help you disable WordPress comments.

  • Option 1: Download and Install a Free Plugin

Check out these free plugins for how to Disable Comments. Administrators can use this plugin to block comments across the board or for specific post types exclusively. Disable Comments is highly recommended and also simple to use.

After you’ve installed the plugin, go to Settings > Disable Comments.

You’ll see a vast choice of options; you can turn off comments on your whole site with a single click, or you can also disable them for posts, pages, images, or other media assets.

Click the Save Changes button. Remember that allowing comments via the usual WordPress Discussion settings or on specific posts and pages will not override these settings.

  • Option 2: Purchase a High-End Solution

The abovementioned plugin isn’t your only choice for dealing with the comments sections of your WordPress site. You might also think about investing in a premium plugin.

Premium plugins can help you increase the speed of your WordPress site. New improvements include a simplified interface and other behind-the-scenes adjustments to reduce possible clutter and glitches.

Under the Options menu in WordPress, you can select Disable Comments.

You may allow or disable comments altogether by switching this option. If you want to switch off your WordPress comments while simultaneously speeding up your website, this program can take care of both.

3. Custom Code

You can use custom code if you want more control or options but don’t want to add another plugin to your site. Your technical knowledge and skill will restrict what you can accomplish with this method. However, deleting the comments section of your website is a simple process.

You can effectively eliminate the comments area from your WordPress theme using some basic HTML instructions. Keep in mind that altering the source code of your WordPress theme is dangerous and, if done incorrectly, might mess up your site.

Use the following instructions to disable the comments area on all of your site’s pages, erasing all recent comments and preventing any new ones from being posted.

  • With your HTML editor open your page.php file and look for the following code:
<?php comments_template( '', true ); ?>

Replace it with the following code instead:

<!-- Begin Comment

<?php comments_template( '', true ); ?>

End Comment -->
  • To perform the same thing with your site’s posts, go to your single.php file and find the following code:
<?php comments_template(); ?>

Replace it with the following code:

<!-- Begin Comment

<?php comments_template(); ?>

End Comment -->

If necessary, you’ll need to repeat the process for different kinds of posts.

Summary

Let’s review the three techniques for deactivating comments:

  1. WordPress Built-in Options
  • Option 1: Disable Comments on a Particular Post or Page
  • Option 2: Disable Comments Across the Board
  1. WordPress Plugin
  • Option 1: Download and Install a Free Plugin
  • Option 2: Purchase a High-End Solution
  1. Custom Code
  • Disable the Comments Area on All of Your Site’s Pages
  • Disable the Comments Area on All of Your Site’s Posts

Conclusion

An active comments area may boost website engagement and foster a strong community. But, if having comments enabled doesn’t make sense for your website, it’s preferable to turn the option off.

Try a few different things and experiment with your WordPress site to discover which method of disabling your comments is working for you.

Want to speed up your web site?

WP Bolt makes it easy and affordable to have a High Performance WordPress VPS server.

View Pricing & Sign Up Now