Can’t center post thumbnail with bootstrap

I really don’t understand why this thumbnail can’t be in the center ? I’ve tried with margin: 0 auto, trying to use col-md-... but nothing works.

Can someone help ?

Thank you

<div id="primary" class="content-area">
    <main id="main" class="site-main container" role="main">
        <div class="row">
            <div class="col-md-6 col-centered">
        <?php the_post_thumbnail('thumbnail'); ?>
    <div class="row">
        <div class="col-md-10 col-xs-12 col-centered">
    while ( have_posts() ) : the_post();

        get_template_part( 'template-parts/content', get_post_format() );

    endwhile; // End of the loop.


.col-centered {
float: none;
margin: 0 auto;


img {
margin: 0 auto;

Read more here: Can’t center post thumbnail with bootstrap

Leave a Reply

Your email address will not be published. Required fields are marked *