Roych Posted April 10 Posted April 10 Hi everyone, I’m happy to share NativeAnalytics, a native first-party analytics module for ProcessWire. The module is now available in the ProcessWire modules directory: https://processwire.com/modules/native-analytics/ NativeAnalytics provides a useful analytics dashboard directly inside the ProcessWire admin, without relying on external analytics platforms, third-party scripts or external APIs. All analytics data is stored locally in your ProcessWire installation, which makes it a good fit for projects where you want a simpler, more self-contained analytics solution. The module currently tracks and displays: page views unique visitors sessions current visitors top pages referrers devices and browsers 404 hits engagement events such as form submits, downloads, tel/mail clicks, outbound clicks and custom CTA events It also includes: charts and trend views comparison between periods custom date range filtering page-level analytics inside the page edit screen optional monthly email reports optional PDF report attachments exports to CSV, PDF and DOCX helper examples and a small snippet generator for custom event tracking New in the latest version: Goals and conversion tracking event-based goals, for example form submits, CTA clicks, downloads or tel/mail clicks page/path-based goals, for example thank-you pages or booking confirmation pages conversion rate reporting based on sessions and unique visitors a dedicated Goals dashboard with goal cards, goal trends and goal overview easier goal setup with helper text, quick presets and suggestions from already tracked events and pages daily aggregate tables for events and goals raw event retention setting additional database indexes and cleanup helpers for larger datasets There are also several privacy and consent-related options: optional cookie-less visitor/session mode consent-based tracking helper functions for custom consent integrations optional PrivacyWire localStorage consent helper support cleaner behaviour when global tracking is disabled The reason I built this module was that I wanted something that feels natural inside ProcessWire itself, instead of embedding another analytics service into the admin. For many sites, it can be useful to have core traffic, engagement and conversion data available right where content is managed. Goal tracking was added because several users asked for a simple way to measure important actions without having to fight with external analytics tools. For example, you can now create a goal for a contact form submit, a CTA button click, a file download or a visit to a thank-you page, and then see conversions and conversion rates directly in the ProcessWire admin. A small note about very large datasets: NativeAnalytics includes retention settings, daily aggregate tables and cleanup tools, and the latest version improves this further for events and goals. For very high-traffic sites, I still recommend using sensible raw data retention and keeping long-term reporting based on aggregated data. I do not want to overclaim without real long-term benchmarks on extremely large datasets, so feedback from larger installations is very welcome. ! If you tested one of the earlier development versions named PW Native Analytics, I recommend uninstalling that old test version first and installing NativeAnalytics as a fresh module, because the module name and structure changed during development. Multi-site analytics is not included yet, but it is something I am looking into. It would need proper per-site separation in the stored analytics data, so I want to approach that carefully rather than adding a quick workaround. Feedback, bug reports and suggestions are very welcome. Get it here: https://processwire.com/modules/native-analytics/ Enjoy! If you find NativeAnalytics useful and would like to support further development, maintenance and testing, a small donation is always appreciated. The module will remain free, but support helps me spend more time improving it and adding new features. DONATE 23 3
szabesz Posted April 11 Posted April 11 On 4/10/2026 at 7:53 PM, Roych said: Download it Here: PwNativeAnalytics.zip Thank you for sharing! Are you planning to add it to the Module Directory? 1
Roych Posted April 12 Author Posted April 12 Small update on PW Native Analytics I made a few refinements to improve usability and setup: cleaned up and improved the module settings added short text descriptions to make technical options easier to understand improved the date format setting so it now offers cleaner and more useful format choices made important beginner-friendly options enabled by default on install, such as: Enable tracking Enable event tracking Respect Do Not Track Ignore query strings in stored paths This makes the module easier to understand and ready to use immediately after installation, especially for less technical users. thx to matjazp for feedback 😉 I updated the file in first post! Cheers 4
Roych Posted April 14 Author Posted April 14 On 4/11/2026 at 9:42 PM, szabesz said: Thank you for sharing! Are you planning to add it to the Module Directory? I wasn't realy planning to, we'll see! R 2
MrSnoozles Posted April 23 Posted April 23 Very cool. How difficult do you think it would be to make it multi-site compatible? So that when the structure is like this: /root /website 1 /website 2 /website 3 Each website could get its own analytics. Would it be a major refactor or do you see it easily doable? @Roych
Stefanowitsch Posted April 27 Posted April 27 @Roych thanks! This is a really nice and clean module that integrates straight into the backend. I just installed it on a client site and its already filling with interesting data. @ai_slop I was able to make this module work together with PrivacyWire since I am inside the EU. If consent is chosen the cookie is set and the module activates. 4
Mikel Posted May 10 Posted May 10 On 4/27/2026 at 8:58 AM, Stefanowitsch said: I was able to make this module work together with PrivacyWire since I am inside the EU. If consent is chosen the cookie is set and the module activates. Hi, @Stefanowitsch, I´m curious: Do you hook into a PrivacyWire method or do you use its built in custom function trigger? We simply have set up a script that checks the local storage for the privacywire key. Then a cookie for Native Analytics is set or unset depending on its "statistics" value. Cheers, Mike
Stefanowitsch Posted May 11 Posted May 11 Hi @Mikel I use a custom JavaScript function (that name is entered in the PrivacyWire module settings) to check for consent and then set the cookie for activating NativeAnalytics: function initNativeAnalytics() { const consent = JSON.parse(localStorage.getItem('privacywire')); //console.log(consent); if (consent && (consent.cookieGroups.statistics || consent.cookieGroups.marketing)) { document.cookie = "pwna_consent=1; path=/; max-age=" + (60*60*24*365) + "; SameSite=Lax"; if (window.PWNA && typeof window.PWNA.trackIfConsented === 'function') { window.PWNA.trackIfConsented(); } } else { document.cookie = "pwna_consent=; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT"; } } 1
Roych Posted May 12 Author Posted May 12 NativeAnalytics v1.0.19 – update This release mainly focuses on privacy/consent handling and admin UI polishing. Added / improved: Added optional cookie-less visitor/session mode for sites that want to avoid browser visitor/session cookies. Added PrivacyWire localStorage consent helper support. Added helper methods for custom consent integrations: window.PWNA.trackIfConsented() window.PWNA.setConsent() window.PWNA.clearConsent() window.PWNA.syncPrivacyWireConsent() Improved consent-based tracking flow, so tracking can start correctly after consent is granted. Tracking-related settings are now hidden/disabled when global tracking is turned off, to avoid confusing combinations like “tracking off + event tracking on”. Added a module settings shortcut button in the analytics dashboard header. Improved AdminTheme compatibility and tab spacing across ProcessWire admin themes. Polished the flat admin UI and removed rounded corners. Fixed panel alignment issues in dashboard grid layouts, especially where side-by-side panels appeared vertically offset. Note: Multi-site analytics is not included yet. It is planned as a possible future improvement because it needs proper per-site separation in stored analytics data. Download is updated in first post! 3 2
Mikel Posted May 12 Posted May 12 Thank you very much for adressing this, @Roych! Would it be possible that you release the module either here in the Modules Section and/or on Github? Either way it would simplify the upgrade process of your wonderful module to a one-click action (ProcessUpgrades) or fully automatic (GitSync). Cheers, Mike
Roych Posted May 12 Author Posted May 12 1 hour ago, Mikel said: Thank you very much for adressing this, @Roych! Would it be possible that you release the module either here in the Modules Section and/or on Github? Either way it would simplify the upgrade process of your wonderful module to a one-click action (ProcessUpgrades) or fully automatic (GitSync). Cheers, Mike I just did, but still waiting for approval. Cheers R 1 1
Roych Posted May 19 Author Posted May 19 I’ve just uploaded a new version of NativeAnalytics 1.0.20. This update mainly focuses on monthly reporting, privacy options, engagement tracking improvements and some smaller admin UI refinements. Added / improved Added optional monthly email reports Added Send test report now option in module settings Added report preview before sending Added optional PDF report attachment Improved page-level analytics summary inside Page Edit Added a setting to show/hide the Page Edit analytics summary Improved spacing and styling of the Page Edit analytics block Improved engagement event tracking, especially form submit tracking Added better cache-busting for updated tracker/admin assets Added module info files so the ProcessWire modules directory and Upgrade module can detect the version correctly Added support links to the module info array The module should now also be upgradeable through the ProcessWire Upgrade module once the modules directory has refreshed the latest version. The current version is 1.0.20. Special thanks to matjazp for testing the module and reporting useful issues along the way. The feedback helped a lot with polishing the module and making it more reliable in real-world use. P 3
HMCB Posted 22 hours ago Posted 22 hours ago Whoa! This seems like a monumentally great module. Just blown away. Thank you!
HMCB Posted 22 hours ago Posted 22 hours ago I am just reading about this but just in case: Can you make event tracking easy? Google Analytics makes it so hard to see when a button or other action is taken. Having this built into PW and super easy to implement would be a godsend. 1
David Karich Posted 18 hours ago Posted 18 hours ago @Roych It looks promising so far. Thanks for the module. Custom event tracking and goal tracking are features I personally would still like to see. Plus conversion rates based on that data. Have you already run a performance test using long-term data and a large number of visitors? How does this scale over the long term? For example: I have sites with 6 million unique visitors per year and a tracking history spanning 15 years. Does the module still run stably with such large data volumes? 1
Roych Posted 1 hour ago Author Posted 1 hour ago Thanks for the feedback. 21 hours ago, HMCB said: Can you make event tracking easy? Google Analytics makes it so hard to see when a button or other action is taken. Having this built into PW and super easy to implement would be a godsend Yes, easy event tracking is already built into NativeAnalytics. The module can automatically track common engagement actions such as form submits, downloads, mailto/tel clicks and outbound links. For custom CTA buttons or other actions you can add simple data attributes like data-pwna-event, data-pwna-group and data-pwna-label. 16 hours ago, David Karich said: Custom event tracking and goal tracking are features I personally would still like to see. Plus conversion rates based on that data. Have you already run a performance test using long-term data and a large number of visitors? How does this scale over the long term? For example: I have sites with 6 million unique visitors per year and a tracking history spanning 15 years. Does the module still run stably with such large data volumes? Based on the feedback, I have also added a new Goals section for the next release (This was already on the list and partialy done, thanks for the kick ... 😉 ). Goals can be created from tracked events or from page/path rules, for example a thank-you page, a form submit, a CTA click or a download. The dashboard then shows conversions, converted sessions, unique visitors and conversion rates. Regarding very large datasets, I do not want to overclaim without real long-term benchmarks at that scale. The module includes retention options, daily aggregate tables and cleanup tools, and the next release improves this further for events and goals. For very high-traffic sites, the recommended approach is to keep raw data only for a limited period and use aggregate data for long-term reporting. Wait for the update refresh 😉 New version is now v1.0.21. Thank you R
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now