Hello friends,

In today’s post I will share with you one quick and easy to apply fix for your “lost” Facebook comments after the migration to SSL for your WordPress website.

Before we begin – let’s define when this tutorial will be useful for you.

First of all you have to be using Facebook comments for your WordPress website. As you know from our previous posts on the topic, this is a great way to allow more people to get involved with your content without the need of additional registrations. Also each Facebook comment increases the popularity of your website within the social media.

For the purpose of this tutorial you may need to use the plugin “Facebook Comments”. Read more about it here: Facebook Comments for WordPress.

Second – this tutorial will be useful if you have just migrated from non-SSL to a SSL version of your WordPress website by using the “Really Simple SSL” plugin. Read how to achieve this from our post: Really Simple SSL – the proper way to secure WordPress.

Now let’s assume that you have been using Facebook Comments for a while before the migration to SSL. You have set up the plugin correctly and your visitors have commented on your website at least once and you are sure that the comments have been displayed correctly. Then you have decided to migrate to SSL and the comments are gone.

This is where our tutorial begins. Prepare to learn how to quickly restore Facebook comments to your WordPress website after migration to SSL!

Your Facebook comments are not lost! You can check them out in your moderation tool. They may have been disabled or hidden, but they are still there. Re-enable them if needed and then return to your WordPress website.

Create a child theme if you haven’t done this already. This will ensure that your Facebook comments won’t get lost again during your theme’s update. If you have set up your child theme successfully simply create a new functions.php file for it. This can be a blank file (i.e. without any content in it). Save it and then edit it.

Add the following code:

Change domain.com to your website’s domain name (with or without www). Do this for both entries (http and https) in the code above. Save the file and clear your cache.

Reload the post or page where you were certain that you had Facebook comments before the migration to SSL. They should be back once again.

In case you are not using a child theme you can add this code to your main functions.php file and save it. However when your theme gets updated this code will be lost and you will need to re-enter it once again.

That’s all friends! For more information and other solutions for the “lost” Facebook comments after migrating to SSL for your WordPress website, please read this post: How to recover Facebook likes after moving to https/ssl.

If you have any questions or other feedback, please share them in the comment section below. See you soon, friends!