Skip to Content
3D render of charts and data

Metrics that matter

A charity's guide to actionable website analytics with Plausible.io and GA4

Part 1: Why your charity needs website analytics (and how to get it right)

1.1. Introduction: The power of knowing your supporters

In the world of charitable work, every action, every pence, and every supporter counts. We pour our hearts into our missions, striving to make a tangible difference. But how do we truly know if our online efforts are hitting the mark? How can we be sure our website, often the digital front door to our cause, is effectively engaging visitors, encouraging donations, or inspiring volunteerism? The answer, as we’ve learned through our own journey, lies in the thoughtful use of website analytics.

For many charities, the idea of delving into website statistics might seem daunting, perhaps even a distraction from the core mission. However, understanding how people interact with your online presence isn’t just a technical exercise; it’s a fundamental part of understanding your supporters and maximising your impact. Website analytics provide the insights needed to move beyond guesswork and assumptions, allowing you to make data-informed decisions that can significantly enhance your outreach, streamline your operations, and even bolster your funding applications. Imagine being able to clearly demonstrate to a potential funder not just how many people visited your site, but how many engaged with your latest campaign, downloaded your impact report, or started the donation process. This is the power analytics can unlock.

We’ve been on this journey ourselves, navigating the landscape of tracking tools, metrics, and privacy considerations. It hasn’t always been straightforward, but the clarity and direction gained have been invaluable. In this guide, we want to share what we’ve learned, offering practical, step-by-step advice to help your charity harness the power of website analytics, whether you’re a small volunteer-run organisation or a larger entity with dedicated technical staff. We’ll explore how to define meaningful metrics, introduce you to powerful tools like Plausible.io and Google Analytics 4, and guide you through the important considerations of user privacy and consent. Our aim is to demystify the process and empower you to use data not just for reporting, but for real, actionable change.

1.2. Defining metrics that matter: From vanity to action

Once you’re ready to embrace website analytics, the first crucial step is figuring out what to measure. It’s easy to get lost in a sea of numbers, charts, and graphs. Many analytics platforms present a dazzling array of data points, but not all of them are equally useful. This is where the distinction between “vanity metrics” and “actionable metrics” becomes paramount.

The trap of vanity metrics: Looking busy vs. being effective

Vanity metrics are those numbers that might look impressive on the surface but offer little real insight into your performance or how to improve. Think of things like the total number of page views in a month without any context, or the number of likes on a social media post that didn’t translate into any website visits or donations. While these figures might give a fleeting sense of activity, they don’t tell you if you’re actually achieving your charity’s objectives. For instance, a high number of website visitors is great, but if none of them are taking the actions you want them to (like donating or signing up to volunteer), then that high visitor count isn’t translating into impact. We’ve learned that focusing too much on these can lead to a false sense of accomplishment and distract from the metrics that truly drive progress.

Focusing on actionable metrics: Data that drives decisions

Actionable metrics, on the other hand, are statistics that provide clear, specific insights you can use to make decisions and take concrete steps. They are directly tied to your charity’s goals and help you understand user behaviour in a way that guides improvement. The key is to define metrics that tell you not just what happened, but give you clues as to why it happened and what to do next.

How do you define these golden metrics for your charity? Start with your core objectives:

  • Are you trying to increase donations? Then you’ll want to track how many people visit your donation page, how many start filling out the donation form, and, most importantly, how many complete the donation. Looking at the drop-off points in this funnel can reveal where users are encountering problems or losing interest.
  • Is recruiting volunteers a priority? Track visits to your volunteering page, the number of sign-up forms viewed, and the number of completed submissions.
  • Do you want to raise awareness about a specific issue? Measure engagement with your campaign pages, downloads of informational resources (like annual reports or educational guides), or shares of key content.
  • Is building a community important? Track newsletter subscriptions or registrations for online events.

Linking your tracking directly to these desired actions is crucial. For example, instead of just tracking page views on your “Impact Report” page, track how many users click the “Download Report” button. This is a much stronger indicator of genuine engagement.

Here are some examples of actionable metrics relevant for many charities:

  • Donation conversion rate: (Number of donations / Number of visitors to donation page) x 100%. This tells you how effective your donation page is.
  • Volunteer application rate: (Number of volunteer applications / Number of visitors to volunteer page) x 100%.
  • Newsletter sign-up rate: (Number of new subscribers / Number of website visitors) x 100%.
  • Goal completion rate (for any specific call to action): (Number of times a goal is completed / Number of opportunities to complete the goal) x 100%.
  • User journey analysis: Understanding the common paths users take on your site before completing a key action (or abandoning it).

Privacy first: Tracking responsibly – A cornerstone for charities

As charities, the trust of our supporters is our most valuable asset. When we collect data about their online interactions, we have a profound responsibility to do so ethically and transparently. This isn’t just about legal compliance; it’s about upholding the values that define our work. The principle of “privacy first” should underpin your entire analytics strategy.

This means avoiding over-tracking. It can be tempting to collect every piece of data possible, but this often leads to a data swamp that’s hard to navigate and can raise significant privacy concerns. The golden rule we’ve adopted is to only collect what you genuinely need and will actively use to make decisions or improve your services. If you can’t articulate a clear purpose for a piece of data, you probably don’t need to collect it.

Understanding and respecting regulations like the UK’s General Data Protection Regulation (GDPR) and the Privacy and Electronic Communications Regulations (PECR) is non-negotiable. These frameworks are designed to protect individuals’ personal data and give them control over how it’s used. For analytics, this often means being transparent about what you’re tracking, why you’re tracking it, and, in many cases (as we’ll discuss in detail for Google Analytics 4), obtaining explicit consent before you start tracking. This commitment to privacy not only ensures legal compliance but also reinforces the trust your supporters place in you, showing that you value their autonomy and data rights as much as their contributions to your cause. We’ll delve deeper into the practicalities of cookie consent later, but for now, remember that responsible data handling is an integral part of effective and ethical charity operations.

Part 2: Getting started with Plausible.io - Simple, privacy-focused analytics

Now that we understand the importance of actionable metrics and responsible tracking, let’s explore our first analytics tool: Plausible.io. If you’re looking for a straightforward, privacy-respecting way to understand your website visitors, Plausible is an excellent choice, particularly for charities that value simplicity and want to avoid the complexities of cookie consent banners right out of the box.

2.1. What is Plausible.io and why it’s great for charities

Plausible.io is a lightweight, open-source web analytics tool designed with privacy at its core. Unlike more traditional analytics platforms that rely heavily on cookies and collect extensive user data, Plausible takes a different approach. It provides all the essential website traffic insights without using any cookies and without collecting any personal data or personally identifiable information (PII). This means that, by default, when you use Plausible, you are respecting your visitors’ privacy to a very high degree.

For charities, this offers several significant advantages:

  • Simplicity: Plausible’s interface is clean and intuitive. It presents the most important metrics in a single-page dashboard, making it easy to understand your website’s performance at a glance without getting overwhelmed by complex reports.
  • Privacy by design: Because Plausible doesn’t use cookies or collect personal data for its standard tracking, it is compliant with GDPR, CCPA, and PECR out-of-the-box for its core functionality. This is a huge win, as it means you generally don’t need to display a cookie consent banner to your visitors just for using Plausible for your website analytics. This creates a smoother, more welcoming experience for your site visitors and reduces the legal and administrative burden on your charity.
  • Lightweight: The Plausible tracking script is very small (less than 1KB). This means it has a negligible impact on your website’s loading speed, ensuring a good user experience for your visitors, which is crucial for keeping them engaged.
  • Open source: Plausible’s source code is publicly available. This transparency allows anyone to inspect how it works, adding an extra layer of trust. For technically inclined teams, it even offers the option to self-host.
  • Data ownership: With Plausible, you own your website data. They have a clear stance against selling or sharing your site data with third parties.

In essence, Plausible allows charities to gather valuable insights about their website traffic—how many people are visiting, where they’re coming from, what content they’re engaging with—all while upholding strong privacy principles. It’s a great way to be data-informed without compromising on your values or your users’ trust.

2.2. Setting Up Plausible.io on your website

Getting started with Plausible.io is refreshingly simple. Here’s a step-by-step guide:

  1. Create an account: Head over to the Plausible.io website and sign up for an account. They offer a free trial, so you can test it out before committing.

  2. Add your website: Once logged in, you’ll be prompted to add your website. Enter your website’s domain (e.g., yourcharity.org.uk) and select the reporting timezone.

  3. Get your tracking script: After adding your site, Plausible will provide you with a small JavaScript snippet. This is your unique tracking script that needs to be added to your website.

    The script will look something like this:

    <script defer data-domain="yourcharity.org.uk" src="https://plausible.io/js/script.js"></script>

    Make sure to replace "yourcharity.org.uk" with the actual domain you registered in Plausible.

  4. Add the script to your website: The next step is to embed this script into your website’s HTML. For it to track all page views, it needs to be present on every page of your site. The recommended place to add it is just before the closing </head> tag or the closing </body> tag in your HTML.

    Practical example (Django/Wagtail or similar CMS): Many website platforms, like those built with Django (and its popular CMS, Wagtail), offer a way to add global HTML snippets to the header or footer of every page. This is often found in the admin settings under a section like “Site Settings,” “Global Settings,” or “Head/Footer Scripts.”

    If your website has a field labeled something like “Custom Head HTML,” “Global Header Scripts,” or "Before closing

    tag," you would paste the Plausible script there. For example, in a Wagtail project, you might have a setting in your models.py for global site settings that allows adding scripts to the header, which then gets rendered in your base HTML template.

    Alternatively, if you have direct access to your website’s base HTML template (often called base.html, index.html, or similar), you can paste the script directly into that file. For instance:

    <!DOCTYPE html>
    <html lang="en">
    <head>
        <meta charset="UTF-8">
        <title>Your charity website</title>
        <!-- Other head elements -->
        <script defer data-domain="yourcharity.org.uk" src="https://plausible.io/js/script.js"></script>
    </head>
    <body>
        <!-- Your website content -->
    </body>
    </html>
  5. Verify installation: After adding the script, visit your website. Then, go back to your Plausible.io dashboard. You should start seeing visitor data appear within a few minutes if the installation was successful. Plausible often shows a “Waiting for first page view” message that will disappear once data starts flowing.

And that’s it! Plausible.io is now tracking your website visitors anonymously.

2.3. Understanding your Plausible.io dashboard

One of the most appealing aspects of Plausible.io is its clean, single-page dashboard. When you log in and select your website, you’re presented with all the key information at a glance. Here’s what you’ll typically see and how to interpret it:

  • Unique visitors: This shows the number of individual people who have visited your site within the selected time period (e.g., today, last 7 days, last 30 days). Plausible counts unique visitors without cookies, using an anonymized daily identifier based on IP address and User-Agent, which is then hashed and salted (the salt rotates daily, so individuals cannot be tracked across days).
  • Total pageviews: The total number of pages viewed. If one visitor views three pages, that counts as three pageviews.
  • Bounce rate: The percentage of visitors who navigate away from your site after viewing only one page. A high bounce rate might indicate that visitors aren’t finding what they expect, or that the page isn’t engaging enough. However, context is key – a blog post might have a high bounce rate if people read it and leave satisfied.
  • Visit duration: The average amount of time visitors spend on your site during a session. Longer durations can suggest higher engagement.
  • Top sources: This shows where your visitors are coming from (e.g., Google, social media sites like Twitter or Facebook, other websites linking to you, or direct visits). This is crucial for understanding which marketing channels are most effective.
  • Top pages: The most viewed pages on your website. This helps you identify your most popular content and areas that might need more attention or promotion.
  • Countries: A breakdown of visitors by country, helping you understand your geographical reach.
  • Devices: Shows whether visitors are using desktop, mobile, or tablet devices. This is important for ensuring your website is optimised for all screen sizes.
  • Browsers & operating systems: Information about the technology your visitors are using.

Interpreting these metrics for actionable insights involves looking for trends and asking questions. For example:

  • If you see a spike in visitors from a particular source after a campaign, you know that campaign was effective.
  • If a key landing page has a very high bounce rate, you might need to improve its content, clarity, or call to action.
  • If most of your visitors are on mobile, ensuring a flawless mobile experience is paramount.

2.4. Tracking what matters: Creating custom goals in Plausible.io

While the default metrics in Plausible are useful, the real power for charities comes from tracking specific actions that align with your mission. These are your “goals” or “conversions.” In Plausible, these are typically tracked as Custom events.

Why are custom goals essential? They allow you to measure things like:

  • How many people clicked your “Donate Now” button.
  • How many successfully submitted a volunteer application form.
  • How many subscribed to your newsletter.
  • How many downloaded your annual impact report.

How to set up custom event goals:

Plausible makes tracking custom events very straightforward using a simple JavaScript function: plausibleEvent('EventName');

You trigger this function when a user performs the action you want to track. The EventName is a descriptive name you choose for your goal (e.g., DonateClick, VolunteerSignup, NewsletterSubscription).

Worked example: Tracking a custom donation goal (Button Click)

Let’s say you have a “Donate Now” button on your website. This button might link to an external donation platform (like JustGiving) or to a dedicated donation page on your site. We want to track how many times this button is clicked, as it’s a key step in the donation process.

  1. Identify your button: First, you need to be able to target your button in HTML. Let’s assume your button has an ID: html <button id="donateButton">Donate Now</button> Or, if it’s a link styled as a button: html <a href="your-donation-platform-link" id="donateLinkAsButton" class="button-style">Donate Now</a>

  2. Add the JavaScript to trigger the event: You need to call plausibleEvent() when this button is clicked. You can do this in a couple of ways:

    • Inline onclick (simpler for basic cases): html <button id="donateButton" onclick="plausibleEvent('DonateButtonClick');">Donate Now</button> Or for the link: html <a href="your-donation-platform-link" id="donateLinkAsButton" class="button-style" onclick="plausibleEvent('DonateButtonClick');">Donate Now</a> Important note for links: If the link navigates away immediately, the plausibleEvent might not have time to fire. A common practice is to add a slight delay or use a callback if Plausible’s script supports it for ensuring the event is sent. However, for simple outbound clicks, Plausible is usually quick enough. For more complex scenarios or if you want to pass properties, you might use a JavaScript event listener.

    • Using a JavaScript event listener (more robust, especially if you can’t modify HTML directly or have multiple such buttons): You would add this script preferably in a global JavaScript file or within <script> tags after your button HTML and the main Plausible script. javascript document.addEventListener('DOMContentLoaded', function() { const donateButton = document.getElementById('donateButton'); // Or 'donateLinkAsButton' if (donateButton) { donateButton.addEventListener('click', function() { plausibleEvent('DonateButtonClick'); // If it's a link and you need to ensure event fires before navigation, // you might do: // event.preventDefault(); // Stop immediate navigation // plausibleEvent('DonateButtonClick', { callback: function() { window.location.href = donateButton.href; } }); // However, Plausible's default event is usually fast. Test this. }); } }); For the plausibleEvent function, you can also pass props: plausibleEvent('EventName', { props: { key: 'value' } }); and a callback: plausibleEvent('EventName', {callback: function() { alert('Event tracked!'); } });

  3. Configure the goal in Plausible.io:

    • Go to your website’s settings in your Plausible.io dashboard.
    • Scroll down to the “Goals” section and click “+ Add goal”.
    • Select “Custom event” as the goal type.
    • In the “Event name” field, enter the exact name you used in your JavaScript function (e.g., DonateButtonClick).
    • Click “Create goal”.

Viewing your custom goals:

Once set up and after users start triggering the event, your custom goal will appear in the “Goals” section of your Plausible dashboard. You’ll see how many times the event has been triggered, and Plausible will calculate a conversion rate for it based on your total visitors. This provides a clear view of how effectively you’re guiding users towards key actions.

By combining the standard insights from Plausible with custom goal tracking, even small charities can gain a powerful understanding of their website’s performance and make informed decisions to better serve their cause, all while championing user privacy.

Part 3: Diving deeper with Google Analytics 4 (GA4)

While Plausible.io offers a fantastic, privacy-first approach to web analytics, there are times when a charity might need or prefer the more extensive feature set of Google Analytics. Google Analytics 4 (GA4) is Google’s latest iteration of its powerful analytics platform. It comes with a steeper learning curve than Plausible but offers deeper insights, more customisation options, and robust integration with other Google services like Google Ads, which can be beneficial for charities running awareness or fundraising campaigns.

3.1. Introduction to Google Analytics 4

Google Analytics 4 is a significant evolution from its predecessor, Universal Analytics (UA). The most fundamental change is its data model: GA4 is entirely event-based. This means that every interaction a user has with your website—from viewing a page to clicking a button or watching a video—is tracked as an “event.” This model is more flexible and designed to provide a more unified view of user journeys across websites and apps (though our focus here is on websites).

Why might a charity choose GA4?

  • Advanced features: GA4 offers more sophisticated analysis tools, including predictive metrics (like purchase probability or churn probability, which could be adapted to donation likelihood with enough data), enhanced segmentation, and more detailed reporting capabilities.
  • Integration with Google ecosystem: If your charity uses Google Ads, GA4 provides seamless integration, allowing you to measure the effectiveness of your ad campaigns and create remarketing audiences.
  • Familiarity (for some): Teams already accustomed to the Google Analytics environment might find it a natural, albeit updated, platform to use.
  • It’s free (with limits): Like its predecessor, GA4 is free to use, which is a significant plus for budget-conscious charities. However, there are data processing and storage limits for very high-traffic sites.

The key trade-off with GA4, as we’ll discuss in detail in Part 4, is that it uses cookies and collects more extensive user data by default. This means that to use GA4 in compliance with UK GDPR and PECR, you must obtain user consent before any tracking begins. This is a critical difference from Plausible.io.

3.2. Setting Up Your GA4 Property

Getting started with GA4 involves creating an account (if you don’t already have a Google Analytics account) and then setting up a GA4 property for your website.

Here’s a step-by-step guide:

  1. Create or access your Google Analytics account:
    • Go to analytics.google.com.
    • If you’re new, click “Start measuring.” If you have an existing Google Analytics account (perhaps from Universal Analytics), sign in.
  2. Create a New GA4 Property:
    • In the Admin section (click the gear icon ⚙️ in the bottom-left), if you’re creating a brand new account, you’ll be guided to create a property. If you have an existing account, click “Create Property” in the Property column.
    • Property name: Give your property a descriptive name (e.g., “Your Charity Website GA4”).
    • Reporting time zone and currency: Select your charity’s reporting time zone and currency. This is important for accurate data interpretation.
    • Business details (optional but recommended): Provide information about your industry category (e.g., “Nonprofit”) and business size. This helps Google tailor some of your default reports.
    • Business Objectives: Select how you intend to use Google Analytics (e.g., “Generate leads,” “Raise brand awareness”). This can also influence the default reports you see.
    • Click “Create.” You may need to accept the Google Analytics Terms of Service.
  3. Set up a data stream for your website:
    • After creating the property, you need to set up a “data stream.” This is the source from which GA4 will collect data. For a website, you’ll choose “Web.”
    • Website URL: Enter your website’s URL (e.g., https://yourcharity.org.uk).
    • Stream Name: Give your stream a name (e.g., “Your Charity Website Stream”).
    • Enhanced measurement: This feature is enabled by default and automatically tracks certain common user interactions like page views, scrolls, outbound clicks, site search, video engagement, and file downloads. Review these settings (by clicking the gear icon within the Enhanced Measurement section) and disable any you don’t want or need. For charities, most of these are useful.
    • Click “Create stream.”
  4. Find your measurement ID:
    • Once the web stream is created, you’ll see a “Web stream details” page. Your Measurement ID (which looks like G-XXXXXXXXXX) will be displayed in the top right. This ID is crucial for connecting your website to your GA4 property.

3.3. Implementing GA4 Tracking: Two main approaches

With your Measurement ID in hand, you now need to add the GA4 tracking code to your website. There are two primary ways to do this. Remember, whichever method you choose, the tracking code should only be activated after you have obtained user consent for analytics cookies (more on this in Part 4).

Approach 1: Directly adding the GA4 tag (gtag.js)

This method involves adding the Google Analytics global site tag (gtag.js) directly to the HTML of every page on your website. This is similar to how you’d add the Plausible script.

  1. Get the gtag.js Snippet: In your GA4 web stream details, under “Installation instructions,” you’ll find the gtag.js snippet. It will look something like this:

    <!-- Google tag (gtag.js) -->
    <script async src="https://www.googletagmanager.com/gtag/js?id=G-XXXXXXXXXX"></script>
    <script>
      window.dataLayer = window.dataLayer || [];
      function gtag(){dataLayer.push(arguments);}
      gtag("js", new Date());
    
      gtag("config", "G-XXXXXXXXXX");
    </script>

    Replace G-XXXXXXXXXX with your actual Measurement ID.

  2. Add to Your Website: Paste this entire snippet into the <head> section of every page on your website. Practical example (Django/Wagtail or similar CMS): As with Plausible, if your CMS allows you to add global HTML to the <head> (e.g., via an admin setting like “Page Header HTML” or by editing a base template), this is where you would place the gtag.js snippet. However, for consent management, you will likely load this script dynamically based on user choice, rather than placing it directly in the static HTML. We’ll cover this in Part 4.

Approach 2: Using Google Tag Manager (GTM)

Google Tag Manager is a free tool that allows you to manage and deploy various marketing and analytics tags (like your GA4 tag) on your website without having to modify the site’s code directly each time. It offers more flexibility, especially for setting up complex event tracking, and is generally the recommended approach if you anticipate using multiple tags or need more control over when and how tags fire.

  1. Set Up Google Tag Manager:
    • Go to tagmanager.google.com.
    • Create an account for your charity and a “container” for your website. The container name is usually your website URL.
    • Select “Web” as the target platform.
    • Once created, GTM will provide you with two code snippets: one to place high in the <head> of your page, and another to place immediately after the opening <body> tag. These snippets need to be on every page of your site. (Again, consent management will affect how these are loaded.)
  2. Create a GA4 Configuration Tag in GTM:
    • Inside your GTM container, go to “Tags” and click “New.”
    • Tag configuration: Choose “Google Analytics: GA4 Configuration” as the tag type.
    • Measurement ID: Enter your GA4 Measurement ID (G-XXXXXXXXXX).
    • You can leave “Send a page view event when this configuration loads” checked if you want standard page view tracking.
    • Triggering: Choose a trigger for when this tag should fire. For basic setup, select the “Initialization - All Pages” or “Consent Initialization - All Pages” trigger (depending on your consent setup strategy). The trigger determines the conditions under which the tag will execute.
    • Name your tag (e.g., “GA4 Configuration - Page View”) and save it.
  3. Publish your GTM container: After setting up your tags and triggers, you need to “Submit” and “Publish” your GTM container for the changes to go live on your website.

Using GTM might seem like an extra step, but it centralises your tag management and makes future tracking implementations much easier, especially if you’re not a developer or prefer a visual interface for setting up tracking logic.

3.4. Custom event tracking and goals in GA4

GA4’s event-based model means that beyond the automatically collected page views and enhanced measurement events, you’ll often want to track specific actions unique to your charity’s goals. These are your custom events, which can then be marked as “conversions” (GA4’s term for goals).

Understanding GA4 event categories:

  • Automatically collected events: These are tracked by default when you install GA4 (e.g., page_view, session_start, first_visit).
  • Enhanced measurement events: If enabled, these track common interactions (e.g., scroll, click for outbound links, file_download, view_search_results).
  • Recommended events: Google provides a list of recommended event names for common scenarios (e.g., login, sign_up, purchase). Using these can help GA4 understand your data better and potentially unlock future reporting features.
  • Custom events: For anything not covered above, you can define your own custom events with names and parameters that make sense for your needs.

Worked example: Tracking a custom donation goal in GA4

Let’s revisit our example of tracking clicks on a “Donate Now” button. We’ll call our custom event custom_donation_click.

Using GTM (Recommended for flexibility):

  1. Create a trigger: This tells GTM when to fire your event tag.
    • In GTM, go to “Triggers” and click “New.”
    • Choose a trigger type. For a button click, “Click - All Elements” or “Click - Just Links” is common.
    • Configure the trigger to fire on “Some Clicks.”
    • Define the condition. If your button has a unique ID (e.g., id="donateButton"), you can use “Click ID equals donateButton”. If it has a specific class (e.g., class="donate-btn"), use “Click Classes contains donate-btn”. You might need to enable built-in click variables (like Click ID, Click Classes) in the “Variables” section of GTM if they aren’t available.
    • Name your trigger (e.g., “Click - Donate Button”) and save.
  2. Create a GA4 event tag: This tells GTM what data to send to GA4.
    • Go to “Tags” and click “New.”
    • Tag configuration: Choose “Google Analytics: GA4 Event” as the tag type.
    • Configuration tag: Select your existing GA4 configuration tag (the one you set up for page views).
    • Event Name: Enter your custom event name (e.g., custom_donation_click). Google recommends using snake_case (lowercase with underscores) for event names.
    • Event parameters (optional but useful): You can add parameters to send more context with your event. For a donation click, you might not have a value yet, but if it were a completed donation, you could add donation_value and currency. For a simple click, you might add button_text (using a GTM variable to capture the clicked text).
    • Triggering: Select the trigger you just created (e.g., “Click - Donate Button”).
    • Name your tag (e.g., “GA4 Event - Custom Donation Click”) and save.
  3. Test with GTM preview mode and GA4 DebugView:
    • In GTM, click “Preview” in the top right. Enter your website URL and connect.
    • Your website will open in a new tab with the GTM debug pane at the bottom.
    • Perform the action (click the donate button).
    • In the GTM debug pane, you should see your event tag fire.
    • In your GA4 property, go to “Admin” > “DebugView.” You should see your custom_donation_click event appear in real-time with any parameters you sent.
  4. Publish your GTM container once you’ve confirmed it’s working.

Using gtag.js (Directly in code):

If you’re not using GTM, you can send custom events directly using the gtag() function in your website’s JavaScript. You’d add this code to run when the donate button is clicked:

// Assuming your donate button has id="donateButton"
document.getElementById('donateButton').addEventListener('click', function() {
  gtag('event', 'custom_donation_click', {
    // You can add parameters here if needed, for example:
    // 'event_category': 'Donation',
    // 'event_label': 'Header Donate Button'
  });
});

This script would need to be placed after your main gtag.js configuration snippet, and ideally within your consent management logic.

Registering custom events/parameters as custom definitions in GA4:

For any custom parameters you send with your events (like event_category or event_label in the gtag.js example, or donation_value if you were tracking actual donations), you need to register them as Custom Dimensions or Custom metrics in the GA4 interface if you want to see them in your standard reports or use them in explorations. Event names themselves don’t need to be registered, but their parameters do.

  • In GA4, go to “Admin” > “Custom definitions” (under Data display).
  • Click “Create custom dimensions” (for text-based parameters) or “Create custom metrics” (for numerical parameters).
  • Dimension/metric name: How it will appear in your reports (e.g., “Donation Button Label”).
  • Scope: Choose “Event.”
  • Event parameter: Enter the exact parameter name you used in your GTM tag or gtag.js code (e.g., event_label).
  • Save. It can take up to 24-48 hours for data from custom definitions to appear in reports.

Marking your custom event as a “Conversion” in GA4:

To treat your custom_donation_click event as a key goal, you need to mark it as a conversion in GA4:

  • In GA4, go to “Admin” > “Conversions” (under Data display).
  • Click “New conversion event.”
  • Enter the exact name of your custom event (e.g., custom_donation_click).
  • Save.

Once marked as a conversion, GA4 will specifically track and report on this event as a key outcome for your website.

Viewing your goals/conversions in GA4 reports:

You can see your conversion events in various GA4 reports, including:

  • Reports > engagement > conversions: Shows a summary of all events marked as conversions.
  • You can also add conversion metrics to other reports (like acquisition reports to see which channels drive the most conversions) or build custom reports in the “Explore” section.

Setting up GA4 and custom event tracking involves more steps than Plausible, but it offers a wealth of data for charities ready to dive deeper. The crucial next step, however, is ensuring you do all of this while respecting user privacy and complying with consent regulations, which we’ll tackle in Part 4.

We’ve explored how to set up both Plausible.io and Google Analytics 4 to gather valuable insights. However, when using GA4, there’s a critical extra step for charities operating in the UK (and indeed, the EU): managing cookie consent. This isn’t just a technicality; it’s a legal and ethical obligation that underpins the trust your supporters place in you.

The fundamental reason GA4 requires a cookie notice and consent mechanism, while Plausible.io (in its default configuration) generally doesn’t, boils down to how they collect and process data, particularly their use of cookies and handling of personal data.

Google Analytics 4 and personal data: GA4, by its nature, is designed to provide deep insights into user behaviour. To do this, it typically:

  • Uses Cookies: GA4 sets cookies on a user’s device (e.g., _ga, _ga_<container-id>) to identify unique users and track their sessions and interactions across your website over time. These cookies store identifiers that can be linked back to an individual.
  • Collects personal data: Beyond cookie identifiers, GA4 can collect other information that may be considered personal data under GDPR, such as IP addresses (though GA4 offers IP anonymisation, the initial collection still occurs), detailed user interaction data, device information, and potentially demographic data if linked with other Google services or signals. This data can be used for analysis, reporting, and, if integrated with Google Ads, for advertising and remarketing purposes.

The UK legal landscape: GDPR and PECR Two key pieces of legislation in the UK govern this area:

  1. PECR (Privacy and Electronic Communications Regulations): PECR specifically addresses the use of cookies and similar technologies. Regulation 6 states that you must tell people if you set cookies and clearly explain what the cookies do and why. Crucially, you must also get the user’s consent to store a cookie on their device. There’s a narrow exception for cookies that are “strictly necessary” for providing an online service requested by the user (e.g., a cookie to remember items in a shopping basket), but analytics cookies, especially those used by GA4 for tracking and profiling, almost always fall outside this exception.
  2. UK GDPR (General Data Protection Regulation): When the data collected via cookies (or other means) constitutes personal data (which it does with GA4), then UK GDPR applies. GDPR requires a lawful basis for processing personal data. For analytics cookies that are not strictly necessary, the most appropriate lawful basis is consent. This consent must be freely given, specific, informed, and an unambiguous indication of the individual’s wishes, typically given by a clear affirmative action (e.g., clicking an “Accept” button).

Plausible.io’s privacy-focused approach: In contrast, Plausible.io is designed to avoid these requirements for its core analytics function:

  • No cookies by default: Plausible does not use cookies. It measures unique visitors by generating a daily changing, anonymised identifier using a hash of the visitor’s IP address, User-Agent, and a daily rotating salt. The raw IP address is not stored.
  • No collection of personal data (for core analytics): It doesn’t collect personally identifiable information. The data is aggregated and anonymised, focusing on overall trends rather than individual user tracking across different sites or long periods.

Because Plausible avoids cookies and the collection of personal data in its standard setup, it generally doesn’t trigger the same consent requirements under PECR and GDPR for basic website analytics. This is why you can often use Plausible without a cookie consent banner, simplifying the user experience and your compliance overhead.

This is a non-negotiable rule: No non-essential cookies (including those for GA4) should be set, and no related personal data should be collected, before you have obtained explicit, informed consent from the user.

This means your GA4 tracking scripts (whether gtag.js or Google Tag Manager) should not load or fire when a user first lands on your website. They should only be activated after the user has made an active choice to accept analytics cookies.

What constitutes valid consent under UK GDPR?

  • Freely given: Users must not be pressured into consenting, and not consenting should not lead to a detriment (e.g., denying access to your website, though access to certain non-essential features could be conditional).
  • Specific: Consent should be obtained for specific purposes. If you use cookies for analytics, advertising, and functional purposes, you should ideally allow users to consent to these categories separately.
  • Informed: Users must be provided with clear, concise information about what they are consenting to – what cookies will be used, by whom, for what purposes, and for how long. This information should be easily accessible.
  • Unambiguous indication: Consent must be given by a clear affirmative action. Pre-ticked boxes or implied consent (e.g., “by continuing to use this site, you consent to cookies”) are not valid.

4.3. A practical solution: Using privacy-choices

Implementing a compliant cookie consent mechanism can seem complex. Fortunately, there are tools available to help. One such open-source solution, which aligns with the practical, hands-on approach of this guide, is the privacy-choices JavaScript library created by Ben Thomson (GitHub: benjeh32/privacy-choices). It’s designed to be a straightforward way to give users clear choices about web storage.

Introduction to privacy-choices: This library provides the front-end components and logic to display a consent banner and manage user preferences. It’s particularly useful because it’s lightweight, customisable, and offers callbacks that allow you to control when other scripts (like your GA4 tags) are loaded.

Key features of privacy-choices:

  • Notification banner: Prompts users to make their choices when they first visit.
  • Equal-weighted options: Typically presents clear accept/deny or manage options, avoiding manipulative design patterns.
  • Settings panel: Allows users to make granular choices if you define different categories of cookies (e.g., Necessary, Analytics, Marketing).
  • Customisable Categories: You can define the categories relevant to your website.
  • JavaScript callbacks: This is the crucial feature for us – it allows you to execute your own code (like loading GA4) based on the user’s choices.
  • Stores preferences: Remembers user choices in a cookie so they aren’t asked on every page or every visit (until the preference cookie expires, which is also configurable).

How to implement privacy-choices (basic guide for GA4):

  1. Get the library:

    • You can download the privacy-choices.bundle.js file from the releases page of the GitHub repository.
    • Host this file on your web server so your website can access it.
  2. Add the Script Tag to your website:

    • Include the script at the bottom of your <body>, before any other scripts that depend on consent (or before your closing </body> tag).
    <script src="/path/to/your/privacy-choices.bundle.js"></script>
  3. Initialise and configure the library:

    • After including the library, you need to initialise it with your desired configuration. This is where you’ll define your cookie categories and set up the callbacks to load GA4.

    Configuration for GA4: Here’s an example of how you might configure privacy-choices to handle consent for Google Analytics:

    // Place this script after the privacy-choices.bundle.js script tag
    // or in your main site JavaScript file that loads after it.
    
    // Function to load your GA4 tracking code (either gtag.js or GTM)
    function loadGa4() {
        console.log("Analytics consent given. Loading GA4...");
        // ** OPTION 1: If using gtag.js directly **
        // Check if script already exists to prevent multiple loads
        if (!document.getElementById('ga4-gtag-script')) {
            const gaScript = document.createElement('script');
            gaScript.id = 'ga4-gtag-script';
            gaScript.async = true;
            gaScript.src = 'https://www.googletagmanager.com/gtag/js?id=G-XXXXXXXXXX'; // Replace G-XXXXXXXXXX
            document.head.appendChild(gaScript);
    
            const gaInlineScript = document.createElement('script');
            gaInlineScript.id = 'ga4-inline-script';
            gaInlineScript.innerHTML = `
                window.dataLayer = window.dataLayer || [];
                function gtag(){dataLayer.push(arguments);}
                gtag('js', new Date());
                gtag('config', 'G-XXXXXXXXXX'); // Replace G-XXXXXXXXXX
            `;
            document.head.appendChild(gaInlineScript);
        }
    
        // ** OPTION 2: If using Google Tag Manager **
        // (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
        // new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
        // j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
        // 'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
        // })(window,document,'script','dataLayer','GTM-XXXXXXX'); // Replace GTM-XXXXXXX
        // Note: For GTM, you'd also need to configure GTM's consent mode features
        // to respect the choices made via privacy-choices, or ensure tags only fire
        // when this loadGa4() function is called.
    }
    
    function unloadGa4() {
        console.log("Analytics consent NOT given or revoked. Ensure GA4 is not active.");
        // Logic to disable GA4 if it was loaded, or prevent it from sending data.
        // For gtag.js, you can set a window flag that gtag uses to deny consent:
        // window['ga-disable-G-XXXXXXXXXX'] = true;
        // For GTM, this is more complex and usually handled by GTM's consent mode settings.
        // Simplest for this guide: ensure it's not loaded if consent isn't given initially.
        const gaScript = document.getElementById('ga4-gtag-script');
        if (gaScript) gaScript.remove();
        const gaInlineScript = document.getElementById('ga4-inline-script');
        if (gaInlineScript) gaInlineScript.remove();
        // Add similar removal for GTM scripts if dynamically loaded
    }
    
    PrivacyChoices.init({
        banner: {
            text: "We use cookies to understand how you use our site and to improve your experience. This includes personalizing content. By choosing \"Accept All\", you consent to our use of cookies.",
            acceptButton: {
                text: "Accept All"
            },
            denyButton: {
                text: "Reject All"
            },
            settingsButton: {
                text: "Cookie Settings"
            }
        },
        settings: {
            title: "Cookie Preferences",
            text: "We use different types of cookies. You can choose which categories to allow. For more information, please see our [Privacy Policy](your-privacy-policy-url.html).", // Link to your privacy policy
            categories: [
                {
                    id: 'necessary',
                    name: 'Strictly Necessary Cookies',
                    description: 'These cookies are essential for the website to function and cannot be switched off in our systems. They are usually only set in response to actions made by you which amount to a request for services, such as setting your privacy preferences, logging in or filling in forms.',
                    // 'tools': ['Session Cookie', 'Security Cookie'], // Optional
                    // 'checked': true, // Default for necessary
                    // 'disabled': true // Default for necessary
                },
                {
                    id: 'analytics',
                    name: 'Analytics Cookies',
                    description: 'These cookies allow us to count visits and traffic sources so we can measure and improve the performance of our site. They help us to know which pages are the most and least popular and see how visitors move around the site. All information these cookies collect is aggregated and therefore anonymous. If you do not allow these cookies we will not know when you have visited our site, and will not be able to monitor its performance.',
                    tools: ['Google Analytics'],
                    checked: false // Default to not checked
                }
                // You could add other categories like 'marketing' if applicable
            ]
        },
        callbacks: {
            onSave: function (preferences) {
                console.log("User saved choices:", preferences);
                if (preferences.analytics) {
                    loadGa4();
                } else {
                    unloadGa4(); // Or ensure it's not loaded / GTM respects this
                }
            },
            onInit: function(preferences) {
                // This callback fires when the library initialises and loads existing preferences.
                // Useful for loading scripts on subsequent page loads if consent was already given.
                console.log("PrivacyChoices initialized. Current preferences:", preferences);
                if (preferences.analytics) {
                    loadGa4();
                }
            }
        },
        cookie: {
            name: 'charityPrivacyChoices',
            expiry: 90 // Days until consent is asked again
        }
    });
    </script>

    Key things in this example:

    • We define an analytics category.
    • The onSave callback checks if the user consented to analytics cookies. If yes, loadGa4() is called. If not, unloadGa4() (or logic to prevent loading) is called.
    • The onInit callback ensures that if consent was previously given (and preferences are loaded from the privacy-choices cookie), GA4 is loaded on page load.
    • Crucially, your main GA4 script (gtag.js or GTM) should NOT be present in your static HTML <head> if you use this dynamic loading method. It must only be loaded via the loadGa4() function after consent.

This is a simplified example. The privacy-choices library has more customisation options for text, colours, and behaviour. You’ll need to adapt the loadGa4() and unloadGa4() functions based on whether you’re using gtag.js directly or GTM, and how you manage script loading on your specific website platform.

Implementing cookie consent correctly is vital. While tools like privacy-choices can greatly assist, always ensure your implementation aligns with the latest guidance from the Information Commissioner’s Office (ICO) in the UK. This careful approach not only ensures compliance but also demonstrates to your supporters that you take their privacy seriously – a cornerstone of trust for any charity.

Part 5: You’re all set (But we’re here to help!)

Navigating the world of website analytics can feel like a significant undertaking, especially when balancing the drive for insights with the crucial responsibility of respecting user privacy. We hope this guide has demystified the process and provided you with practical, actionable steps to harness the power of data for your charity. From understanding what truly matters in your metrics to implementing tools like Plausible.io and Google Analytics 4, you now have a roadmap to better understand your supporters and enhance your online impact.

5.1. Recap: Key takeaways for your charity

As we conclude, let’s quickly revisit the core messages we’ve explored together:

  • Focus on actionable metrics: Move beyond vanity numbers. The most valuable data is that which informs your decisions and helps you take concrete steps towards achieving your charity’s mission. Define what success looks like for your online efforts – be it donations, volunteer sign-ups, or awareness raised – and track the metrics that directly reflect that success.
  • Plausible.io for simple, privacy-first analytics: If you’re looking for a straightforward, easy-to-use analytics tool that respects user privacy by default and generally doesn’t require a cookie consent banner, Plausible.io is an excellent choice. Its simplicity and focus on essential metrics make it a great starting point or a long-term solution for many charities.
  • Google Analytics 4 for more power (with careful consent management): For charities needing deeper analytical capabilities, more extensive customisation, or integration with the broader Google ecosystem, GA4 is a powerful option. However, its use of cookies and collection of personal data mean that robust, transparent cookie consent management, implemented before any tracking begins, is an absolute necessity in the UK and EU.
  • The paramount importance of respecting user privacy: Regardless of the tools you choose, remember that trust is the bedrock of your relationship with your supporters. Always prioritise their privacy, be transparent about how you use data, and comply with all relevant regulations like UK GDPR and PECR. Ethical data handling is not just a legal requirement; it’s a reflection of your charity’s values.

5.2. Your next steps

Armed with this knowledge, we encourage you to take a fresh look at your current website analytics setup. Are you tracking what truly matters? Are you respecting your users’ privacy choices? Is there an opportunity to gain clearer insights that could help you better serve your community and advance your cause?

Perhaps you’ll start by defining a few key actionable metrics for your main campaigns. Maybe you’ll decide to trial Plausible.io for its simplicity or begin the process of implementing GA4 with a compliant consent solution like privacy-choices. Whatever your path, remember that the journey to becoming data-informed is an ongoing one, filled with opportunities for learning and improvement.

We understand that this can still feel like a lot to take in, and every charity’s situation is unique. You’re all set with the foundational knowledge – but if you need help, we’re here to support in guiding your metrics journey. Don’t hesitate to seek further advice, explore the resources linked throughout this guide, and connect with others in the non-profit sector who are also navigating these challenges. By working together and sharing our learnings, we can all become more effective in using digital tools to make a positive difference in the world.


References