Supprimez le champ du site Web du formulaire de commentaire pour ARRÊTER le spam (Méthode facile)

Désactiver l'URL du site Web du formulaire de commentaire

As any blogger knows, comment spam can seriously detract from the user experience on a WordPress site.

Not only does it clutter up otherwise valuable discussions, but it can also negatively impact your site’s reputation if left unchecked.

While there are plugins that help filter spam comments automatically (Like Akismet), one of the most effective tactics is to remove the unnecessary website field from your comment form, that spam bots commonly target.

Why Remove the Website Field from the Comment Form?

The “websitefield is included by default on WordPress comment forms. Malheureusement, this field provides little value for legitimate commenters while giving spam bots an easy place to populate with garbage links. Removing it can cut down on a major point of entry for spam.

Comment SPAMwas a popular method for bots to insert backlinks to shady websites back in the day. toutefois, even today, there is still a huge amount of comment spam being generated.

And even though WordPress now understands this and filters the spam comments pretty successfully. They are still stored in your database.

The Easiest way to Remove the Website field from the Comment Form (with a free plugin)

You can add code to your functions.php file or use a plugin that will insert it automatically for you. While all these methods work, I found one useful plugin that I was using already, that can do this very easily.

Removing the Website Field from the Comment Form with WPCode Lite plugin

WPCode Lite is a free plugin with multiple useful options. The plugin was previously known as “Insert Headers and Footersand it has 2+ million active installations.

This is a very powerful plugin that can help you in many ways. But now let’s focus on removing the website field from the comments form.

After you install and activate WPCode Lite, you’ll see the new menu called “Code Snippets”, or simply find the plugin in your Plugins list and click on “Code Snippets

WPCode Lite "Code Snippets"

Click the “+ Add Snippetand you’ll see a library of pre-made snippets. They are separated in categories. What we need now is the “Commentscategory.

Remove Website Field from the Comment Form with WPCode Lite

You’ll see the snippet calledDésactiver l'URL du site Web du formulaire de commentaire. Now we just need to activate it and set some additional rules.

To use this free snippet you’ll need to register a free account and connect to the library. This takes just a few seconds and a simple registration form.

Par défaut, the snippet will run everywhere. Since it only applies to the comments form on the post pages, we can change the location to Page-Specific.

I choose “Insert After Postand it works as expected for me.

This is it!

Check your Comment form now in incognito mode (or make sure you are logged out) to see if it works as it should.

Download WPCode

résultat financier

Removing unnecessary form fields slashes an easy spam entry point without negatively impacting the user experience for real commenters. By leveraging a plugin like WPCode Lite, you can craft an optimized comment form that welcomes engagement while blocking a major flow of spam. Keep your discussions on track and your site’s reputation strong through these simple spam-prevention tactics.

Let me know if you need any other tips for fighting comment spam or optimizing the user experience on your WordPress site. Reducing friction for genuine users while complicating things for bots is key.

Divulgation: Certains des liens sur la page peuvent contenir un code de référence (liens d'affiliation), qui dit à l'autre côté que nous vous avons envoyé. Si vous avez aimé ce que nous suggérons et que vous effectuez un achat, nous pouvons recevoir une commission.

Daniel Adamo
Daniel est un créateur de contenu spécialisé dans les thèmes et plugins WordPress. Il rédige des guides et tutoriels détaillés pour aider les débutants et les professionnels à tirer le meilleur parti de WordPress.. Pendant son temps libre, Daniel agit comme bénévole pour des organismes à but non lucratif. Il estime que les plateformes open source comme WordPress sont des outils importants pour renforcer les causes et les communautés du monde entier..