Creation

Track copied texts with Google Analytics/Google Tag Manager

Good content takes time! Time for the idea, text creation and for SEO optimization (outline, headings and keywords). It doesn't stop after publishing. From here on, content marketing really gets going.

How well the content is received by the target group can be answered in the further course through content tracking. In addition, event tracking can help measure content engagement. This includes the tracking of copied texts, the so-called Ctrl-C tracking.

{{divider}}

Content and event tracking

If you want to measure the performance of the content on your website, you can't do without Content tracking cannot be bypassed. This involves measuring important key figures that reflect the success of content. Web analytics systems such as Google Analytics offer metrics such as bounce rate and dwell time. The bounce rate is the percentage of all sessions in which visitors generated only one hit. The dwell time tells how long a user stays on the page.

If you want to measure additional events triggered by your users, you will have to implement event tracking. This can be used to track clicks on elements such as buttons or links. Scroll tracking is also of central importance for measuring content engagement.

In addition to clicking and scrolling, users like to perform another action while reading texts: They copy individual terms or entire text phrases to the clipboard using Ctrl-C. This is where you can start with Google Analytics and Google Tag Manager. Ctrl-C tracking allows you to measure such interaction.

{{divider}}

How does the tracking of copied texts work?

How often did you copy single terms or whole text passages via Ctrl-C while reading a text and then send it on to colleagues?

This is exactly how many users behave on the web. Different content is copied. Based on my observations, the copied content can be roughly divided into 3 categories:

  • Contact information such as phone numbers, addresses or email addresses
  • Individual terms and item numbers
  • Whole text passages

Ctrl-C tracking focuses on such use cases. As soon as a user copies text to the clipboard via Ctrl-C, an event is sent to Google Analytics via Google Tag Manager. The following happens technically:

  1. A user comes to the website and marks a section of text while reading.
  2. When the text is selected, a JavaScript function fetches the selected text passage.
  3. The user presses "Ctrl" on the keyboard together with "C" to copy the text to the clipboard.
  4. Directly during copying, another JavaScript function is executed. This function sends the data to the dataLayer of the Google Tag Manager.
  5. When the data is sent to the dataLayer (called "push"), an event is triggered at the same time.
  6. The triggered event is then a signal to send the data to Google Analytics.

I'll show you how to implement these steps in Google Tag Manager in the next section.

At this point, an important note on the topic of "PII" (Personally Identifiable Information). The focus here is on the transmission of personal data to Google Analytics. According to the Google Analytics terms and conditions, such transmission is not permitted.

Google explains this in the Google Analytics Help "Best Practices for Avoiding the Sending of Personally Identifiable Information." Since users also copy contact information, Ctrl-C tracking could send personally identifiable information to Google Analytics. The linked Google Analytics Help explains how to counter this.

{{divider}}

Track copied texts with Google Tag Manager

Let's move on to the practical implementation of Ctrl-C tracking with Google Tag Manager. You will need the following tags, triggers and variables:

  • A custom HTML tag with the necessary JavaScript functions
  • Two data layer variables
  • A custom trigger
  • A Google Analytics tag for the event

{{divider}}

Custom HTML tag

Further above I had mentioned that two JavaScript functions are necessary:

  • When the text is selected, a JavaScript function fetches the selected text passage.
  • Directly during copying, another JavaScript function is executed. This function sends the data to the dataLayer of the Google Tag Manager.

For the first case, you don't necessarily need programming skills. On Stack Overflow you can find a ready-made function that does the job. For the second case Daniel Carlbom has a solution ready. In combination, the code looks like this:

<script>

// Declare function to get selected text from document

function getSelectionText() {

var text = "";

if (window.getSelection) {

text = window.getSelection().toString();

} else if (document.selection && document.selection.type != "Control") {

text = document.selection.createRange().text;

}

return text;

}

// Declare function on copy event

document.addEventListener('copy', function(e){

dataLayer.push({

'event': 'textCopied',

'clipboardText': getSelectionText(),

'clipboardLength': getSelectionText().length

});

});

</script>

Copy this code. In Google Tag Manager, create a new tag of type "custom HTML" and add the code. Select "All Pages" as the trigger:

Custom HTML tag

{{divider}}

Data layer variables

In the next step you need 2 data layer variables, which you can create under the menu item "Variables" in the Google Tag Manager:

Google Tag Manager Variable
Google Tag Manager Variable

{{divider}}

Trigger

In order for our Google Analytics tag to fire, we need a trigger of type "custom trigger":

Google Tag Manager Trigger

The defined condition "does not match regular expression ^$" controls the following: The trigger should only fire if text has actually been selected.

{{divider}}

Google Analytics Tag

The last step is to create the Google Analytics tag for the event.

  • I choose "copy content" as the event category.
  • The event action should be the copied text. Therefore I choose here the data layer variable "clipboardText", which I named "{{dlv - clipboardText}}".
  • The event label is "{{dlv - clipboardLength}}" and returns the character length of the copied text.
  • "Hits without interaction" I set to "True" so that the bounce rate is not affected.
  • As trigger I choose the previously defined custom trigger "textCopied".
  • In the Google Analytics setting, the last thing I do is select my Google Analytics Property.

The names can be freely assigned. The category could be "content" if you want to combine all events from the content tracking area within this name. The label could then be "copy" for further differentiation. The data layer variable "clipboardText" is important because it returns the copied text.

In summary, my day looks like this:

Google Analytics Tag

That's it!

Before publishing, the implementation should be tested as usual via the preview mode of the Google Tag Manager. Activate the preview mode and open your website in the same window but in a different tab. Mark a text and copy it with the key combination "Ctrl" and "C". On the left side of the preview mode you should see the event "textCopied". Under "Tags Fired On This Event" the created tag should appear:

Google Tag Manager Preview Mode

With the publication, the data will flow to Google Analytics immediately. Before you go into the analysis, here are a few technical notes on the setup:

  • The used copy event is not supported by Internet Explorer. The compatibility can be checked on the Developer page from Mozilla can be checked.
  • The copy event also reacts within many mobile browsers. Anyone who copies texts in the Google Chrome app is also recorded here. Safari also sent data during my test.
  • The event action can get long quickly when copying larger sections of text. According to the Google Analytics documentation. the event action can be max. 500 bytes long. This corresponds to about 500 characters. Anything over this can be truncated by Google Analytics. As a rule, this length should be sufficient for an evaluation.

{{divider}}

Evaluate copied texts in Google Analytics

In Google Analytics, you can find the data in the behavior report. Under "Behavior" -> "Events" -> "Overview" you first get to the overview page of the event tracking. On the right side you can find the copied texts within the category "copy content". In the event category report, you still need to select "event action" as the primary dimension.

Subsequently, Google Analytics provides the desired data:

Copied texts in Google Analytics

You can see from this example:

  • Contact details are gladly copied
  • Individual terms are also well represented
  • Whole sentences and text passages occur twice within the top 10

{{divider}}

Data analysis and interpretation

What does the data tell us? The interpretation can go in different directions. I had initially presented 3 possible use cases and categorized them according to experience:

  • Contact information such as phone numbers, addresses or email addresses.
  • Individual terms and part numbers.
  • Whole text passages.

Below I will go into more detail about the 3 categories and present my interpretation of the data. I would be interested in your perspective as well. How do you see it? Feel free to write it in the comments!

Contact information such as phone numbers, addresses or email addresses

Thesis: Copied contact data such as phone numbers, addresses or email addresses are shared with colleagues and friends. Copied phone numbers are used mobile in the numeric keypad for a call. Addresses are entered into Google Maps. E-mail addresses are taken into the e-mail program.

Copied contact data would be a good signal at first glance. Users could be about to make contact. A kind of "soft conversion". On the other hand, I ask myself the following questions:

  1. Are all phone numbers directly linked on mobile devices so that a click directly triggers a call?
  2. Does a folder including a map have to be placed directly under the address on the contact page?
  3. Are all email addresses linked correctly so that when clicked, the email program opens automatically?

Phone numbers are not automatically linked by all mobile browsers. In Apple's Safari, this happens automatically via the meta specification "format-detection". Google Chrome does not link phone numbers automatically.

You can make mobile, phone contact easier for your users by linking all phone numbers directly!

Regarding point 2: Frequently copied addresses may indicate that your users are missing more detailed information about the location. The integration of a folder or a detailed map can help here.

E-mail addresses are copied in order to then use them in the preferred e-mail program for a contact. Clicking on the email address opens the default email client. For most people, this is Outlook or Apple Mail.

But what if the user would rather use Gmail? As a website operator, you can no longer influence that. In order for the user to get directly to Gmail after the click, adjustments in the user's browser settings are required.

Individual terms and item numbers

Thesis: Individual terms and article numbers are copied and then Googled. The user wants to know more about this and research it in more detail.

I interpret copied terms and part numbers in my projects as follows:

  • The terms are googled because they need explanation. If you have a well-maintained glossary to link to, you have a clear advantage. Alternatively, the term can be explained directly in the content. If a more extensive explanation is necessary, external, trustworthy sources can be linked to in case of need.
  • Article numbers are also googled. The user is looking for more detailed information. A detailed product description can be a solution here. Article numbers can also be googled for price comparison purposes.

Whole text passages

Thesis: Whole passages of text are shared with others via emails, chats and social media. Or (re)used on other websites.

This is where it gets exciting. Especially for SEOs. The Ctrl-C tracking can be considered from the SEO point of view as "content theft tracking". Content theft is not rare and can occur in 2 ways:

  • Most often, content theft happens via so-called scrapers. A scraper works in a similar way to a bot. It is a program that automatically processes tasks. One task can be the copying of texts on the web. Texts are automatically pulled from the RSS feed of the website in question. The texts are then published on third-party domains. These sites are called "scraper sites".
  • Not as common as automated content theft - but still present - is theft by copy-and-paste method. Here, texts are copied manually using Ctrl-C and reused on other domains. Whether the content theft happens consciously or unconsciously is irrelevant for the consequences.

In both cases, content theft is a major annoyance for the content creator. The consequence is external duplicate content with many risks for SEO. The automated content theft is not covered by the Ctrl-C tracking...

But the copy-and-paste method does. If large text passages are reported by Google Analytics in the event action, this can be an indication of content theft. Whether your own text is actually reused on other domains can be checked in 2 ways:

  • By Google query: If the stolen text is indexed, you can put the text passage in quotes in Google's search slot. The search engine will then return exact match results.
  • Duplicate content checkers: Tools such as Copyscape, Siteliner or Articlechecker can also help track down the content thieves.

If the Google query and/or tools don't return anything, then that can be a good sign. It doesn't always have to be content theft. Copying several sentences can be interpreted positively on the other hand:

  • The user has found what they are looking for, likes the text and shares it with colleagues via email, chats or social media.
  • Another website owner quotes you on his website. You are mentioned and in the best case you get a backlink. Here, the queries presented above can help to find out the backlink provider.

As you can see, the most exciting part of Ctrl-C tracking is the analysis of the data. The generated insights enable content marketers, SEOs and web analysts to take further steps towards optimization.

How do you see it? Do you use Google Analytics to track copied texts? What exciting insights were you able to generate?

Share:

Book your demo now

Learn best practices and uncover your content marketing potential!
Book a demo
- free of charge

contentbird.blog

Ended
Ended

Key Take Aways

More contributions