I just want to add author gravatar near the name of the author. I know that I have to add something in the single.php file, but what to add? Thanks!

2 Answers 2


If you're in the Loop:

echo get_avatar( get_the_author_meta('ID') );

  • It worked just fine!
    – user385917
    Aug 10, 2011 at 17:20

Plenty of info on WP Codex on Gravatar's.

use: get_avatar( "id of author" );

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.