Connect with us

How-To

How to add google analytics to a website or blog

Published

on

In this article we are going to discuss about How to add google analytics to website or blog. As you know Google analytics is the most popular and best available traffic analytic tool available today. And best thing about this is its totally free. Google analytics can be used to get detail analytics on conversation rate, geographic locations, traffic sources and user behaviors of the traffic to your site.  Google analytics is very useful in analyzing your audience and decide what your target audience and where they coming from and what are the other related pages that they generally interested in. Analyzing this kind of information will considerably help you to keep traffic within your website and also attract more traffic.

How Google Analytics work?

Integrating Google analytic to you website is quite simple you just have to add short piece of JavaScript code in to you website. Then when people visit your website it will track your user behaviors and where they are coming from and other traffic related data through that persons session data from the web browser. Those data can be analyzed trough the Google analytics website. It allows you to compare analyze data according filters and different timeframes.

Now let’s see step by step how you can integrate Google analytic to your HTML or WordPress website.

Set up your google analytics account

1:  Create a Google analytics account if you already have one use that account

add google analytics to website

2. If you are new to google analytics, sign up for a new google analytics. account.

add google analytics to website

3. After providing all required details of your website. You will be directed to the google analytics dashboard. Now select the property that you want to integrate analytics (your website is referred as your property).

add google analytics to website

4. After selecting the property, you want go to admin section in the left-hand side of your dashboard.

5. Inside the admin panel under Property select tracking info -> Tracking code to get the analytics tracking code.

add google analytics to wordpress

Then you get a code snippet that contains your tracking id.

how to add google analytics

Copy this tracking code in to the note pad or any text editor you will need it later.

Integrating Google Analytics to Html website

Adding google analytics to html website is quite straight forward. Just copy and pate the google analytics code in to the html header tag.

how to add google analytics to html website

That’s it now you can get all analytics data from your google analytics page.

Integrate Google analytic to your WordPress website

Now you have to place this tracking code that you obtained in the previous step in to your website. As we discussed there are two ways of doing this if you are using WordPress. You can use google analytics plugin in your WordPress website or you can do it without any plugins also if you don’t like to add extra plugins to your WordPress website. Let’s take a look at these two methods step by step.

Google analytics with plugin

Integrating analytics to you WordPress site using plugin is quite easy. First you need to install the MonsterInsights plugin. To install plugin, go to Plugins->Add new then search for MonsterInsights and install the monster insight plugin to your WordPress website.

how to add google analytics to wordpress

Then new tab called analytics tab will appear on your dashboard. Click on settings section in this analytics tab.

monster insight WordPress plugin

Now click on authenticate your Google account button to authenticate analytics with the plugin from your Google account. Remember to link the correct Google account that you have created earlier section.

how to add monsterinstight to wordpress

That’s it, now you can analyze traffic data through the analytics dashboard . you can also monitor analytics data from your WordPress dashboard.

google analytics on wordpress

Add google analytics to WordPress without plugin

It’s better to use less plugins in you WordPress plugins as much as you can. Because using many plugins in your WordPress website might slow down your website. So, try to use less plugins as much as you can. Therefore I will show you how to integrate Google analytics without using the plugin as well.

As mentioned in the previous sections also first you must have a Google analytics account to use this analytics tools. After creating Google analytics account login to your analytics account.

select the property if you have already added it to your analytics account or Select add new the property in to google analytics account as mentioned in section 1 and get the tracking code for that property.

how to add google analytics

Then go to WordPress dashboard and go to Appearance -> Editor

add analytics to your website

In the editor panel. All the files of your website are listed in the right hand side corner. In that list select the theme header file.

analytics to website

When you click on the theme header header.php file will be opened in editor. Now you can simply copy and paste the google analytics tracking code within the header tag. that’s it now saves the file and go back.

add analytics to website

Now you have successfully integrated google analytics on your WordPress website without using a plugin.  You can monitor site analytics from the google analytics dashboard.

monster insight

thats how you can add google analytics to website or blog. Hope this article is useful for you all. If you have any questions please leave a comment and don’t forget to check out my YouTube channel. Thank you for dropping by.

Continue Reading
Click to comment

Leave a Reply

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

How-To

Free WordPress Hosting On Google Cloud Platform

Published

on

free wordpress hosting on google cloud platform

Google cloud platform is one of the best places to host your website and it’s totally free for the first year. If you are new to web hosting, I think this is the best place for you to start. There are lots of features in a google cloud platform, but here we discuss only free WordPress hosting on a google cloud platform. Let’s start.

What you need…

  • Google account (Gmail)
  • Valid credit card

Step 01 – Setup Google cloud platform

Go to cloud.google.com and sign in to it using your Gmail.

google cloud login

Then click on console and login to your google cloud console.

When you login, you will receive 300$ free credit to explore google cloud products for the first year. Maybe you would like to simply check out GCP’s breath, deploy some application of yours, learn about google cloud and machine learning capabilities. So you can use these 300$ credits to test all of them.

Then go ahead and activate the offer.

google cloud credit activation

Select your country, agree to the term of service and then click continue

google cloud term of service

After that, set up your payment profile by giving your address and credit card details. Don’t afraid to give your card details because if you run out of credits you won’t be billed without your permission.

gcp profile details
gcp billing details

Congratulations …!! Now you are on the google cloud platform. This is a very simple dashboard and easy to understand for anyone. Lots of services are providing by this platform, but here we discuss only the hosting part. Go ahead and click on My First Project to create a new project.

Then create a new project by giving a suitable name.

google cloud platform dashboard
create new google cloud project

Ok, now you have your google cloud project. Let’s see how to deploy WordPress on a google cloud platform.

Step 02 – Deploy WordPress on Google Cloud Platform

Go to Marketplace and scroll down to select WordPress Certified by Bitnami virtual machine

google cloud platform marketplace
wordpress by bitnami

Bitnami WordPress comes with plenty of packages that are essential to typical WordPress themes. Let’s go ahead and click Launch on Compute Engine.

launch bitnami on google cloud

Ok, now we are going to set up deployment details. Please use the following values to fill in the details.

  • Deployment Name – wordPress-1
  • Zone – us-west1-b
  • Machine Type – micro (1 shared vCPU)
  • Boot disk type – SDD Persistent Disk

Keep default values for other fields and click the Deploy button.

deploy bitnami on gcp
deploy wordpress on gcp

Now we have a new WordPress website. You can see the site IP address, user name, and admin password.

OK… what are you waiting for? Let’s log into the admin panel.

bitnami wordpress login

This is your WordPress admin panel. In addition, we hope to discuss WordPress customization in the future. For now, you can simply go through the dashboard and understand.

wordpress dashboard

Finally, this is your brand new website. Using very few steps we launch our very first WordPress website. In future lessons, we hope to discuss WordPress customization and the best WordPress themes for blogging.

your first wordpress website

Hope you learn something, So don’t wait and start your blog today.

And don’t forget to share your experience with the Google cloud platform in the comment section.

Continue Reading

Trending