Afficher conditionnellement l’image mise en avant sur les pages et articles uniques.


Important notice

If your theme does a customized call to load the featured image (like the Twenty Seventeen theme), this plugin might not work! Use get_the_post_thumbnail() or wp_get_attachment_image() to be sure it will work.


This plugin lets you choose for each post or page, if the featured image should be shown in the single view. This can get handy, if you use the featured image to show a thumbnail on the archives or front page but you don\’t want the featured image to be shown on every posts view itself.

The plugin adds a simple checkbox to the featured image panel (or meta box if you are using the classic editor), that lets you choose, if the featured image will be shown in the singular view or not.

Captures d’écran

  • Administration
  • Frontend


  1. Upload the plugin files to the /wp-content/plugins/conditional-featured-image directory, or install the plugin through the WordPress plugins screen directly.
  2. Activate the plugin through the Plugins screen in WordPress


The plugin doesn’t work with my theme. What can I do?


  • kindly ask the theme developer to use one of the dedicated WordPress functions (wp_get_attachment_image(), get_the_post_thumbnail(), the_post_thumbnail()) to load the featured image in the singular views.
  • or create a child theme that replaces the call, that loads the featured image, with one of the methods listed above.

Can I limit this plugin to posts (and exclude other post types)?

Yes. By default, the plugin is available on any post type, that has a featured image. But there is a filter, that lets you control, for with post types the plugin should be available. The following example limits it to posts only:

function enable_conditionally_featured_image_plugin_by_post_type( $post_type ) {
    return 'post' === $post_type;
add_filter( 'cybocfi_post_type', 'enable_conditionally_featured_image_plugin_by_post_type' );

The filter provides you the current post type and you can decide if you want to use the plugin for this post type by returning true to enable and false to disable it. Add the following snippet to your functions.php to enable the plugin for posts and pages, but disable it for any other post type:

function enable_conditionally_featured_image_plugin_by_post_type( $post_type ) {
    $allowed_post_types = array( 'post', 'page' ); // add any post type you want to use the plugin with
    return in_array( $post_type, $allowed_post_types );
add_filter( 'cybocfi_post_type', 'enable_conditionally_featured_image_plugin_by_post_type' );

Is it possible to get the plugin in my language?

Absolutely. You’re invited to contribute a translation in your language. Please keep in mind, that the translation needs to be reviewed by the community, so it will take a little while until it gets accepted.

How can I change the text of the checkbox?

There is a filter hook for this. Add the following snippet to your functions.php:

function change_conditionally_featured_image_label( $label ) {
    return 'Hide featured image in post'; // change this string
add_filter( 'cibocfi_checkbox_label', 'change_conditionally_featured_image_label' );


26 juin 2020
It took me a while to find a solution to hide singular images from my posts - This Plugin Works absolutely great and is easy to use.
26 mars 2020
It works great, but it not only removes the main featured image that is added automatically by wordpress, but also removes/hides the featured image inside any component from the post, such as Single Image from WPBakery Composer. Anyway, I managed to solve it by manually choosing an image from the gallery on that Single Image WPBakery Composer component, instead using the "featured image" option.
3 février 2020
Thank you very much, this plugin is essential for many themes, I hope it will be maintained for a long time.
19 février 2019
This was the last missing piece in putting together my WP website the way I had it pictured. I need the featured image thumbnail on my page-list links but not at the top of the actual page. The plugin took care of that in 30 seconds flat. And I don't know why the warning about not working with Gutenberg. For me it works exactly as intended on WP 5.0.3 with pages containing Gutenberg paragraph blocks.
Lire les 12 avis

Contributeurs & développeurs

« Afficher conditionnellement l’image mise en avant sur les pages et articles uniques. » est un logiciel libre. Les personnes suivantes ont contribué à cette extension.


“Afficher conditionnellement l’image mise en avant sur les pages et articles uniques.” a été traduit dans 2 locales. Remerciez l’équipe de traduction pour ses contributions.

Traduisez « Afficher conditionnellement l’image mise en avant sur les pages et articles uniques. » dans votre langue.

Le développement vous intéresse ?

Parcourir le code, consulter le SVN dépôt, ou s’inscrire au journal de développement par RSS.



  • Tested up to WordPress 5.5 (RC1)
  • Extended FAQ
  • Updated dependencies


  • Allow to enable/disable the plugin by post type


  • Allow filtering the featured image checkbox label
  • Update readme
  • Update dependencies


  • Exclude none essential data from SVN


  • Update dependencies


  • Add support for Yoast SEO (don’t filter image for the social header data)


  • Add support for the block editor (Gutenberg)
  • Tested up to WordPress 5.2.2


  • Makes sure, we do only modify the main post
  • Tested up to WordPress 5.0.0


  • Make it more robust so it will also work with Elementor
  • Tested up to WordPress 4.9.6


  • Tested up to WordPress 4.7.3
  • Tested up to WordPress 4.8.0
  • Tested up to WordPress 4.9.0


  • Tested up to WordPress 4.7.2


  • Get ready for language packs (set text domain equal to the name of the plugins folder, remove load_plugin_textdomain)


  • Tested up to WordPress 4.7.0
  • Removed language folder. Languages are now loaded from


  • Improve plugin title
  • Improve checkbox string
  • Improve documentation
  • Updated stable tag


  • Updated stable tag


  • Extended functionality to pages


  • Initial public release