Google Webmaster account provides various ways for authorization of self hosted WordPress site. It is recommended to verify the site of all methods so as to be recognized by Google and this makes indexing of webpages better. Today, we will find out how to successfully verify Google Tag Manager container script with Google Webmaster account of your website. In this write up I shall focus on how to install container script inside BIGROCK hosting of a WordPress site.
In order to verify ownership of the WordPress site in Google Webmaster Tools by using Google Tag Manager, there are few prior factors necessary. This writing is suitable for most webhosts including BIGROCK. Here are some prerequisites:
- A self-hosted WordPress blog
- Google Webmaster account
- Container script in Google tag manager
- This article explains about how to insert container script inside BIGROCK hosting
In subsequent articles, I shall be telling about how to create Google Webmaster account. In this article, I have clearly described about how to create Google Tag Manager container script. Google Tag manager categorizes yours site’s container and present anonymous data to advertisers and marketers to use it and give you advertisement options. Research has shown that how sites which have been using Google Tag Manager container script have been very much fast in getting approval from different advertisement agencies for their sites.
- Log in to BIGROCK hosting by WordPress website https://www.bigrock.in/login.php. If you do not have account, then you can purchase one hosting account by going through this link (affiliate link)
- Log in to your BIGROCK wordpress hosting account by providing username and password and then click on blue “Login” button.
- You reach in BIGROCK dashboard, from its upper top right corner click on “My Account”
- You reach for “List of orders”. Here, is the list of purchased domains and hosts. Click its “domain” link corresponding to host name to reach next page.
- Then, you reach for your hosting package. Here is “single domain Linux hosting” and from there click on “manage Web Hosting”. Here you will go to “Cpanel” of WebHost. By clicking a new window will open which is “Cpanel” of webhost.
- From Cpanel go to “files” then go to “File Manager”
- Right click on “File Manager” and then left click on “Open link in new tab”.
- In the next window or tab of Web browser “File manager” opens.
- Then click on “Public_html” folder of WordPress installation.
- On the right side of “File Manager” go to “wp-content”
- In the next phase “wp-content” is in the left side of “File Manager” and in its right side files of “wp-content” will be there.
- On the right side of “File Manager” choose “themes” folder. Click on the folder icon beside “themes”
- In the next windows choose the currently active theme on your WordPress and left click on the currently activated theme folder.
- In the next step, from currently activated theme you will reach to contents of the theme folder.
- Then reach for “header.php” file from the WordPress theme.
- First backs up “header.php” file into your desktop. Double click on the pop icon beside “header.php” and wait for a few seconds to see a popup window to save this file. Save it desktop unless you delete some code then you can restore back it from this back up.
- After back up, then select “header.php” and from above select “Code Editor”
- In the next step, a popup window of “Code Editor” will appear. Click “Edit”
- In the next step after clicking on “Edit” you will find an entire php code of “header.php”
- Then scroll down and search for “<body <? php body_class (); ? >>” It is the body segment of php code
- Just under above mentioned code paste “Google Tag Manager code snippet” copied from here. (Previous page link)
- After copy pasting code under “<body <? php body_class (); ?>>” reach to the upper right of “header. php” segment is to click on “Save Changes”.
In this way, in this tutorial, we learn how to insert Google Tag Manager snippet code for website, into BIGROCK hosting so that in the next step, we will learn about how to verify WordPress website with Google Webmaster tools’s alternative verification method with Google Tag Manager.