How To Add Google Analytics Tracking Code In WordPress Website

After you create a WordPress website, you can add google analytics tracking code in your WordPress website to track your website browsing action. This article will tell you two method about how to add google analytics tracking code in your WordPress website.

1. Use WordPress Plugin MonsterInsights.

  1. Login to your WordPress manager website.
  2. Click Plugins —> Add New menu item in left navigation panel.
  3. Search MonsterInsights in search plugins text box.
  4. Then click Install Now button to install the MonsterInsights plugin.
  5. After install the MonsterInsights plugin, click Insights —> Settings menu item in left navigation panel.
  6. Then click Launch Setup Wizard button to integrate your google analytics code into your WordPress website.

2. Add Google Analytics JS Code In Theme header.php File.

  1. Register google analytics with your google account.
  2. Login to google analytics and click Admin menu item in left menu panel.
    google analytics admin menu item
  3. Then click Create Account button in right panel, input related website information until the get google analytics tracking code page.
    google analytics website tracking code page
  4. Copy your website google analytics tracking js code.
  5. Then paste above js code into WordPress website header.php file. Please read article How To Modify WordPress Header & Footer to learn more.
READ :   How To Restore WordPress Website From Backup

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.