Trusted WordPress tutorials, when you need them most.
Beginner’s Guide to WordPress
WPB Cup
25 Million+
Websites using our plugins
16+
Years of WordPress experience
3000+
WordPress tutorials
by experts

How to Change the Default Gravatar on WordPress (Easy Guide)

Do you want to change the default Gravatar on your WordPress site? We hear from a lot of users who aren’t fans of the generic ‘mystery person’ image that WordPress shows when a commenter doesn’t have a Gravatar.

At WPBeginner, we agree that it’s not the most welcoming or engaging look for your comment section. By replacing this stock picture with an image of your choice, you can personalize your comment section to your brand and make it stand out.

In this article, we will show you how to change the default Gravatar on WordPress.

How to change the default Gravatar on WordPress

What Is a Default Gravatar and Why Change it?

Gravatar stands for Globally Recognized Avatar. It’s a web service that allows people to create a profile and associate avatar images with their email address.

All WordPress sites have built-in support for Gravatars and will automatically show the user’s avatar when they write posts on a multi-author WordPress blog or leave comments.

If a user doesn’t have a Gravatar, then WordPress will show a default Gravatar instead. For most WordPress websites, this is a grey mystery person.

The default Gravatar in WordPress

You can change this default Gravatar to any other picture of your choosing. For example, you might use an image that represents your company, such as your website logo. This can help reinforce your branding.

Having said that, let’s see how you can change the default Gravatar image on your WordPress website or blog. Simply use the quick links to jump straight to the method you want to use:

Method 1: Choose a Different Built-in WordPress Gravatar (Quick and Easy)

WordPress comes with a few different default Gravatars that you can use. Using the defaults is the quickest way to change the mystery person Gravatar, although these images won’t be unique to your WordPress website or brand.

To look at the different default Gravatars, you need to go to Settings » Discussion from the WordPress admin area.

Changing the default Gravatars in WordPress

Under ‘Default Avatar,’ you will see all the different built-in avatars that WordPress can use when there’s no Gravatar linked to the person’s email address.

Out of the box, WordPress uses the mystery person as its default, but you can use any other image in this section.

The built-in WordPress Gravatars

Simply click on the radio button next to the image you want to use on your WordPress blog.

Then, scroll to the bottom of the screen and click on ‘Save Changes.’

Clicking the 'Save Changes' button on the WordPress Discussion settings page

Method 2: Use Thrive Comments to Upload a Custom Gravatar (Plugin Method)

If you don’t like the gravatar options provided by WordPress, then you can upload a custom gravatar instead. This is the best way to personalize your comment section to your brand.

For this method, we will use Thrive Comments. It’s a comment plugin that’s designed to encourage users to comment on your blog posts and boost your website engagement.

Besides a custom gravatar feature, Thrive Comments comes with tools to make your comment section more fun and exciting. For instance, you can enable likes and dislikes just like on a social media site.

The Thrive Comments WordPress plugin

You can get Thrive Comments as an individual plugin or purchase the complete Thrive Themes Suite. This includes all Thrive products, like Thrive Ovations, which can turn your comments into testimonials.

After that, you can download a plugin zip package to install on your WordPress site. Read our step-by-step guide on how to install a WordPress plugin for more information.

With the plugin installed and activated, you can go to Thrive Dashboard » Thrive Comments from the WordPress admin area. Then, open the ‘Customize Style’ tab.

Inside this tab, make sure the ‘Display avatars’ setting is turned on. Once done, just click ‘Choose Image.’

Choosing a custom gravatar in Thrive Comments

At this point, you can either choose an existing image from the WordPress media library or upload your own to use as the default gravatar.

You can use a stock photo, make your own custom logo, or even create a new Gravatar image using web design software such as Canva. This image should be a square, like 250×250 pixels.

Once you have chosen an image, click ‘Select.’

Selecting a gravatar image in the WordPress media library using Thrive Comments

And you’re done!

You should now see your new default gravatar in the preview and on your live comment section.

Example of a comment after the Thrive Comments plugin is activated

The cool thing about Thrive Comments is you can easily lazy load gravatars with it.

What that means is WordPress won’t display a commenter’s gravatar until the website visitor scrolls down to that specific comment.

If you want to enable this feature, simply go to Thrive Dashboard » Thrive Comments and open the ‘Advanced Settings’ tab. Then, tick off the box that says ‘Load avatar images when comment enters viewport.’

You can also tick off the other lazy loading features, too.

Enabling lazy loading in Thrive Comments

For more tips and tricks on using Thrive Comments, check out these guides:

Method 3: Insert a Code Snippet to Use a Custom Gravatar (Code Method)

Besides using Thrive Comments, you can also upload a custom gravatar using code. You may prefer this method if you simply want to add a new image to the gravatar list on the WordPress Discussion page.

Like in the second method, you need to have an image that you want to use as a gravatar.

After that, you can upload the image to your WordPress site by going to Media » Add New. Here, you can either choose an image from the WordPress media library or upload a new file from your computer.

How to upload a custom default Gravatar in WordPress

Now that you’ve chosen an image, go ahead and click on the ‘Edit’ link next to it.

WordPress will now open the file for editing. On this screen, scroll to the ‘File URL’ section.

Uploading a default WordPress Gravatar

Make a note of this URL, as you will need it in the next step.

At this stage, you need to add some code to your WordPress site. Often, tutorials will ask you to add custom snippets to your theme’s functions.php file.

However, we don’t recommend this because even a small mistake in your code can cause common WordPress errors or completely break your website.

That’s why we recommend using WPCode. It is the easiest and safest way to add custom code in WordPress without having to edit any core WordPress files.

The first thing you need to do is install and activate the free WPCode plugin. For more details, see our step-by-step guide on how to install a WordPress plugin.

Upon activation, go to Code Snippets » Add Snippet in your WordPress dashboard.

How to add a custom avatar snippet to your WordPress website

Here, you will see all the different snippets you can add to your WordPress website. These include snippets that allow you to completely disable comments in WordPress, upload SVG files to your site, and more.

There’s even one for using a custom image for the default avatar. Simply search for the ‘Custom Default Avatar’ snippet in the library.

Once you find it, hover your mouse over it and then click the ‘Use snippet’ button.

Showing a custom avatar using code

After that, WPCode will automatically add the correct code for you.

Don’t forget to replace the URL with a link to the image you want to use as the default WordPress Gravatar.

WPCode automatically adds the code, you just need to replace the image url

Below the code box, you will see some insertion options. If it isn’t already selected, then choose the ‘Auto Insert’ method so that the snippet will be automatically inserted and executed across your entire site.

After that, open the ‘Location’ dropdown and click on ‘Run Everywhere.’

How to run PHP gravatar code across your website

Once you have done that, you need to scroll to the top of the screen and click on the ‘Inactive’ toggle so that it changes to ‘Active’ instead.

Finally, go ahead and click on ‘Update’ to make the Gravatar snippet live.

How to activate the gravatar code snippet

To start using this Gravatar, go to the Settings » Discussion page.

In the ‘Default Avatar’ section, select the new ‘Custom Avatar’ option.

How to change the default Gravatar in WordPress

After that, make sure you click on ‘Save Changes’ to store your settings.

Now, if you visit your website, you’ll see the new default Gravatar image live.

An example of a custom defualt Gravatar, on a WordPress website

That’s it! To learn more about gravatars in WordPress, check out these guides:

We hope this article has helped you learn how to change the default Gravatar on WordPress. You may also want to see our guide on how to moderate comments in WordPress and our list of the best WordPress comment plugins.

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

Disclosure: Our content is reader-supported. This means if you click on some of our links, then we may earn a commission. See how WPBeginner is funded, why it matters, and how you can support us. Here's our editorial process.

Editorial Staff

Editorial Staff at WPBeginner is a team of WordPress experts led by Syed Balkhi with over 16 years of experience in WordPress, Web Hosting, eCommerce, SEO, and Marketing. Started in 2009, WPBeginner is now the largest free WordPress resource site in the industry and is often referred to as the Wikipedia for WordPress.

The Ultimate WordPress Toolkit

Get FREE access to our toolkit - a collection of WordPress related products and resources that every professional should have!

Reader Interactions

120 CommentsLeave a Reply

  1. Syed Balkhi

    Hey WPBeginner readers,
    Did you know you can win exciting prizes by commenting on WPBeginner?
    Every month, our top blog commenters will win HUGE rewards, including premium WordPress plugin licenses and cash prizes.
    You can get more details about the contest from here.
    Start sharing your thoughts below to stand a chance to win!

  2. Kzain

    this is so helpful i never thought of changing a comment Gravatar but I guess it needs to match your brand and blog

  3. Dennis Muthomi

    The good thing I love about Thrive Comments is that uses a branded image as a placeholder icon for commenters without Gravatars.
    Best comment plugin ever made! :-)

  4. Teri

    You did it again! You helped me. Thank you so much!

    • WPBeginner Support

      You’re welcome! Glad our guide was helpful!

      Admin

  5. Francis

    Hi guys,

    Wonderful tutorial, you saved me from a big headache! Keep up the great work!!!

    Best regards,

    Francis

    • WPBeginner Support

      Glad to hear our guide was helpful!

      Admin

  6. Segun Solomon

    Thanks for this guide. It helps.

    • WPBeginner Support

      Glad it was helpful!

      Admin

  7. WoodyP

    Hi, thank you for your article!
    is there a way to assign one image per role?

    • WPBeginner Support

      We do not have a recommended method at the moment but if that changes we will be sure to share.

      Admin

  8. Patti

    Been working for 2 days trying to get rid of the Chef Hat in my theme.

    This worked! Thanks

    • WPBeginner Support

      Glad our guide could help :)

      Admin

  9. Aardha

    This worked like a charm. Thanks!! Is there a way to have multiple default gravatar which can be assigned randomly to users ?

    • WPBeginner Support

      You would need a plugin for a feature like that, if we find a plugin we would recommend we will certainly share.

      Admin

  10. David

    This is not working. Wordpress does not allow to use local images. Please review your tutorial and update it accordingly.

  11. Murat Dinç

    Hi,
    Can I add an icon instead of Adding an image?

    • WPBeginner Support

      You would want to check on Gravatar’s site for any current restrictions.

      Admin

  12. Renz

    Thank you for this tutorial. was able to follow but my default picture wont show up

    • WPBeginner Support

      If our method was not able to assist, you would likely want to reach out to your theme’s support to ensure there isn’t a theme-specific setting preventing the change.

      Admin

  13. Karen

    Okay, I found an easier solution for everyone that works well: just install the “WP User Avatar” plugin. Works like a charm and you don’t have to do anything with coding!

    • WPBeginner Support

      Thanks for sharing your recommendation

      Admin

  14. Mari Alonso

    This is great, thanks! I followed this by installing the plugin to add the code and then adding my 250×250 picture. It worked great, but now if anyone comments on my site, my picture, not theirs, shows up next to their name. My picture shows up everywhere and no one else’s. Any idea why?

    Thank you. :-)

      • Thank you so much

        I followed the Gravatar instructions on your link and now anywhere I comment I see my unique Gravatar. Nevertheless, I see it everywhere except on my own site even thought the same email address is associated with it. Any ideas?

        Thanks, tons again.
        Mari

        • WPBeginner Support

          If you have any caching on your site make sure it is cleared as the most common reason for something like that.

  15. Divine

    This page was really helpful. I managed to change the custom image. Thanks

    • WPBeginner Support

      Glad our recommendation could help :)

      Admin

  16. Lilly

    Thank you for this post!! I use All in one SEO and could never get it to work. Your post provided a good map and work around. However I am still getting 12 error msgs? are they possible related?

    • WPBeginner Support

      It would depend on the specific errors. If you reach out to the plugin’s support they should be able to assist.

      Admin

  17. Andreia Esteves

    Thank you for this post! But, what if I just want to change my personal avatar without using gravatar?

  18. Giga

    I want an option where the user can upload an image as per their requirements. What should I do for that ?

  19. Tommy Roche

    Thank you for this.

    • WPBeginner Support

      You’re welcome :)

      Admin

  20. Mahdi

    ty – its worked for me – but now default avatar loded from other site – how i can define that this image loaded from my host?

    • WPBeginner Support

      You’re likely using the Jetpack plugin and using their option to load images from their server. You can go into Jetpack’s settings to disable this function.

      Admin

      • MAHDI

        i don’t have Jetpack plugin – how i can do it? without install new plugin?

        • WPBeginner Support

          If you mean you want your gravatar image to be loaded from your site when it is added to other sites, that is not an option at the moment.

  21. Daniel

    Perfect solution, thank you!

    • WPBeginner Support

      You’re welcome

      Admin

  22. Divya S

    That was so informative!

  23. Brian

    Hey so I have sort of a peculiar yet distinct task that I need help with. My client has a blog on Wordpress but then they post their blog to Twitter, next to the article is a gray blank avatar. She had requested that I find a way to put some sort of image in place of this but I am not sure how to go about doing this. I know she uses a Gravatar for the comment section but this instance is a bit different. Any advice on what I can do?

  24. Ryô

    Hello, the code works well, but I made some changes to my newly added avatar picture and I still see the first version when I refresh the page.

    Looking at the url of the picture it automatically added “http://i2.wp.com/” at the beginning (I don’t have jetpack or any cache plugins).

    I guess I can just change the name of my picture and update the code, but is it a way to get ride of wp cache?

  25. Satyam Patle

    Wow Thank you sir its helping me for Change custom Avtar

  26. Ana

    I have no problem changing the image on my gravatar but I cannot seem to change the words. Even though I select edit and rewrite them, the change doesn’t appear on my wordpress site. What am I doing wrong?

Leave A Reply

Thanks for choosing to leave a comment. Please keep in mind that all comments are moderated according to our comment policy, and your email address will NOT be published. Please Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.