=== Loglyuk Privacy Analytics ===
Contributors: loglyuk
Tags: analytics, privacy, GDPR, cookie-free, lightweight
Requires at least: 5.0
Tested up to: 7.0
Requires PHP: 7.4
Stable tag: 1.0.2
License: GPL-2.0+
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Privacy-first analytics under 1 KB. No cookies, no consent banner, works with Brave and uBlock Origin.

== Description ==

**Loglyuk Privacy Analytics** connects your WordPress site to Loglyuk (logly.uk), a lightweight web analytics service that tracks your visitors without cookies, without storing personal data, and without requiring a consent banner.

= Why Loglyuk? =

* **Under 1 KB** — zero impact on your Lighthouse score or Core Web Vitals
* **No cookie banner required** — no persistent identifiers, GDPR compliant by design
* **Works with ad blockers** — including Brave Shields and uBlock Origin
* **Active time on page** — measures real reading time, not just tab-open time
* **Free plan** — 10,000 pageviews/month, forever, no credit card

= What you get =

* Pageviews, sessions, visitors
* Top pages and referrers
* Countries, devices, browsers
* Active visitors right now
* Week-over-week comparison

= Setup =

1. Install and activate the plugin
2. Go to **Loglyuk** in the WordPress admin sidebar
3. Enter your Site ID from [app.logly.uk](https://app.logly.uk)
4. Done — no tag manager, no configuration file

== Installation ==

1. Upload the `loglyuk-privacy-analytics` folder to `/wp-content/plugins/`
2. Activate the plugin via **Plugins → Installed Plugins**
3. Go to **Loglyuk** in the admin sidebar and enter your Site ID

== Frequently Asked Questions ==

= Do I need a cookie banner? =

No. Loglyuk does not set cookies or store personal data, so no consent banner is required under GDPR or PECR.

= Does it work with Brave or ad blockers? =

Yes. Loglyuk is designed to work with Brave Shields, uBlock Origin, and Firefox Enhanced Tracking Protection.

= Where do I find my Site ID? =

In your Loglyuk dashboard at [app.logly.uk](https://app.logly.uk) — go to Settings for your site and copy the ID from the installation snippet.

= Is there a free plan? =

Yes. Free forever up to 10,000 pageviews/month, no credit card required.

== External services ==

This plugin loads a tracking script from Loglyuk (https://logly.uk) and sends pageview data to Loglyuk's servers so you can view analytics for your site. Loglyuk is a privacy-first web analytics service operated at logly.uk.

**What is sent and when:** every time a visitor loads a page on your site, the tracker script (loaded from `https://logly.uk/p.js`) sends a small GET request to `https://logly.uk/e` containing only:

* the page path being viewed
* an anonymous session hash (derived from IP + User-Agent + a daily-rotating salt; not reversible, not stored)
* the visitor's country (resolved from IP at the edge; the IP itself is never stored)
* device, browser and OS family (e.g. "Mobile / Chrome / Android")
* the referrer URL, if any
* your Site ID (so Loglyuk knows which property the pageview belongs to)

No cookies are set, no personal data is stored, and no consent banner is required under GDPR or PECR.

**When this happens:** only after you configure the plugin with a Site ID in the Loglyuk admin page. Without a Site ID, the plugin sends nothing.

**Reading your analytics in wp-admin:** when you open the Loglyuk admin page, the plugin fetches your aggregated, non-personal statistics (totals, top pages and referrers) from Loglyuk's public API at `https://app.logly.uk/api/public/<your-site-id>/stats` and `/breakdown`, and renders them natively in WordPress. These read-only requests run only on the plugin's admin page and only return data you have explicitly marked Public in your Loglyuk settings.

**Terms and privacy policy:**

* Terms of Service: https://logly.uk/terms
* Privacy Policy: https://logly.uk/privacy

== Screenshots ==

1. Dashboard overview — pageviews trend, sessions, visitors, top pages and referrers, with week-over-week comparison.
2. Custom events with A/B comparison and conversion funnels that show exactly where visitors drop off.
3. Audience insights — countries, devices, browsers, and a user-flow view from source to entry and exit pages.

== Changelog ==

= 1.0.2 =
* Countries, devices and browsers are now shown as donut charts with a percentage legend.

= 1.0.1 =
* The admin dashboard now renders your analytics natively in WordPress via the Loglyuk public API instead of embedding an external iframe.
* Richer overview: pageviews trend chart, plus top pages, referrers, countries, devices and browsers, with a 7/30/90-day range picker.

= 1.0.0 =
* Initial release

== Upgrade Notice ==

= 1.0.2 =
Countries, devices and browsers now display as donut charts.

= 1.0.1 =
Analytics now render natively in wp-admin (no external iframe).

= 1.0.0 =
Initial release.
