Data and analytics
How to use tools, such as Google Analytics, to improve your content's search engine optimisation (SEO) and get data on how users are interacting with your content.
We’re still working on this section. Sign up to get an alert when we make changes to the guidance.
How to optimise your content for search
Use popular keywords to make the most of search engine optimisation (SEO)
Search engines are where most users start their search for information. If they can’t find your page, they won’t get to your content.
If you use their vocabulary, starting with your page title, summary and first paragraph, users will be more likely to find it.
Find popular keywords with search tools
Use search tools like Google AdWords Keyword Planner to find the keywords that people are searching for in Google. The words you use to describe your content may not be the words your users use to try and find it.
To use Keyword Planner:
- register with Google AdWords Keyword Planner (select ‘I’m an experienced AdWords user’ when this button comes up to avoid having to pay for ad campaigns)
- enter your keyword in the search field
- make sure that results are filtered to UK
We have a guide on GOV.UK that covers a benefit people can get if their partner dies, called ‘Bereavement Allowance’. At first we gave this guide the name of the benefit, but a colleague in HM Revenue and Customs (HMRC) told us that ‘widow’s pension’ was a much more popular term. A Keyword Planner report confirms this.
The term ‘Volume’ means the number of searches per month.
The term ‘bereavement allowance’ gets 450 searches per month, while the term ‘widow’s pension’ gets over 6,000.
Double-check with Google Trends
The volume figures in search tools aren’t exact, so focus on trends and relative popularity rather than the numbers. Use multiple tools if you’re going to make a big content decision like changing a title.
Google Trends allows you to compare alternative keywords, and shows seasonal trends.
The Google Trends report below confirms that ’widow’s pension’ is more popular than ’bereavement allowance’: Widow’s pension keyword result screen in Google Trends
Optimise content for search
Once you know the most popular keywords you can prioritise them in the:
- introductory sentence/summary
- chapter/part titles
- metadata descriptions (only for ‘mainstream’ content)
It’s best to start with the least disruptive content change, so in the Bereavement Allowance example we initially added the term ‘widow’s pension’ in the first sentence. Bereavement Allowance GOV.UK page
At the time of writing GOV.UK is now getting the most traffic from Google for this term, having surpassed HMRC which was previously first in results.
Get a more detailed understanding of your users
As well as the keywords that people are using in search, you can also uncover the specific questions that people have about government services with the search tools above.
The Google AdWords Keyword Planner report also shows terms related to ‘widow’s pension’. This report groups the long list of keywords into themes, and you can click on each theme heading to get the keyword variations. This allows you to understand what questions users want answered in our content.
For example, people search for ‘rates’ in relation to ‘widow’s pension’.
So we covered this on the page: Bereavement Allowance rates page on GOV.UK
Searches on GOV.UK
We also look at what people are searching for on GOV.UK with the Google Analytics Search Terms report. This is helpful to understand what people want specifically from government, not the whole internet.
You’ll need a GOV.UK Google Analytics account to access this link. If you don’t have an account, you can request a report from your departmental single point of contact (SPOC).
Specify the term you want data on; for example to confirm demand for ‘widow’s pension’ you can ask to see how many people searched for this within a certain time period.
You can also find out what people are searching for on a particular page in a Google Analytics Search pages report. These terms often tell us what we’re missing in our content, for more about this see the blog post - The search is over… almost.
We don’t currently make our meta descriptions available for Google to use in search results, but they’re used on browse pages and in internal search results. Meta descriptions help clarify the purpose of the page and focus on the user need.
Trending searches on GOV.UK
Knowing which search terms are ‘trending’ on GOV.UK (being searched for more than usual) can help you to spot user needs that are new or growing in popularity.
GOV.UK trending searches dashboard
The GOV.UK trending searches dashboard pulls in data from Google Analytics into Google Sheets. Then it filters the data to show only what’s being searched for more than usual (compared to yesterday, last week or last month).
Customise the GOV.UK trending searches dashboard
The GOV.UK trending searches dashboard shows search patterns across the whole of GOV.UK.
But if you have a GOV.UK Google Analytics account, you can customise the dashboard so it’s more relevant to your organisation. It works by setting up a ‘segment’, so that the dashboard only shows data about a visit if that visit includes a page published by your organisation.
Bear in mind that segmented data from Google Analytics is sampled to speed up processing.
If you don’t have a GOV.UK Google Analytics account, you’ll need to ask your department or agency’s GOV.UK analytics lead to customise the dashboard for you.
Step 1: make a copy of the dashboard
Make a copy of the GOV.UK trending searches dashboard. To do this, go to File > Make a copy, then save a new version.
Step 2: set up a segment so the data is more relevant to your organisation
Go to the Report Configuration tab in your copy of the dashboard. Paste this code into cell B12:
D10 is the organisation ID for the Department of Work and Pensions (DWP). Change the letter and number to match your own organisation ID.
To find your organisation ID, open up a new browser window and go to your organisation home page on GOV.UK. Then right click and select ‘View source’. Find the ‘govuk:analytics:organisations’ line and copy the ID. For example, on the DWP organisation home page it looks like this:
<meta name="govuk:analytics:organisations" content="<D10>">
Step 3 (optional): add searches associated with mainstream content
GOV.UK mainstream content doesn’t currently have organisation IDs for analytics. But you can segment content by the top-level browse section that it belongs to.
To combine more than one segment, use a comma (with no spaces). If there’s a comma in the name of the browse section, you’ll need to put a backslash in front of it.
So, for data about users who viewed any content tagged with the DWP organisation <D10> or any content in the mainstream ‘Benefits’ or ‘Working, jobs and pensions’ sections, you would paste this code into cell B12:
sessions::condition::ga:customVarValue9=~^<D10>,ga:customVarValue1==benefits,ga:customVarValue1==working\, jobs and pensions
Step 4: schedule updates to the data
You can set the dashboard to update automatically, every hour or every day. Go to Add-ons > Google Analytics > Schedule reports.
To refresh the data manually, go to Add-ons > Google Analytics > Run reports.
For more details about how the dashboard works, see ‘How to monitor trending searches’.
A basic guide to Google Analytics
Understanding basic reports
A quick way to see how your pages are doing is by mapping them against some key metrics and analysing how those metrics relate to each other.
You can get this by going into Behaviour > Site Content > All Pages in the Google Analytics interface and then searching for the URLs of pages you want.
Here’s what each metric means:
This represents the number of visits in which that page was viewed. So, if a user visits a page 5 times during their browsing session, it will show up as one unique pageview in Google Analytics.
This is a count of every time that page was viewed.
For example, if someone visits page X, then goes to page Y and then page X again, then page X will be shown having 2 pageviews (and one unique pageview).
This is the number of times that page was the first page on the site viewed by users.
A simple calculation showing entrances to the page as a percentage of the pageviews.
The percentage of ‘single-page sessions’ – that is, users who viewed only this page and then left GOV.UK.
Average Time on Page
How long users view the page for on average.
In the web version of Google Analytics, it’s given in hours, minutes and seconds - hh:mm:ss. In exported spreadsheets, it’s just in seconds.
Treat this metric with caution – see below.
The percentage of exits that were made from the page (calculated as number of exits/number of pageviews).
How to use the data:
Find out what is the most (and least) popular content
By default, Google Analytics will order reports by the first metrics column. In the above report the Service Manual homepage was the highest visited page followed by the Digital by Default page.
The Unique Pageviews column will show you your most visited pages. Clicking on the down arrow at the top of the column will show the reverse order, ie the least visited pages.
Note that Google Analytics will only show URLs that were visited in the time period (ie, it won’t show up pages which weren’t visited at all). All iterations of URLs will appear as well.
Find potential navigation issues
Dividing the Pageviews metric by Unique Pageviews will show on average how many times a page was viewed during users’ sessions.
A high ratio (above 1.4) indicates that users have to come back to that page within their session. This should be a primer for you to investigate the navigation from that page further to identify any issues.
You’ll need to work this out yourself by exporting the data to a spreadsheet. Unfortunately Google doesn’t do this for you.
Identify pages that need to be better optimised
If the Entrances/Pageviews percentage metric is low on pages getting a reasonable amount of traffic, then it suggests that users have a need for the page. However, most are having to navigate their way to get to it so better optimisation for search may be needed.
What high bounce rates suggest
Bounce rates should only be viewed against the Entrances metric and not with Pageviews.
A high bounce rate on navigation pages reveals a problem, as it indicates users are not engaging with the page. Changes should be made and the page measured again.
However, a high bounce rate on content pages is not necessarily a bad thing as users could have found the information they came for and didn’t need to go any further.
Length of time spent on a page
The Average Time on Page metric provides a guide to how engaged users are with your page.
However, treat with caution. This is because it excludes data from sessions in which the page was the last one visited on GOV.UK (eg, it doesn’t include single page sessions).
So for pages with high bounce rates (such as news pages), the dwell time displayed by Google may be very wide of the mark. As a general rule, the lower the % Exits rate, the more representative the average time on the page will be.
How to build reports for your own content
If there are sets of pages you frequently measure, you can save time by building your own custom reports. To do this, you could replicate the above report and filter it for your own pages or you could click on this custom report and save it in the ‘1.GOV.UK (Entire site – Filtered)’ view.
You can use Feedback Explorer (also known as ‘Feedex’) to find out what users are saying about your content. You’ll need a Signon account with Feedback Explorer permissions to get access. Contact GDS to ask for access to Feedback Explorer.
Feedback Explorer lets you view anonymous feedback from GOV.UK users.
Users submit this feedback:
- via the ‘Is there anything wrong with this page?’ form at the bottom of GOV.UK pages
- by filling out the satisfaction survey at the end of a transaction that started on GOV.UK
You can use Feedback Explorer to find out if users:
- are having technical difficulties (broken links etc)
- can’t find the information they need
- are struggling to navigate content
- don’t understand something
Why it’s useful
Feedback Explorer can help you understand your users and make informed content decisions.
It’s especially useful if lots of users are saying the same thing, or what they’re saying is supported by:
- reports from contact centres
- feedback from policy colleagues
- named contacts via Zendesk
- searches on GOV.UK
- analytics data
How to use Feedback Explorer
Go to Feedback Explorer.
You can filter feedback by:
- organisation (eg all Home Office content)
- date to see feedback over different periods of time
- the first part of the URL (eg putting ‘www.gov.uk/child-tax-credit’ will show the feedback on all the pages in the guide)
You can export the feedback as a CSV file. The CSV will show more information (eg browsers used) in separate columns, to make it easier to filter and sort.
You can filter by Whitehall pages. Add “&path=/government” to the end of the URL in your browser. This filter won’t show detailed guides.
The ‘Referrer’ column shows where the user came from before they arrived on the page where they left feedback.
Contact GDS if you notice that lots of users are having the same problem on a mainstream page. Please include any information you have that might help to solve the problem.
Other ways to view anonymous feedback
Use the Performance platform dashboard to see which of your pages received the most comments in recent weeks.
Find out more about how to check your content is working for your users.
Info pages are the ‘shadow’ pages that exist for almost every page on GOV.UK. They show validated user needs for that page and metrics about how well the page meets those needs.
How to view an info page
What’s on an info page
An ‘info’ page contains information like the:
- user needs the page is intended to meet
- average number of unique pageviews
- average number of searches started from the page
- top 10 search terms
- number of ‘is there anything wrong on this page?’ of Feedback explorer comments per week
Use this data to see how:
- your content is doing
- users are using your content
- to improve your content to better meet user’s needs