How to Guide — Fix Gravatar WordPress Block in China

Update 2018: Gravatar is working again from China, for the time being at least! See the links below this post to check if it’s currently blocked or not.

If you have visitors from the Chinese mainland (like I do) and never touched the avatar settings, some of them could be struggling with slow page loads. This is because Gravatar is blocked/unstable in China, for the time being at least.

The Gravatar homepage itself usually works. But by default, WordPress connects to 0/1/2.gravatar.com subdomains which are the blocked victims. These servers are used to fetch the actual avatar images for the comments section. Therefore it’s better to prevent the connections if you are serious about serving the mainland.

Gravatar in China

The Quick Fix: Turn off Avatars

For a quick solution, turning off avatars completely works efficiently. But of course will remove all avatar images from the layout of your WordPress theme.

WordPress Settings Discussion Avatars

The Easy Fix: Local Avatars Plugin

To keep the native WP comments system, we are left with the option of supporting local avatars only. There are basically two options.

  1. Visitor comments use one set default avatar image, and administrators/editors can set up their own avatar. Which is what I am using.
  2. Enable registrations with the ability for all users to upload their own avatar.

With the most advanced WP User Avatar plugin these are the settings.

WP User Avatar Plugin Settings

To enable user avatars you have different options as well.

WP User Avatar Plugin Upload Avatar Setting

And the results are in. Although I wish there was a solution that can internally fetch the avatars from Gavatar and display them locally without forcing blog visitors to connect to the blocked server. Maybe one day.

How China Comments

The Alternative: Change Comment System

For example, the popular Disqus commenting system has so far remained steadily unblocked in China. While future remains unknown, it’s possible to change from WordPress comments all together and start fresh with their WP plugin. Unfortunately I have no experience of using such systems, but comments are most welcome.

These links can check the current Gravatar block status:

Leave a Reply

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