Thursday, May 26, 2022

How to Display All Your Subscriber Counts in WordPress (4 Ways)

Do you want to display all your subscriber counts in WordPress?

Displaying the total number of followers on your WordPress site is an easy way to boost your social proof and authority.

In this article, we’ll show you how to grow your audience by displaying all your subscriber counts in WordPress.

How to display all your subscriber counts in WordPress

Why Display Your Subscriber Count in WordPress?

A subscriber count is the number of people subscribed to a service or platform. You’ll often see subscriber or follower counts on popular social media sites.

Adding your subscriber counts to WordPress is a form of social proof.

If users see that a lot of people are followers or subscribers, then they’re more likely to see your website as an authority in your blogging niche.

For example, here at WPBeginner we display our total number of readers to encourage other visitors to follow or subscribe.

WPBeginner email subscriber count

There are all kinds of different subscriber counts you can display on your site including email newsletter subscribers, membership site users, social media followers, and more.

That being said, let’s take a look at how you can display all your subscriber counts in WordPress. Simply use the quick links below to jump straight to the method you want to use.

Method 1. Displaying Multiple Social Media Follower Counts with a WordPress Plugin

With this method, you can display multiple social media follower counts together on your WordPress website. If you have a large social media following on different networks, then this can be a great way to show your authority.

To do this, we’ll be using the Ultimate Social Icons plugin. It integrates with over 200 platforms and lets you easily display subscriber counts for multiple networks at once.

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

Upon activation, there will be a new menu option called ‘Ultimate Social Media Icons’ in your WordPress admin panel.

You need to click this to bring up the plugin settings.

Then, click the ‘Which icons do you want to show on your site?’ drop down and check the box for the social icons that you want to display.

Choose icons to display

Next, click on the ‘What do you want the icons to do?’ drop down. Here, you can configure the actions that visitors can perform when interacting with your icons. 

For example, if you selected Facebook, then you have the option for users to like your page, visit your page, and more.

Choose social icon actions

Next, click to expand the ‘Where shall they be displayed?’ section.

Here, you can choose where your icons will appear.

Choose social icons display settings

You’ll have multiple options including adding them in a widget, having them hover over your site, using a shortcode, and more.

If you want the flexibility to place the subscriber count anywhere on your site, then check the ‘Place via shortcode’ box.

This gives you a shortcode that you can add anywhere on your WordPress site.

Copy social icons shortcode

If you’re using the shortcode option, then make sure to copy the shortcode, since we’ll add it to your site at a later step.

Now, it’s time to configure your subscriber counts. Simply click the ‘Do you want to display counts next to your icons’ drop down and then click the radio button for ‘Yes’.

Display social follower counts

Below that, you may need to enter additional information, depending on the platforms and services you selected earlier.

For example, to display your Facebook subscriber count, you’ll need to enter your Facebook page ID.

Enter Facebook page ID

The plugin does a good job of explaining the actions you need to take, and the information you’ll need to enter for each social network. 

Once you’ve finished configuring the plugin settings, scroll to the bottom of the page and click on the ‘Save All Settings’ button.

Now, you can add your social share count buttons to your WordPress blog.

You can add these to any post, page, or widget area. To add it to a post, simply open up the blog post you want to edit.

Then, click the ‘Plus’ add block icon and search for ‘Shortcode’, then select the block.

Select shortcode block

Next, paste the plugin shortcode that you copied earlier.

Then, click the ‘Update’ or ‘Publish’ button to save your changes.

Paste shortcode and save

Now, you can visit your website to see your social media follower counts live.

If you want to add the shortcode to a page or widget area, then the steps will be similar.

To learn more, see our beginner’s guide on how to add a shortcode in WordPress.

A range of subscriber counts.

Method 2. Displaying Individual Social Media Follower Counts in WordPress

This method involves showing individual social media follower counts for Facebook, YouTube, and Twitter.

If you’re very active and have a large following on a specific social media network, then this is a great option.

Display Your Facebook Follower Count in WordPress

If you have a large Facebook following, then you can easily show this follower count to your site.

To do this, you’ll be using the Facebook page plugin. These work similar to standard WordPress plugins, but are created by Facebook.

First, you need to head over to the Meta for Developers website to create your plugin embed code. You’ll see a list of all the different Facebook plugins that you can add to your website.

From here, select ‘Page Plugin’ from the left-hand sidebar.

Select Facebook page plugin menu option

Next, enter the URL of your Facebook page. Then, you need to let Facebook know what content it should display on your website.

Beyond your follower count, you can also show your timeline, events, or messages.

If you want to display multiple types of content, then simply separate each value with a comma. For example, if you wanted to display your timeline plus upcoming events, then you’d type ‘timeline, events’.

Enter Facebook page URL

The live preview will update automatically so you can play around with the settings to see what works for you. You can also change the width and height of your Facebook plugin.

If you want to reduce the size of your Facebook content, then you can check the ‘Use Small Header’ box. You can even remove the Facebook cover photo completely, by checking the ‘Hide Cover Photo’ box. 

Customize Facebook display settings

Once you’re happy with what you’re seeing in the preview, you need to click the ‘Get Code’ button. This opens a popup containing all of the different embed codes.

In this popup, select the ‘iFrame‘ tab and copy the code.

Copy iFrame code

Next, you need to open up the post or page where you want to add your Facebook follower count.

Then, click the ‘Plus’ add block icon and search for ‘Custom HTML’, then select the block.

Select custom HTML block

After that, paste your HTML code into this block.

You can also click on the ‘Preview’ option to check if the HTML code is working properly. You should now see your Facebook subscriber count embedded in your WordPress website. 

Paste iFrame code and save

If you’re happy with how it looks, then click the ‘Publish’ or ‘Update’ button to save your changes. To learn more, see our guide on how to easily embed iFrame code in WordPress.

You can also add your Facebook subscriber count to any widget or sidebar area of your site. This can be a great way to display your Facebook subscriber count across your entire website. 

To do this, go to Appearance » Widgets. Then, click the ‘Plus’ add block icon and search for ‘Custom HTML’ and then select the widget.

Add custom HTML block

Then, you can paste your HTML code just like above.

Don’t forget to click on the ‘Update’ button at the top of your screen to save your changes.

Paste iFrame code and save

Now, you can visit your website to see your Facebook subscriber count live.

Facebook followers sidebar example

Display Your YouTube Follower Count in WordPress

Similar to Facebook, YouTube has a tool that you can use to display your YouTube subscriber count. This makes it easy for visitors to see your total number of subscribers and follow your channel.

First, you’ll need to know your YouTube channel ID. To find this, head over to YouTube and click on your profile icon in the top right corner.

Next, click on ‘Settings’. Then, in the left-hand menu, click on ‘Advanced Settings’. This opens a screen containing your Channel ID.

Find YouTube channel ID

Once you have this information, you need to go to the YouTube developers website

Now, you can enter your ID into the ‘Channel Name or ID’ field.

Enter YouTube channel ID

The preview will update to display your total number of subscribers.

There are a few different ways you can style your subscribe button. This includes displaying your profile picture and channel name.

You can try out different settings to see what works best for your site.

Customize YouTube subscribe button

As you customize the button, YouTube will update the embed code automatically. When you’re happy with how your Subscribe button looks, you need to copy this code.

Then, you can paste the embed code into any post, page, or widget area, just like above.

For more details, you can see our guide on how to add HTML in WordPress.

Here’s how it looked on our demo site.

How to display your YouTube subscriber count on your WordPress website.

Display Your Twitter Follower Count in WordPress

If you’re active on Twitter and have a large following, then you can display this on your WordPress blog.

The easiest way to do this is by using the Smash Balloon Twitter Feed Pro plugin. It’s one of the best Twitter plugins for WordPress and makes it easy to display your Twitter feed and follower count.

Smash Balloon Twitter Feeds Pro

This plugin gives you full control over what Twitter content you want to add to your site. You can display your follower count and feed by using the included block, or adding it as a sidebar widget.

To learn more, see our step by step guide on how to add your social media feeds to WordPress.

Twitter followers example

Method 3. Displaying Your Email List Subscriber Count in WordPress

Showing your email subscriber count can act as an incentive to get readers to join your email list. If you have a large email list, then displaying the subscriber count on your site can be great social proof.

We’ll be using Constant Contact, however the steps will be similar if you’re using an email marketing service like HubSpot, Drip, Sendinblue, or another provider.

First thing you need to do is login to your account and click the ‘Contacts’ tab, then click the smaller ‘Contacts’ menu option.

This will list the total number of email subscribers you have. You need to take note of this number, since you’ll be adding it to your site.

View Constant Contact subscribers

Then, you can add the subscriber count to any page, post, or widget area on your site.

We’ll show you how to add it to a sidebar widget, but the steps will be similar if you’re adding it to another location.

Next, go to Appearance » Widgets, click the ‘Plus’ add block icon and search for the ‘Paragraph’ widget and select it.

Add new paragraph widget block

Then you can customize the text however you’d like. You can even add the text above your email subscription forms, desktop and mobile popups, and more.

Once you’re finished, make sure to click the ‘Update’ button to save your changes.

Add subscriber count and save

Now, you can visit your website to see your email subscriber totals live.

Email list subscribers example

Although this method isn’t automated, you can easily update your subscriber counts by simply logging into your email marketing provider and making sure your numbers are still accurate.

You can make this a task to update each month or even each quarter.

Method 4. Displaying Total Number of Registered Users in WordPress

Some websites enable user registration so visitors can comment, post, and perform other actions on the site.

Other sites like membership sites, online courses, WordPress forums, and more also allow for user registration during sign up.

If you have a large number of registered users, then you may want to display this number to encourage more sign ups.

This method requires you to add code to your WordPress site. If you haven’t done this before, then see our guide to pasting snippets from the web into WordPress

Then, you can add the following code snippet to your functions.php file, in a site-specific plugin, or by using a code snippets plugin

// Function to return user count
function wpb_user_count() {
$usercount = count_users();
$result = $usercount['total_users'];
return $result;
}
// Creating a shortcode to display user count
add_shortcode('user_count', 'wpb_user_count');

This code snippet creates a shortcode that you can use to display your registered user count anywhere on your WordPress site.

You’ll need to copy the following shortcode:

[user_count]

Then, open up any page, post, or widget area where you want the user count to display.

For this example, we’ll show you how to add it to a widget-ready area of your site. But the steps are similar for any other area of your website.

Simply go to Appearance » Widgets, click the ‘Plus’ add block icon and then search for ‘Custom HTML’ and select the block.

Add custom HTML block

Keep in mind, the shortcode displays the number of registered users only. If you don’t provide any context, then this is just a random number. 

To make sure visitors understand that is your subscriber count, it’s a good idea to add some supporting text. For example, you can add the following HTML formatting.

<p>There are <strong>[user_count]</strong> awesome people subscribed to this blog!</p>

Once you’re finished customizing, make sure to click the ‘Update’ button to save your changes.

Save registered user count shortcode

Now, you can visit your site to see your registered user count live.

Registered user count example

If you don’t feel comfortable editing your site’s code, then another option is to use a plugin.  To learn more, see our guide on how to show total number of registered users in WordPress

You can also show a list of recently registered users in a list format. To learn more, see our guide on how to display recently registered users in WordPress.

Growing Your Subscriber and Follower Counts in WordPress

Displaying your large subscriber numbers can give your users the push they need in order to convert. However, there is always room to improve your conversion rates by displaying even more social proof. 

Here are some of the best WordPress plugins that’ll help you grow your subscribers and followers even further:

We hope this article helped you learn how to display all your subscriber counts in WordPress. You may want to see our guide on how to choose the best web design software and our expert picks of best live chat software for small businesses.

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.

The post How to Display All Your Subscriber Counts in WordPress (4 Ways) first appeared on WPBeginner.


May 26, 2022 at 04:00PM

Wednesday, May 25, 2022

How to Switch to Google Analytics 4 in WordPress (The RIGHT Way)

Are you looking to switch to the latest Google Analytics version?

Google is now recommending website owners to move to the new Google Analytics 4 because they will be sunsetting the previous Universal Analytics on July 1, 2023. After the sunset day, you won’t be able to track data in the older version.

In this article, we’ll show you how to easily switch to Google Analytics 4 in WordPress.

Switch to Google Analytics 4 in WordPress

Why Switch to Google Analytics 4?

Google Analytics 4 (GA4) is the latest version of Google Analytics. It lets you track your mobile apps and websites in the same account, and offers new metrics, reports, and tracking features.

If you haven’t created a GA4 property yet, then now is the best time to switch to the latest version. That’s because Google announced that it will be closing down the old Universal Analytics on July 1, 2023.

What this means is that Universal Analytics will no longer receive data from your WordPress website, and it will eventually stop working after the sunset date. That means that all your old analytics data will be lost.

Switching to Google Analytics 4 as soon as possible will protect you from starting from scratch with no historical data.

To do this right, a lot of smart website owners are using the dual tracking method which allows you to continue using the current Universal Analytics while start sending data to GA4.

This way, you can future-proof your data while giving yourself plenty of time to learn the new Google Analytics dashboard and features.

That being said, let’s see how you can switch to Google Analytics 4 in WordPress with dual tracking.

Creating a Google Analytics 4 Property

If you already have an existing Google Analytics account using the old version, then you can eaily create a new GA4 property and start sending stats to GA4.

First, you’ll need to visit the Google Analytics website and login to your account.

After that, head over to the ‘Admin’ settings page in the bottom left corner.

Click admin settings

If you’re on classic Google analytics, then you’ll see the option to setup GA4.

Go ahead and click on ‘GA4 Setup Assistant’ under the Property column.

Click on GA4 setup assistant

In the next step, the setup assistant will give you 2 options. You can create a new Google Analytics 4 property or connect an existing one.

Since we’re setting up a new property, simply click the Get Started button under the ‘I want to create a new Google Analytics 4 property’ option.

Create a new GA4 property

A popup will now appear with the details about the setup wizard.

If you’ve implemented your Universal Analytics using the Global Site Tag (gtag.js) code, then you’ll see an option to Enable data collection using existing tags.

This uses the existing tracking code on your site to collect information. That said, if you don’t already have the right tracking code on your website, we’ll show you how to add it to your WordPress blog below.

For now, you can go ahead and click the ‘Create property’ button.

Click the create property button

The setup wizard will add a new GA4 property and copy the Universal Analytics property name, website URL, timezone, and currency settings.

You can now view your new Google Analytics 4 property in the GA4 Setup Assistant.

View your connected property

Next, you’ll need to click on the ‘See your GA4 property’ button to see your Google Analytics tracking code.

After clicking on the button, simply click on the ‘Tag installation’ option to retrieve your tracking code.

Go to tag installation

You should now see your new GA4 property under Data Streams.

Go ahead and click on your new property.

Select your data stream

A new window will slide in from the right, and you’ll be able to see your web stream details.

Note: Google Analytics 4 uses both ‘data stream’ and ‘web stream’. These both simply mean the flow of analytics data that Google Analytics receives from your website.

Simply scroll down to Tagging Instructions section and click the Global site tag (gtag.js) option to expand the settings. You’ll now see your Google Analytics tracking code that needs to be added to your WordPress site.

See web stream details

One thing you need to know is that Google Analytics 4 reports are quite different than what you’re used to in Universal Analytics.

They have introduced new terminology, and many familiar metrics and reports are missing completely. Basically if you were using common reports like the Top Landing Pages report or others, then you’d have to recreate those from scratch in Google Analytics 4.

That’s why we recommend using MonsterInsights Pro or even the free version of MonsterInsights.

It will help you see all the familiar analytics reports right in your WordPress dashboard, and it also lets you use both Universal Analytics and Google Analytics 4 at the same time.

Not to mention, with MonsterInsights you get all the powerful tracking features such as outbound link tracking, author tracking, and more which can be enabled without writing any code.

Let’s take a look at how to easily set up Google Analytics 4 on your WordPress site with MonsterInsights.

Adding Google Analytics Tracking Code to WordPress Site

The best way to add Google Analytics tracking code to your WordPress website is by using MonsterInsights. This is the plugin that we use on WPBeginner.

MonsterInsights is the best Analytics solution for WordPress, and it’s trusted by over 3 million websites because it lets you easily setup advanced tracking without any coding skills.

You can use the MonsterInsights Lite version to set up Google Analytics in no time. There are also premium MonsterInsights plans that offer more features like custom dashboard reports, email summaries, scroll tracking, eCommerce tracking, premium integrations, and more.

MonsterInsights also offers dual tracking, meaning you can use both Universal Analytics and Google Analytics 4 at the same time. This is available in both the free version as well paid, and we highly recommend using this to ensure that your transition to GA4 goes smoothly.

First, you’ll need to install and activate the MonsterInsights plugin. For more details, please see our guide on how to install a WordPress plugin.

Upon activation, you’ll be taken to the MonsterInsights welcome screen in your WordPress dashboard. Simply click the ‘Launch the Wizard’ button to add Google Analytics to your site.

Launch setup wizard

After clicking the button, the setup wizard will ask you to choose a category that best describes your website.

You can choose from a business website, publisher (blog), or online store. Once you’ve selected a category, click the ‘Save and Continue’ button.

The MonsterInsights setup wizard

In the next step, you’ll need to connect MonsterInsights with your WordPress site.

Go ahead and click the ‘Connect MonsterInsights’ button.

Connect MonsterInsights with your site

Once you click the button, you’ll need to sign in to your Google Account.

Simply select your account and click the ‘Next’ button.

Choose Google account to sign in

Next, MonsterInsights will require access to your Google Analytics Account.

MonsterInsights App needs these permissions, so it can help you setup analytics properly and show you all the relevant stats right inside your WordPress dashboard.

You can click the ‘Allow’ button to continue.

Allow access to your Google account

After that, you’ll be redirected back to the MonsterInsights setup wizard.

To complete the connection, select your Google Analytics 4 property from the dropdown menu and click the ‘Complete Connection’ button.

Select your GA4 property

Next, MonsterInsights will connect Google Analytics with your WordPress website.

On the next screen, you’ll see some recommended settings like file download tracking and affiliate link tracking.

You can use the default settings in the setup wizard. However, if you’re using an affiliate link plugin, then you’ll need to enter the path you use to cloak the affiliate links.

Recommended settings

Next, you can scroll down and select who can see reports and add different WordPress user roles.

Once you’re done, click the ‘Save and continue’ button.

Who can see the reports

After that, MonsterInsights will show different tracking features that you can enable for your website.

You can scroll down and click the ‘Skip for Now’ button.

Choose which tracking features to enable

Next, you’ll see a checklist showing that you’ve successfully connected Google Analytics to your website.

For example, it will show that you’re successfully connected to Google Analytics, the tracking code is properly installed, and the data is being collected.

Tracking should be all setup

That’s it, you’ve added Google Analytics 4 property to your WordPress site.

Creating a Measurement Protocol API Secret

If you want to MonsterInsights to track eCommerce purchases, form conversions, and more advanced tracking in Google Analytics, then you’ll need to create a Measurement Protocol API Secret.

First, you’ll need to go back to your Google Analytics account and then go to Admin settings. Next, click on the ‘Data Streams’ option under Property column.

Go to admin and data stream settings

Then you’ll need to select the Google Analytics 4 property that we created earlier.

Go ahead and select your property under Data Streams.

Select your data stream

After that, you can scroll down to the ‘Advanced Settings’ section.

Simply click the ‘Measurement Protocol API secrets’ option.

Select measurement protocol API secrets option

A new window will now slide in with your Measurement Protocol API secrets.

You will have to click the ‘Create’ button.

Create an API key

After that, enter a nickname for your API secret so it’s easily identifiable.

When you’re done, click the ‘Create’ button.

Enter a name for your API

You should now see your Measurement Protocol API secret.

Simply copy the API secret under the ‘Secret value’ field.

Copy the secret value

After that, you can head back to your WordPress website and navigate to Insights » Settings from your dashboard.

Now click on the ‘General’ tab at the top.

General settings tab in MonsterInsights

Next, you will have to scroll down to the ‘Google Authentication’ section.

Go ahead and enter the Secret value you just copied in the Measurement Protocol API Secret field.

Enter measurement protocol API secret in MonsterInsights

You’ve successfully added Measurement Protocol API Secret in MonsterInsights.

Setting Up Universal Analytics Dual Tracking

Now that you have setup GA4, the next step is to enable dual tracking for Universal Analytics, so it can run alongside your Google Analytics 4 property in WordPress.

With MonsterInsights, you can easily set up dual tracking and simultaneously track both properties without writing code.

Note: If you already have Universal Analytics tracking code added to your WordPress website, then we recommend disabling it first. Otherwise, it could lead to double-tracking and can skew your data.

To start setting up dual tracking properly, you can head to Insights » Settings from your WordPress admin panel and then click on the ‘General’ tab.

General settings tab in MonsterInsights

Next, you’ll need to scroll down to the ‘Google Authentication’ section.

Now under the Dual Tracking Profile, enter your Universal Analytics (UA) code.

Enter your UA Code

You can easily find your UA code in Google Analytics Admin settings.

Simply go to the Admin settings page in Google Analytics of your Universal Analytics property.

Click admin settings

Then click on ‘Property Settings’ under the Property column.

You should see the Tracking Id, and it will look like this: UA-123856789-5

Find your tracking ID

You’ve now successfully set up dual tracking on your WordPress website.

To see how your website is performing, simply go to Insights » Reports. Here you’ll find all the data you need to make the right decisions to grow your website.

Dashboard reports

We hope this article helped you learn how to switch to Google Analytics 4 in WordPress. You may also want to see our ultimate WordPress SEO guide to improve your rankings, or see our comparison of the best email marketing services for small business.

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.

The post How to Switch to Google Analytics 4 in WordPress (The RIGHT Way) first appeared on WPBeginner.


May 25, 2022 at 04:00PM