How to Add Author Bio on Each Blog Post

Many of the themes today come with author bio pre-installed but some do not; and in that case you can get one either by installing a plugin or by hard coding the author bio section in your theme’s single post page. Most of the bloggers go for the plugin option since it’s the easier one. But if you think you already have a lot of plugins and do not want to add one more to the list, here is how to get it done through coding. Ah it too is not that difficult either.

So, to have a small author bio section just below your post :

1. Log in to your WordPress admin panel

2. Navigate To Appearance >> Editor

3. The page which appears before you once you navigate to above location is the CSS file of your site; or in simple words, it’s the file where your site’s design lies. Scroll to the last line of the page hit enter to create a space and then put this small piece of code there (in your Style.css file):

border:2px solid #CECFD0;
margin:0 auto;
margin-top: 5px;
#authorbox h4{
padding:5px 10px 5px 10px;
#authorbox img{
#authorbox p{
padding:0px 10px 10px 10px;
#authorbox h4 > a{
#authorbox p{

4. Once you are done with pasting the above code in the Style.css file, search for the page called single.php. Open it and get to the desired location where you want the author bio to appear and then paste the below given code there:

<div id=”authorbox”>
<?php if (function_exists(‘get_avatar’)) { echo get_avatar( get_the_author_email(), ’80’ ); }?>
<div class=”authortext”>
<h4>About <a href=”<?php the_author_url(); ?>”>
<?php the_author_firstname(); ?> <?php the_author_lastname(); ?></a></h4>
<p><?php the_author_description(); ?>. <?php the_author_firstname(); ?> has written <strong><?php the_author_posts(); ?></strong> awesome articles for <?php bloginfo(‘name’); ?>, See all the posts written by <?php the_author_posts_link(); ?>.</p>

Note : If you are not able to decide where to place the code, then place the above code just below the following code in your single.php file (This will make your author bio appear just below your post):

<?php if (function_exists(‘digg_this_button’)) { ?><div style=”float: left;”><?php digg_this_button(); ?></div><?php } ?>
<?php the_content(‘<span>Continue Reading</span>’); ?>
<!– google_ad_section_end –>
<?php wp_link_pages(‘before=<div id=”page-links”>&after=</div>’); ?>

Now, save the changes to the single.php file and clear your browser cache; its time for a site preview. Go to a post and you should find your author bio appearing there.

Speak Your Mind


This site uses Akismet to reduce spam. Learn how your comment data is processed.