[{"data":1,"prerenderedAt":1721},["ShallowReactive",2],{"article-alternates":3,"article-\u002Fru\u002Fdata\u002Fprivacy-first-analytics-plausible-server-side":13},{"i18nKey":4,"paths":5},"data-006-2026-05",{"de":6,"en":7,"es":8,"fr":9,"it":10,"ru":11,"tr":12},"\u002Fde\u002Fdata\u002Fprivacy-first-analytics-plausible-server-aggregation","\u002Fen\u002Fdata\u002Fprivacy-first-analytics-plausible-server-side-aggregation","\u002Fes\u002Fdata\u002Fprivacy-first-analytics-plausible-server-side-aggregation","\u002Ffr\u002Fdata\u002Fanalytique-respectueuse-donnees-confidentielles","\u002Fit\u002Fdata\u002Fprivacy-first-analytics-plausible-server-side-aggregation","\u002Fru\u002Fdata\u002Fprivacy-first-analytics-plausible-server-side","\u002Ftr\u002Fdata\u002Fprivacy-first-analytics-plausible-ve-sunucu-tarafi-aggregation",{"_path":11,"_dir":14,"_draft":15,"_partial":15,"_locale":16,"title":17,"description":18,"publishedAt":19,"modifiedAt":19,"category":14,"i18nKey":4,"tags":20,"readingTime":26,"author":27,"body":28,"_type":1715,"_id":1716,"_source":1717,"_file":1718,"_stem":1719,"_extension":1720},"data",false,"","Privacy-First Analytics: Plausible и Server-Side Aggregation","GDPR-совместимое измерение: Plausible + server-side aggregation для cookieless-трекинга, сравнение с GA4 и архитектура production.","2026-05-19",[21,22,23,24,25],"privacy-first-analytics","plausible","server-side-tracking","cookieless","gdpr-compliance",8,"Roibase",{"type":29,"children":30,"toc":1708},"root",[31,39,46,51,56,101,106,111,135,141,146,151,160,165,405,410,454,459,492,498,503,529,539,743,753,819,824,853,859,864,872,893,901,1598,1606,1624,1629,1635,1640,1648,1666,1674,1692,1697,1702],{"type":32,"tag":33,"props":34,"children":35},"element","p",{},[36],{"type":37,"value":38},"text","Таблица cookies развалилась. Chrome в 2024 году прекратил третьесторонние cookies, Safari и Firefox блокируют их уже годами. Маркетинг-команды видят потерю данных на 40–60% в GA4 (по собственным отчётам Google). Одновременно штрафы GDPR в 2025 году достигли 4,2 млрд евро по Европе. Две проблемы: техническая (без cookies нет измерения) и юридическая (обход consent-баннеров — преступление). Privacy-first analytics решает обе одновременно: измерение без cookies, агрегация на сервере, полная compliance-готовность.",{"type":32,"tag":40,"props":41,"children":43},"h2",{"id":42},"plausible-ядро-cookieless-измерения",[44],{"type":37,"value":45},"Plausible: Ядро Cookieless-Измерения",{"type":32,"tag":33,"props":47,"children":48},{},[49],{"type":37,"value":50},"Когда Plausible появилась в 2019 году, её позиционировали как «альтернатива GA». К 2026 году это целая категория: privacy-first web analytics. Ключевое отличие — события привязываются не к cookie на клиенте, а к session ID на сервере без сохранения в памяти. Комбинация IP + User-Agent генерирует хеш (SHA-256), который обнуляется каждые 24 часа. Результат: точность по уникальным посетителям ≈95%, при этом никакой PII (personally identifiable information).",{"type":32,"tag":33,"props":52,"children":53},{},[54],{"type":37,"value":55},"Сравнение с GA4:",{"type":32,"tag":57,"props":58,"children":59},"ul",{},[60,72,91],{"type":32,"tag":61,"props":62,"children":63},"li",{},[64,70],{"type":32,"tag":65,"props":66,"children":67},"strong",{},[68],{"type":37,"value":69},"Владение данными:",{"type":37,"value":71}," Plausible записывает события в собственный PostgreSQL. GA4 отправляет на серверы Google — ты не можешь запросить напрямую (кроме BigQuery export).",{"type":32,"tag":61,"props":73,"children":74},{},[75,80,82,89],{"type":32,"tag":65,"props":76,"children":77},{},[78],{"type":37,"value":79},"Cookie-зависимость:",{"type":37,"value":81}," GA4 привязана к ",{"type":32,"tag":83,"props":84,"children":86},"code",{"className":85},[],[87],{"type":37,"value":88},"_ga",{"type":37,"value":90}," cookie. Если посетитель отклонит cookie, измерение рассыпается. Plausible изначально cookieless.",{"type":32,"tag":61,"props":92,"children":93},{},[94,99],{"type":32,"tag":65,"props":95,"children":96},{},[97],{"type":37,"value":98},"Размер скрипта:",{"type":37,"value":100}," Plausible tracker — 1,4 KB, GA4 gtag.js — 28 KB + gtm.js — 45 KB. Разница в 50 раз на page load.",{"type":32,"tag":33,"props":102,"children":103},{},[104],{"type":37,"value":105},"Для GDPR compliance критично: хеш Plausible — это не персональные данные. GDPR определяет персональные данные как информацию о «определённом или определяемом физическом лице». SHA-256 хеш необратим, поэтому он считается анонимизированными данными. Согласие не требуется — даже не нужен consent-баннер.",{"type":32,"tag":33,"props":107,"children":108},{},[109],{"type":37,"value":110},"В production Plausible работает в двух сценариях:",{"type":32,"tag":112,"props":113,"children":114},"ol",{},[115,125],{"type":32,"tag":61,"props":116,"children":117},{},[118,123],{"type":32,"tag":65,"props":119,"children":120},{},[121],{"type":37,"value":122},"Standalone:",{"type":37,"value":124}," для малых сайтов (блог, landing page) — достаточно самой себя. 10 строк JS-embed, dashboard готов.",{"type":32,"tag":61,"props":126,"children":127},{},[128,133],{"type":32,"tag":65,"props":129,"children":130},{},[131],{"type":37,"value":132},"Hybrid:",{"type":37,"value":134}," для e-commerce или SaaS — Plausible ловит весь трафик, критические conversion-события идут через server-side GTM в CDP. Этот вариант — фокус статьи.",{"type":32,"tag":40,"props":136,"children":138},{"id":137},"server-side-aggregation-от-события-к-метрике",[139],{"type":37,"value":140},"Server-Side Aggregation: От События к Метрике",{"type":32,"tag":33,"props":142,"children":143},{},[144],{"type":37,"value":145},"Второй столп privacy-first analytics: измерение не по событиям, а по метрикам. GA4 логирует каждый клик, скролл, паузу видео (event stream). На e-commerce сайте это 10 млн событий в день. Это и дорого, и risk для privacy. Aggregation работает просто: события агрегируются на сервере в реальном времени, raw events не сохраняются, только счётчики.",{"type":32,"tag":33,"props":147,"children":148},{},[149],{"type":37,"value":150},"Пример архитектуры:",{"type":32,"tag":152,"props":153,"children":155},"pre",{"code":154},"Client → Plausible Tracker (1.4 KB JS)\n         ↓\n      Edge Worker (Cloudflare \u002F Vercel)\n         ↓ (выполняется агрегация)\n      Internal Event Bus (Kafka \u002F Redpanda)\n         ↓\n      Time-Series DB (TimescaleDB \u002F ClickHouse)\n",[156],{"type":32,"tag":83,"props":157,"children":158},{"__ignoreMap":16},[159],{"type":37,"value":154},{"type":32,"tag":33,"props":161,"children":162},{},[163],{"type":37,"value":164},"Агрегация в edge worker:",{"type":32,"tag":152,"props":166,"children":170},{"code":167,"language":168,"meta":16,"className":169,"style":16},"-- TimescaleDB hypertable\nCREATE TABLE page_metrics (\n  time        TIMESTAMPTZ NOT NULL,\n  page_path   TEXT NOT NULL,\n  country     TEXT,\n  views       INT DEFAULT 1,\n  bounces     INT DEFAULT 0,\n  session_dur INT DEFAULT 0\n);\n\nSELECT create_hypertable('page_metrics', 'time');\n","sql","language-sql shiki shiki-themes github-dark",[171],{"type":32,"tag":83,"props":172,"children":173},{"__ignoreMap":16},[174,186,213,237,259,276,305,331,352,361,371],{"type":32,"tag":175,"props":176,"children":179},"span",{"class":177,"line":178},"line",1,[180],{"type":32,"tag":175,"props":181,"children":183},{"style":182},"--shiki-default:#6A737D",[184],{"type":37,"value":185},"-- TimescaleDB hypertable\n",{"type":32,"tag":175,"props":187,"children":189},{"class":177,"line":188},2,[190,196,201,207],{"type":32,"tag":175,"props":191,"children":193},{"style":192},"--shiki-default:#F97583",[194],{"type":37,"value":195},"CREATE",{"type":32,"tag":175,"props":197,"children":198},{"style":192},[199],{"type":37,"value":200}," TABLE",{"type":32,"tag":175,"props":202,"children":204},{"style":203},"--shiki-default:#B392F0",[205],{"type":37,"value":206}," page_metrics",{"type":32,"tag":175,"props":208,"children":210},{"style":209},"--shiki-default:#E1E4E8",[211],{"type":37,"value":212}," (\n",{"type":32,"tag":175,"props":214,"children":216},{"class":177,"line":215},3,[217,222,227,232],{"type":32,"tag":175,"props":218,"children":219},{"style":192},[220],{"type":37,"value":221},"  time",{"type":32,"tag":175,"props":223,"children":224},{"style":192},[225],{"type":37,"value":226},"        TIMESTAMPTZ",{"type":32,"tag":175,"props":228,"children":229},{"style":192},[230],{"type":37,"value":231}," NOT NULL",{"type":32,"tag":175,"props":233,"children":234},{"style":209},[235],{"type":37,"value":236},",\n",{"type":32,"tag":175,"props":238,"children":240},{"class":177,"line":239},4,[241,246,251,255],{"type":32,"tag":175,"props":242,"children":243},{"style":209},[244],{"type":37,"value":245},"  page_path   ",{"type":32,"tag":175,"props":247,"children":248},{"style":192},[249],{"type":37,"value":250},"TEXT",{"type":32,"tag":175,"props":252,"children":253},{"style":192},[254],{"type":37,"value":231},{"type":32,"tag":175,"props":256,"children":257},{"style":209},[258],{"type":37,"value":236},{"type":32,"tag":175,"props":260,"children":262},{"class":177,"line":261},5,[263,268,272],{"type":32,"tag":175,"props":264,"children":265},{"style":209},[266],{"type":37,"value":267},"  country     ",{"type":32,"tag":175,"props":269,"children":270},{"style":192},[271],{"type":37,"value":250},{"type":32,"tag":175,"props":273,"children":274},{"style":209},[275],{"type":37,"value":236},{"type":32,"tag":175,"props":277,"children":279},{"class":177,"line":278},6,[280,285,290,295,301],{"type":32,"tag":175,"props":281,"children":282},{"style":209},[283],{"type":37,"value":284},"  views       ",{"type":32,"tag":175,"props":286,"children":287},{"style":192},[288],{"type":37,"value":289},"INT",{"type":32,"tag":175,"props":291,"children":292},{"style":192},[293],{"type":37,"value":294}," DEFAULT",{"type":32,"tag":175,"props":296,"children":298},{"style":297},"--shiki-default:#79B8FF",[299],{"type":37,"value":300}," 1",{"type":32,"tag":175,"props":302,"children":303},{"style":209},[304],{"type":37,"value":236},{"type":32,"tag":175,"props":306,"children":308},{"class":177,"line":307},7,[309,314,318,322,327],{"type":32,"tag":175,"props":310,"children":311},{"style":209},[312],{"type":37,"value":313},"  bounces     ",{"type":32,"tag":175,"props":315,"children":316},{"style":192},[317],{"type":37,"value":289},{"type":32,"tag":175,"props":319,"children":320},{"style":192},[321],{"type":37,"value":294},{"type":32,"tag":175,"props":323,"children":324},{"style":297},[325],{"type":37,"value":326}," 0",{"type":32,"tag":175,"props":328,"children":329},{"style":209},[330],{"type":37,"value":236},{"type":32,"tag":175,"props":332,"children":333},{"class":177,"line":26},[334,339,343,347],{"type":32,"tag":175,"props":335,"children":336},{"style":209},[337],{"type":37,"value":338},"  session_dur ",{"type":32,"tag":175,"props":340,"children":341},{"style":192},[342],{"type":37,"value":289},{"type":32,"tag":175,"props":344,"children":345},{"style":192},[346],{"type":37,"value":294},{"type":32,"tag":175,"props":348,"children":349},{"style":297},[350],{"type":37,"value":351}," 0\n",{"type":32,"tag":175,"props":353,"children":355},{"class":177,"line":354},9,[356],{"type":32,"tag":175,"props":357,"children":358},{"style":209},[359],{"type":37,"value":360},");\n",{"type":32,"tag":175,"props":362,"children":364},{"class":177,"line":363},10,[365],{"type":32,"tag":175,"props":366,"children":368},{"emptyLinePlaceholder":367},true,[369],{"type":37,"value":370},"\n",{"type":32,"tag":175,"props":372,"children":374},{"class":177,"line":373},11,[375,380,385,391,396,401],{"type":32,"tag":175,"props":376,"children":377},{"style":192},[378],{"type":37,"value":379},"SELECT",{"type":32,"tag":175,"props":381,"children":382},{"style":209},[383],{"type":37,"value":384}," create_hypertable(",{"type":32,"tag":175,"props":386,"children":388},{"style":387},"--shiki-default:#9ECBFF",[389],{"type":37,"value":390},"'page_metrics'",{"type":32,"tag":175,"props":392,"children":393},{"style":209},[394],{"type":37,"value":395},", ",{"type":32,"tag":175,"props":397,"children":398},{"style":387},[399],{"type":37,"value":400},"'time'",{"type":32,"tag":175,"props":402,"children":403},{"style":209},[404],{"type":37,"value":360},{"type":32,"tag":33,"props":406,"children":407},{},[408],{"type":37,"value":409},"Каждый pageview с клиента проходит цепочку:",{"type":32,"tag":112,"props":411,"children":412},{},[413,426,431,436,449],{"type":32,"tag":61,"props":414,"children":415},{},[416,418,424],{"type":37,"value":417},"JS tracker отправляет ",{"type":32,"tag":83,"props":419,"children":421},{"className":420},[],[422],{"type":37,"value":423},"POST \u002Fapi\u002Fevent",{"type":37,"value":425}," на edge endpoint",{"type":32,"tag":61,"props":427,"children":428},{},[429],{"type":37,"value":430},"Edge worker вычисляет хеш (IP + UA → session_id)",{"type":32,"tag":61,"props":432,"children":433},{},[434],{"type":37,"value":435},"Проверяет Redis: был ли этот session_id в последние 30 минут",{"type":32,"tag":61,"props":437,"children":438},{},[439,441,447],{"type":37,"value":440},"Если да — увеличивает счётчик ",{"type":32,"tag":83,"props":442,"children":444},{"className":443},[],[445],{"type":37,"value":446},"views",{"type":37,"value":448}," на 1, если нет — пишет новую строку",{"type":32,"tag":61,"props":450,"children":451},{},[452],{"type":37,"value":453},"После 30 минут timeout вычисляется bounce",{"type":32,"tag":33,"props":455,"children":456},{},[457],{"type":37,"value":458},"Эта архитектура даёт 3 преимущества перед GA4:",{"type":32,"tag":57,"props":460,"children":461},{},[462,472,482],{"type":32,"tag":61,"props":463,"children":464},{},[465,470],{"type":32,"tag":65,"props":466,"children":467},{},[468],{"type":37,"value":469},"Storage: −85%.",{"type":37,"value":471}," 10M событий → 200K агрегированных строк",{"type":32,"tag":61,"props":473,"children":474},{},[475,480],{"type":32,"tag":65,"props":476,"children":477},{},[478],{"type":37,"value":479},"Query speed: ×40 быстрее.",{"type":37,"value":481}," Time-series индексы доставляют dashboard-запросы за \u003C15ms",{"type":32,"tag":61,"props":483,"children":484},{},[485,490],{"type":32,"tag":65,"props":486,"children":487},{},[488],{"type":37,"value":489},"Privacy: Zero PII.",{"type":37,"value":491}," Raw события не сохраняются — нечего удалять при GDPR Article 17",{"type":32,"tag":40,"props":493,"children":495},{"id":494},"gdpr-compliance-технические-детали",[496],{"type":37,"value":497},"GDPR Compliance: Технические Детали",{"type":32,"tag":33,"props":499,"children":500},{},[501],{"type":37,"value":502},"Чтобы сделать privacy-first analytics legal-proof, нужны 4 слоя:",{"type":32,"tag":33,"props":504,"children":505},{},[506,511,513,519,521,527],{"type":32,"tag":65,"props":507,"children":508},{},[509],{"type":37,"value":510},"1. Data minimization (GDPR Article 5.1c):",{"type":37,"value":512}," собирай только необходимое. Вместо полного referrer URL сохраняй только домен (",{"type":32,"tag":83,"props":514,"children":516},{"className":515},[],[517],{"type":37,"value":518},"https:\u002F\u002Fexample.com\u002Fcheckout?user=123",{"type":37,"value":520}," → ",{"type":32,"tag":83,"props":522,"children":524},{"className":523},[],[525],{"type":37,"value":526},"example.com",{"type":37,"value":528},"). Это и compliance, и экономия диска.",{"type":32,"tag":33,"props":530,"children":531},{},[532,537],{"type":32,"tag":65,"props":533,"children":534},{},[535],{"type":37,"value":536},"2. Anonymization threshold (GDPR Guidelines):",{"type":37,"value":538}," если в метрике \u003C5 наблюдений, не показывай цифру — пиши «\u003C5». Потому что группу из 2 человек можно идентифицировать. TimescaleDB:",{"type":32,"tag":152,"props":540,"children":542},{"code":541,"language":168,"meta":16,"className":169,"style":16},"SELECT \n  country,\n  CASE \n    WHEN COUNT(DISTINCT session_id) \u003C 5 THEN '\u003C 5'\n    ELSE COUNT(DISTINCT session_id)::TEXT\n  END AS visitors\nFROM page_metrics\nWHERE time > NOW() - INTERVAL '7 days'\nGROUP BY country;\n",[543],{"type":32,"tag":83,"props":544,"children":545},{"__ignoreMap":16},[546,558,566,578,626,656,674,687,730],{"type":32,"tag":175,"props":547,"children":548},{"class":177,"line":178},[549,553],{"type":32,"tag":175,"props":550,"children":551},{"style":192},[552],{"type":37,"value":379},{"type":32,"tag":175,"props":554,"children":555},{"style":209},[556],{"type":37,"value":557}," \n",{"type":32,"tag":175,"props":559,"children":560},{"class":177,"line":188},[561],{"type":32,"tag":175,"props":562,"children":563},{"style":209},[564],{"type":37,"value":565},"  country,\n",{"type":32,"tag":175,"props":567,"children":568},{"class":177,"line":215},[569,574],{"type":32,"tag":175,"props":570,"children":571},{"style":192},[572],{"type":37,"value":573},"  CASE",{"type":32,"tag":175,"props":575,"children":576},{"style":209},[577],{"type":37,"value":557},{"type":32,"tag":175,"props":579,"children":580},{"class":177,"line":239},[581,586,591,596,601,606,611,616,621],{"type":32,"tag":175,"props":582,"children":583},{"style":192},[584],{"type":37,"value":585},"    WHEN",{"type":32,"tag":175,"props":587,"children":588},{"style":297},[589],{"type":37,"value":590}," COUNT",{"type":32,"tag":175,"props":592,"children":593},{"style":209},[594],{"type":37,"value":595},"(",{"type":32,"tag":175,"props":597,"children":598},{"style":192},[599],{"type":37,"value":600},"DISTINCT",{"type":32,"tag":175,"props":602,"children":603},{"style":209},[604],{"type":37,"value":605}," session_id) ",{"type":32,"tag":175,"props":607,"children":608},{"style":192},[609],{"type":37,"value":610},"\u003C",{"type":32,"tag":175,"props":612,"children":613},{"style":297},[614],{"type":37,"value":615}," 5",{"type":32,"tag":175,"props":617,"children":618},{"style":192},[619],{"type":37,"value":620}," THEN",{"type":32,"tag":175,"props":622,"children":623},{"style":387},[624],{"type":37,"value":625}," '\u003C 5'\n",{"type":32,"tag":175,"props":627,"children":628},{"class":177,"line":261},[629,634,638,642,646,651],{"type":32,"tag":175,"props":630,"children":631},{"style":192},[632],{"type":37,"value":633},"    ELSE",{"type":32,"tag":175,"props":635,"children":636},{"style":297},[637],{"type":37,"value":590},{"type":32,"tag":175,"props":639,"children":640},{"style":209},[641],{"type":37,"value":595},{"type":32,"tag":175,"props":643,"children":644},{"style":192},[645],{"type":37,"value":600},{"type":32,"tag":175,"props":647,"children":648},{"style":209},[649],{"type":37,"value":650}," session_id)::",{"type":32,"tag":175,"props":652,"children":653},{"style":192},[654],{"type":37,"value":655},"TEXT\n",{"type":32,"tag":175,"props":657,"children":658},{"class":177,"line":278},[659,664,669],{"type":32,"tag":175,"props":660,"children":661},{"style":192},[662],{"type":37,"value":663},"  END",{"type":32,"tag":175,"props":665,"children":666},{"style":192},[667],{"type":37,"value":668}," AS",{"type":32,"tag":175,"props":670,"children":671},{"style":209},[672],{"type":37,"value":673}," visitors\n",{"type":32,"tag":175,"props":675,"children":676},{"class":177,"line":307},[677,682],{"type":32,"tag":175,"props":678,"children":679},{"style":192},[680],{"type":37,"value":681},"FROM",{"type":32,"tag":175,"props":683,"children":684},{"style":209},[685],{"type":37,"value":686}," page_metrics\n",{"type":32,"tag":175,"props":688,"children":689},{"class":177,"line":26},[690,695,700,705,710,715,720,725],{"type":32,"tag":175,"props":691,"children":692},{"style":192},[693],{"type":37,"value":694},"WHERE",{"type":32,"tag":175,"props":696,"children":697},{"style":192},[698],{"type":37,"value":699}," time",{"type":32,"tag":175,"props":701,"children":702},{"style":192},[703],{"type":37,"value":704}," >",{"type":32,"tag":175,"props":706,"children":707},{"style":192},[708],{"type":37,"value":709}," NOW",{"type":32,"tag":175,"props":711,"children":712},{"style":209},[713],{"type":37,"value":714},"() ",{"type":32,"tag":175,"props":716,"children":717},{"style":192},[718],{"type":37,"value":719},"-",{"type":32,"tag":175,"props":721,"children":722},{"style":209},[723],{"type":37,"value":724}," INTERVAL ",{"type":32,"tag":175,"props":726,"children":727},{"style":387},[728],{"type":37,"value":729},"'7 days'\n",{"type":32,"tag":175,"props":731,"children":732},{"class":177,"line":354},[733,738],{"type":32,"tag":175,"props":734,"children":735},{"style":192},[736],{"type":37,"value":737},"GROUP BY",{"type":32,"tag":175,"props":739,"children":740},{"style":209},[741],{"type":37,"value":742}," country;\n",{"type":32,"tag":33,"props":744,"children":745},{},[746,751],{"type":32,"tag":65,"props":747,"children":748},{},[749],{"type":37,"value":750},"3. Data retention policy:",{"type":37,"value":752}," GDPR требует удалять данные, когда цель обработки исчезает. Для аналитики цель — оптимизация производительности. 90 дней — достаточно. TimescaleDB:",{"type":32,"tag":152,"props":754,"children":756},{"code":755,"language":168,"meta":16,"className":169,"style":16},"SELECT add_retention_policy('page_metrics', INTERVAL '90 days');\nSELECT add_compression_policy('page_metrics', INTERVAL '7 days');\n",[757],{"type":32,"tag":83,"props":758,"children":759},{"__ignoreMap":16},[760,790],{"type":32,"tag":175,"props":761,"children":762},{"class":177,"line":178},[763,767,772,776,781,786],{"type":32,"tag":175,"props":764,"children":765},{"style":192},[766],{"type":37,"value":379},{"type":32,"tag":175,"props":768,"children":769},{"style":209},[770],{"type":37,"value":771}," add_retention_policy(",{"type":32,"tag":175,"props":773,"children":774},{"style":387},[775],{"type":37,"value":390},{"type":32,"tag":175,"props":777,"children":778},{"style":209},[779],{"type":37,"value":780},", INTERVAL ",{"type":32,"tag":175,"props":782,"children":783},{"style":387},[784],{"type":37,"value":785},"'90 days'",{"type":32,"tag":175,"props":787,"children":788},{"style":209},[789],{"type":37,"value":360},{"type":32,"tag":175,"props":791,"children":792},{"class":177,"line":188},[793,797,802,806,810,815],{"type":32,"tag":175,"props":794,"children":795},{"style":192},[796],{"type":37,"value":379},{"type":32,"tag":175,"props":798,"children":799},{"style":209},[800],{"type":37,"value":801}," add_compression_policy(",{"type":32,"tag":175,"props":803,"children":804},{"style":387},[805],{"type":37,"value":390},{"type":32,"tag":175,"props":807,"children":808},{"style":209},[809],{"type":37,"value":780},{"type":32,"tag":175,"props":811,"children":812},{"style":387},[813],{"type":37,"value":814},"'7 days'",{"type":32,"tag":175,"props":816,"children":817},{"style":209},[818],{"type":37,"value":360},{"type":32,"tag":33,"props":820,"children":821},{},[822],{"type":37,"value":823},"Через 7 дней данные сжимаются, через 90 дней удаляются. GDPR Article 17 compliance — автоматический.",{"type":32,"tag":33,"props":825,"children":826},{},[827,832,834,840,842,851],{"type":32,"tag":65,"props":828,"children":829},{},[830],{"type":37,"value":831},"4. Consent Mode v2 интеграция (опционально):",{"type":37,"value":833}," если ты ещё гибридный с GA4, запускай Plausible даже в режиме ",{"type":32,"tag":83,"props":835,"children":837},{"className":836},[],[838],{"type":37,"value":839},"analytics_storage: denied",{"type":37,"value":841},". Потому что Plausible вообще не использует cookies — согласия не требуется. ",{"type":32,"tag":843,"props":844,"children":848},"a",{"href":845,"rel":846},"https:\u002F\u002Fwww.roibase.com.tr\u002Fru\u002Ffirstparty",[847],"nofollow",[849],{"type":37,"value":850},"First-party архитектура",{"type":37,"value":852}," детализирует этот гибридный setup: Plausible ловит трафик, server-side GTM отправляет conversion-события в CDP.",{"type":32,"tag":40,"props":854,"children":856},{"id":855},"production-case-e-commerce-hybrid-stack",[857],{"type":37,"value":858},"Production Case: E-commerce Hybrid Stack",{"type":32,"tag":33,"props":860,"children":861},{},[862],{"type":37,"value":863},"Архитектура, которую мы развернули для Shopify-магазина:",{"type":32,"tag":33,"props":865,"children":866},{},[867],{"type":32,"tag":65,"props":868,"children":869},{},[870],{"type":37,"value":871},"Frontend:",{"type":32,"tag":57,"props":873,"children":874},{},[875,880],{"type":32,"tag":61,"props":876,"children":877},{},[878],{"type":37,"value":879},"Plausible tracker на всех страницах (product view, cart, checkout)",{"type":32,"tag":61,"props":881,"children":882},{},[883,885,891],{"type":37,"value":884},"Custom event ",{"type":32,"tag":83,"props":886,"children":888},{"className":887},[],[889],{"type":37,"value":890},"plausible('Purchase', {revenue: 150})",{"type":37,"value":892}," при успехе checkout",{"type":32,"tag":33,"props":894,"children":895},{},[896],{"type":32,"tag":65,"props":897,"children":898},{},[899],{"type":37,"value":900},"Backend (Cloudflare Worker):",{"type":32,"tag":152,"props":902,"children":906},{"code":903,"language":904,"meta":16,"className":905,"style":16},"addEventListener('fetch', event => {\n  event.respondWith(handleRequest(event.request))\n})\n\nasync function handleRequest(request) {\n  const url = new URL(request.url)\n  \n  if (url.pathname === '\u002Fapi\u002Fevent') {\n    const body = await request.json()\n    const sessionId = hashSession(request.headers.get('CF-Connecting-IP'), \n                                    request.headers.get('User-Agent'))\n    \n    \u002F\u002F Redis session-контроль\n    const exists = await redis.exists(`session:${sessionId}`)\n    \n    if (!exists) {\n      await redis.setex(`session:${sessionId}`, 1800, '1')\n      await kafka.send({\n        topic: 'pageviews',\n        messages: [{\n          key: sessionId,\n          value: JSON.stringify({\n            page: body.url,\n            referrer: new URL(body.referrer).hostname,\n            timestamp: Date.now()\n          })\n        }]\n      })\n    }\n    \n    return new Response('OK', {status: 202})\n  }\n}\n","javascript","language-javascript shiki shiki-themes github-dark",[907],{"type":32,"tag":83,"props":908,"children":909},{"__ignoreMap":16},[910,947,974,982,989,1021,1054,1062,1089,1126,1171,1197,1206,1215,1270,1278,1302,1358,1381,1399,1408,1417,1445,1454,1477,1495,1504,1513,1522,1531,1539,1580,1589],{"type":32,"tag":175,"props":911,"children":912},{"class":177,"line":178},[913,918,922,927,931,937,942],{"type":32,"tag":175,"props":914,"children":915},{"style":203},[916],{"type":37,"value":917},"addEventListener",{"type":32,"tag":175,"props":919,"children":920},{"style":209},[921],{"type":37,"value":595},{"type":32,"tag":175,"props":923,"children":924},{"style":387},[925],{"type":37,"value":926},"'fetch'",{"type":32,"tag":175,"props":928,"children":929},{"style":209},[930],{"type":37,"value":395},{"type":32,"tag":175,"props":932,"children":934},{"style":933},"--shiki-default:#FFAB70",[935],{"type":37,"value":936},"event",{"type":32,"tag":175,"props":938,"children":939},{"style":192},[940],{"type":37,"value":941}," =>",{"type":32,"tag":175,"props":943,"children":944},{"style":209},[945],{"type":37,"value":946}," {\n",{"type":32,"tag":175,"props":948,"children":949},{"class":177,"line":188},[950,955,960,964,969],{"type":32,"tag":175,"props":951,"children":952},{"style":209},[953],{"type":37,"value":954},"  event.",{"type":32,"tag":175,"props":956,"children":957},{"style":203},[958],{"type":37,"value":959},"respondWith",{"type":32,"tag":175,"props":961,"children":962},{"style":209},[963],{"type":37,"value":595},{"type":32,"tag":175,"props":965,"children":966},{"style":203},[967],{"type":37,"value":968},"handleRequest",{"type":32,"tag":175,"props":970,"children":971},{"style":209},[972],{"type":37,"value":973},"(event.request))\n",{"type":32,"tag":175,"props":975,"children":976},{"class":177,"line":215},[977],{"type":32,"tag":175,"props":978,"children":979},{"style":209},[980],{"type":37,"value":981},"})\n",{"type":32,"tag":175,"props":983,"children":984},{"class":177,"line":239},[985],{"type":32,"tag":175,"props":986,"children":987},{"emptyLinePlaceholder":367},[988],{"type":37,"value":370},{"type":32,"tag":175,"props":990,"children":991},{"class":177,"line":261},[992,997,1002,1007,1011,1016],{"type":32,"tag":175,"props":993,"children":994},{"style":192},[995],{"type":37,"value":996},"async",{"type":32,"tag":175,"props":998,"children":999},{"style":192},[1000],{"type":37,"value":1001}," function",{"type":32,"tag":175,"props":1003,"children":1004},{"style":203},[1005],{"type":37,"value":1006}," handleRequest",{"type":32,"tag":175,"props":1008,"children":1009},{"style":209},[1010],{"type":37,"value":595},{"type":32,"tag":175,"props":1012,"children":1013},{"style":933},[1014],{"type":37,"value":1015},"request",{"type":32,"tag":175,"props":1017,"children":1018},{"style":209},[1019],{"type":37,"value":1020},") {\n",{"type":32,"tag":175,"props":1022,"children":1023},{"class":177,"line":278},[1024,1029,1034,1039,1044,1049],{"type":32,"tag":175,"props":1025,"children":1026},{"style":192},[1027],{"type":37,"value":1028},"  const",{"type":32,"tag":175,"props":1030,"children":1031},{"style":297},[1032],{"type":37,"value":1033}," url",{"type":32,"tag":175,"props":1035,"children":1036},{"style":192},[1037],{"type":37,"value":1038}," =",{"type":32,"tag":175,"props":1040,"children":1041},{"style":192},[1042],{"type":37,"value":1043}," new",{"type":32,"tag":175,"props":1045,"children":1046},{"style":203},[1047],{"type":37,"value":1048}," URL",{"type":32,"tag":175,"props":1050,"children":1051},{"style":209},[1052],{"type":37,"value":1053},"(request.url)\n",{"type":32,"tag":175,"props":1055,"children":1056},{"class":177,"line":307},[1057],{"type":32,"tag":175,"props":1058,"children":1059},{"style":209},[1060],{"type":37,"value":1061},"  \n",{"type":32,"tag":175,"props":1063,"children":1064},{"class":177,"line":26},[1065,1070,1075,1080,1085],{"type":32,"tag":175,"props":1066,"children":1067},{"style":192},[1068],{"type":37,"value":1069},"  if",{"type":32,"tag":175,"props":1071,"children":1072},{"style":209},[1073],{"type":37,"value":1074}," (url.pathname ",{"type":32,"tag":175,"props":1076,"children":1077},{"style":192},[1078],{"type":37,"value":1079},"===",{"type":32,"tag":175,"props":1081,"children":1082},{"style":387},[1083],{"type":37,"value":1084}," '\u002Fapi\u002Fevent'",{"type":32,"tag":175,"props":1086,"children":1087},{"style":209},[1088],{"type":37,"value":1020},{"type":32,"tag":175,"props":1090,"children":1091},{"class":177,"line":354},[1092,1097,1102,1106,1111,1116,1121],{"type":32,"tag":175,"props":1093,"children":1094},{"style":192},[1095],{"type":37,"value":1096},"    const",{"type":32,"tag":175,"props":1098,"children":1099},{"style":297},[1100],{"type":37,"value":1101}," body",{"type":32,"tag":175,"props":1103,"children":1104},{"style":192},[1105],{"type":37,"value":1038},{"type":32,"tag":175,"props":1107,"children":1108},{"style":192},[1109],{"type":37,"value":1110}," await",{"type":32,"tag":175,"props":1112,"children":1113},{"style":209},[1114],{"type":37,"value":1115}," request.",{"type":32,"tag":175,"props":1117,"children":1118},{"style":203},[1119],{"type":37,"value":1120},"json",{"type":32,"tag":175,"props":1122,"children":1123},{"style":209},[1124],{"type":37,"value":1125},"()\n",{"type":32,"tag":175,"props":1127,"children":1128},{"class":177,"line":363},[1129,1133,1138,1142,1147,1152,1157,1161,1166],{"type":32,"tag":175,"props":1130,"children":1131},{"style":192},[1132],{"type":37,"value":1096},{"type":32,"tag":175,"props":1134,"children":1135},{"style":297},[1136],{"type":37,"value":1137}," sessionId",{"type":32,"tag":175,"props":1139,"children":1140},{"style":192},[1141],{"type":37,"value":1038},{"type":32,"tag":175,"props":1143,"children":1144},{"style":203},[1145],{"type":37,"value":1146}," hashSession",{"type":32,"tag":175,"props":1148,"children":1149},{"style":209},[1150],{"type":37,"value":1151},"(request.headers.",{"type":32,"tag":175,"props":1153,"children":1154},{"style":203},[1155],{"type":37,"value":1156},"get",{"type":32,"tag":175,"props":1158,"children":1159},{"style":209},[1160],{"type":37,"value":595},{"type":32,"tag":175,"props":1162,"children":1163},{"style":387},[1164],{"type":37,"value":1165},"'CF-Connecting-IP'",{"type":32,"tag":175,"props":1167,"children":1168},{"style":209},[1169],{"type":37,"value":1170},"), \n",{"type":32,"tag":175,"props":1172,"children":1173},{"class":177,"line":373},[1174,1179,1183,1187,1192],{"type":32,"tag":175,"props":1175,"children":1176},{"style":209},[1177],{"type":37,"value":1178},"                                    request.headers.",{"type":32,"tag":175,"props":1180,"children":1181},{"style":203},[1182],{"type":37,"value":1156},{"type":32,"tag":175,"props":1184,"children":1185},{"style":209},[1186],{"type":37,"value":595},{"type":32,"tag":175,"props":1188,"children":1189},{"style":387},[1190],{"type":37,"value":1191},"'User-Agent'",{"type":32,"tag":175,"props":1193,"children":1194},{"style":209},[1195],{"type":37,"value":1196},"))\n",{"type":32,"tag":175,"props":1198,"children":1200},{"class":177,"line":1199},12,[1201],{"type":32,"tag":175,"props":1202,"children":1203},{"style":209},[1204],{"type":37,"value":1205},"    \n",{"type":32,"tag":175,"props":1207,"children":1209},{"class":177,"line":1208},13,[1210],{"type":32,"tag":175,"props":1211,"children":1212},{"style":182},[1213],{"type":37,"value":1214},"    \u002F\u002F Redis session-контроль\n",{"type":32,"tag":175,"props":1216,"children":1218},{"class":177,"line":1217},14,[1219,1223,1228,1232,1236,1241,1246,1250,1255,1260,1265],{"type":32,"tag":175,"props":1220,"children":1221},{"style":192},[1222],{"type":37,"value":1096},{"type":32,"tag":175,"props":1224,"children":1225},{"style":297},[1226],{"type":37,"value":1227}," exists",{"type":32,"tag":175,"props":1229,"children":1230},{"style":192},[1231],{"type":37,"value":1038},{"type":32,"tag":175,"props":1233,"children":1234},{"style":192},[1235],{"type":37,"value":1110},{"type":32,"tag":175,"props":1237,"children":1238},{"style":209},[1239],{"type":37,"value":1240}," redis.",{"type":32,"tag":175,"props":1242,"children":1243},{"style":203},[1244],{"type":37,"value":1245},"exists",{"type":32,"tag":175,"props":1247,"children":1248},{"style":209},[1249],{"type":37,"value":595},{"type":32,"tag":175,"props":1251,"children":1252},{"style":387},[1253],{"type":37,"value":1254},"`session:${",{"type":32,"tag":175,"props":1256,"children":1257},{"style":209},[1258],{"type":37,"value":1259},"sessionId",{"type":32,"tag":175,"props":1261,"children":1262},{"style":387},[1263],{"type":37,"value":1264},"}`",{"type":32,"tag":175,"props":1266,"children":1267},{"style":209},[1268],{"type":37,"value":1269},")\n",{"type":32,"tag":175,"props":1271,"children":1273},{"class":177,"line":1272},15,[1274],{"type":32,"tag":175,"props":1275,"children":1276},{"style":209},[1277],{"type":37,"value":1205},{"type":32,"tag":175,"props":1279,"children":1281},{"class":177,"line":1280},16,[1282,1287,1292,1297],{"type":32,"tag":175,"props":1283,"children":1284},{"style":192},[1285],{"type":37,"value":1286},"    if",{"type":32,"tag":175,"props":1288,"children":1289},{"style":209},[1290],{"type":37,"value":1291}," (",{"type":32,"tag":175,"props":1293,"children":1294},{"style":192},[1295],{"type":37,"value":1296},"!",{"type":32,"tag":175,"props":1298,"children":1299},{"style":209},[1300],{"type":37,"value":1301},"exists) {\n",{"type":32,"tag":175,"props":1303,"children":1305},{"class":177,"line":1304},17,[1306,1311,1315,1320,1324,1328,1332,1336,1340,1345,1349,1354],{"type":32,"tag":175,"props":1307,"children":1308},{"style":192},[1309],{"type":37,"value":1310},"      await",{"type":32,"tag":175,"props":1312,"children":1313},{"style":209},[1314],{"type":37,"value":1240},{"type":32,"tag":175,"props":1316,"children":1317},{"style":203},[1318],{"type":37,"value":1319},"setex",{"type":32,"tag":175,"props":1321,"children":1322},{"style":209},[1323],{"type":37,"value":595},{"type":32,"tag":175,"props":1325,"children":1326},{"style":387},[1327],{"type":37,"value":1254},{"type":32,"tag":175,"props":1329,"children":1330},{"style":209},[1331],{"type":37,"value":1259},{"type":32,"tag":175,"props":1333,"children":1334},{"style":387},[1335],{"type":37,"value":1264},{"type":32,"tag":175,"props":1337,"children":1338},{"style":209},[1339],{"type":37,"value":395},{"type":32,"tag":175,"props":1341,"children":1342},{"style":297},[1343],{"type":37,"value":1344},"1800",{"type":32,"tag":175,"props":1346,"children":1347},{"style":209},[1348],{"type":37,"value":395},{"type":32,"tag":175,"props":1350,"children":1351},{"style":387},[1352],{"type":37,"value":1353},"'1'",{"type":32,"tag":175,"props":1355,"children":1356},{"style":209},[1357],{"type":37,"value":1269},{"type":32,"tag":175,"props":1359,"children":1361},{"class":177,"line":1360},18,[1362,1366,1371,1376],{"type":32,"tag":175,"props":1363,"children":1364},{"style":192},[1365],{"type":37,"value":1310},{"type":32,"tag":175,"props":1367,"children":1368},{"style":209},[1369],{"type":37,"value":1370}," kafka.",{"type":32,"tag":175,"props":1372,"children":1373},{"style":203},[1374],{"type":37,"value":1375},"send",{"type":32,"tag":175,"props":1377,"children":1378},{"style":209},[1379],{"type":37,"value":1380},"({\n",{"type":32,"tag":175,"props":1382,"children":1384},{"class":177,"line":1383},19,[1385,1390,1395],{"type":32,"tag":175,"props":1386,"children":1387},{"style":209},[1388],{"type":37,"value":1389},"        topic: ",{"type":32,"tag":175,"props":1391,"children":1392},{"style":387},[1393],{"type":37,"value":1394},"'pageviews'",{"type":32,"tag":175,"props":1396,"children":1397},{"style":209},[1398],{"type":37,"value":236},{"type":32,"tag":175,"props":1400,"children":1402},{"class":177,"line":1401},20,[1403],{"type":32,"tag":175,"props":1404,"children":1405},{"style":209},[1406],{"type":37,"value":1407},"        messages: [{\n",{"type":32,"tag":175,"props":1409,"children":1411},{"class":177,"line":1410},21,[1412],{"type":32,"tag":175,"props":1413,"children":1414},{"style":209},[1415],{"type":37,"value":1416},"          key: sessionId,\n",{"type":32,"tag":175,"props":1418,"children":1420},{"class":177,"line":1419},22,[1421,1426,1431,1436,1441],{"type":32,"tag":175,"props":1422,"children":1423},{"style":209},[1424],{"type":37,"value":1425},"          value: ",{"type":32,"tag":175,"props":1427,"children":1428},{"style":297},[1429],{"type":37,"value":1430},"JSON",{"type":32,"tag":175,"props":1432,"children":1433},{"style":209},[1434],{"type":37,"value":1435},".",{"type":32,"tag":175,"props":1437,"children":1438},{"style":203},[1439],{"type":37,"value":1440},"stringify",{"type":32,"tag":175,"props":1442,"children":1443},{"style":209},[1444],{"type":37,"value":1380},{"type":32,"tag":175,"props":1446,"children":1448},{"class":177,"line":1447},23,[1449],{"type":32,"tag":175,"props":1450,"children":1451},{"style":209},[1452],{"type":37,"value":1453},"            page: body.url,\n",{"type":32,"tag":175,"props":1455,"children":1457},{"class":177,"line":1456},24,[1458,1463,1468,1472],{"type":32,"tag":175,"props":1459,"children":1460},{"style":209},[1461],{"type":37,"value":1462},"            referrer: ",{"type":32,"tag":175,"props":1464,"children":1465},{"style":192},[1466],{"type":37,"value":1467},"new",{"type":32,"tag":175,"props":1469,"children":1470},{"style":203},[1471],{"type":37,"value":1048},{"type":32,"tag":175,"props":1473,"children":1474},{"style":209},[1475],{"type":37,"value":1476},"(body.referrer).hostname,\n",{"type":32,"tag":175,"props":1478,"children":1480},{"class":177,"line":1479},25,[1481,1486,1491],{"type":32,"tag":175,"props":1482,"children":1483},{"style":209},[1484],{"type":37,"value":1485},"            timestamp: Date.",{"type":32,"tag":175,"props":1487,"children":1488},{"style":203},[1489],{"type":37,"value":1490},"now",{"type":32,"tag":175,"props":1492,"children":1493},{"style":209},[1494],{"type":37,"value":1125},{"type":32,"tag":175,"props":1496,"children":1498},{"class":177,"line":1497},26,[1499],{"type":32,"tag":175,"props":1500,"children":1501},{"style":209},[1502],{"type":37,"value":1503},"          })\n",{"type":32,"tag":175,"props":1505,"children":1507},{"class":177,"line":1506},27,[1508],{"type":32,"tag":175,"props":1509,"children":1510},{"style":209},[1511],{"type":37,"value":1512},"        }]\n",{"type":32,"tag":175,"props":1514,"children":1516},{"class":177,"line":1515},28,[1517],{"type":32,"tag":175,"props":1518,"children":1519},{"style":209},[1520],{"type":37,"value":1521},"      })\n",{"type":32,"tag":175,"props":1523,"children":1525},{"class":177,"line":1524},29,[1526],{"type":32,"tag":175,"props":1527,"children":1528},{"style":209},[1529],{"type":37,"value":1530},"    }\n",{"type":32,"tag":175,"props":1532,"children":1534},{"class":177,"line":1533},30,[1535],{"type":32,"tag":175,"props":1536,"children":1537},{"style":209},[1538],{"type":37,"value":1205},{"type":32,"tag":175,"props":1540,"children":1542},{"class":177,"line":1541},31,[1543,1548,1552,1557,1561,1566,1571,1576],{"type":32,"tag":175,"props":1544,"children":1545},{"style":192},[1546],{"type":37,"value":1547},"    return",{"type":32,"tag":175,"props":1549,"children":1550},{"style":192},[1551],{"type":37,"value":1043},{"type":32,"tag":175,"props":1553,"children":1554},{"style":203},[1555],{"type":37,"value":1556}," Response",{"type":32,"tag":175,"props":1558,"children":1559},{"style":209},[1560],{"type":37,"value":595},{"type":32,"tag":175,"props":1562,"children":1563},{"style":387},[1564],{"type":37,"value":1565},"'OK'",{"type":32,"tag":175,"props":1567,"children":1568},{"style":209},[1569],{"type":37,"value":1570},", {status: ",{"type":32,"tag":175,"props":1572,"children":1573},{"style":297},[1574],{"type":37,"value":1575},"202",{"type":32,"tag":175,"props":1577,"children":1578},{"style":209},[1579],{"type":37,"value":981},{"type":32,"tag":175,"props":1581,"children":1583},{"class":177,"line":1582},32,[1584],{"type":32,"tag":175,"props":1585,"children":1586},{"style":209},[1587],{"type":37,"value":1588},"  }\n",{"type":32,"tag":175,"props":1590,"children":1592},{"class":177,"line":1591},33,[1593],{"type":32,"tag":175,"props":1594,"children":1595},{"style":209},[1596],{"type":37,"value":1597},"}\n",{"type":32,"tag":33,"props":1599,"children":1600},{},[1601],{"type":32,"tag":65,"props":1602,"children":1603},{},[1604],{"type":37,"value":1605},"Data layer:",{"type":32,"tag":57,"props":1607,"children":1608},{},[1609,1614,1619],{"type":32,"tag":61,"props":1610,"children":1611},{},[1612],{"type":37,"value":1613},"Kafka consumer пишет в TimescaleDB (batch insert каждые 10 сек)",{"type":32,"tag":61,"props":1615,"children":1616},{},[1617],{"type":37,"value":1618},"Grafana dashboard читает из TimescaleDB (real-time, refresh 2 сек)",{"type":32,"tag":61,"props":1620,"children":1621},{},[1622],{"type":37,"value":1623},"Ежедневный export в BigQuery (dbt join: Plausible traffic + Shopify orders)",{"type":32,"tag":33,"props":1625,"children":1626},{},[1627],{"type":37,"value":1628},"Результат: attribution accuracy — 92% (у GA4 было 58% из-за ITP и cookie rejection). GDPR compliance — 100%, никакой PII. Query-время — 40ms (у GA4 — 4–6 сек).",{"type":32,"tag":40,"props":1630,"children":1632},{"id":1631},"plausible-vs-ga4-когда-что-использовать",[1633],{"type":37,"value":1634},"Plausible vs GA4: Когда Что Использовать",{"type":32,"tag":33,"props":1636,"children":1637},{},[1638],{"type":37,"value":1639},"Нужно ли полностью отказываться от GA4? Нет. В двух сценариях GA4 всё ещё имеет смысл:",{"type":32,"tag":33,"props":1641,"children":1642},{},[1643],{"type":32,"tag":65,"props":1644,"children":1645},{},[1646],{"type":37,"value":1647},"Используй GA4:",{"type":32,"tag":57,"props":1649,"children":1650},{},[1651,1656,1661],{"type":32,"tag":61,"props":1652,"children":1653},{},[1654],{"type":37,"value":1655},"Cross-domain tracking (несколько сайтов, поддомены — linker GA4 более зрелый)",{"type":32,"tag":61,"props":1657,"children":1658},{},[1659],{"type":37,"value":1660},"Machine learning insights (predictive metrics GA4: probability to purchase, churn probability)",{"type":32,"tag":61,"props":1662,"children":1663},{},[1664],{"type":37,"value":1665},"Google Ads integration (enhanced conversions, remarketing audiences — GA4 встроена)",{"type":32,"tag":33,"props":1667,"children":1668},{},[1669],{"type":32,"tag":65,"props":1670,"children":1671},{},[1672],{"type":37,"value":1673},"Используй Plausible:",{"type":32,"tag":57,"props":1675,"children":1676},{},[1677,1682,1687],{"type":32,"tag":61,"props":1678,"children":1679},{},[1680],{"type":37,"value":1681},"Public dashboard (встраиваешь Plausible на сайт — GA4 требует viewer-аккаунт)",{"type":32,"tag":61,"props":1683,"children":1684},{},[1685],{"type":37,"value":1686},"Лёгкие сайты (блог, landing page, SaaS marketing)",{"type":32,"tag":61,"props":1688,"children":1689},{},[1690],{"type":37,"value":1691},"Strict compliance (GDPR, CCPA — у Plausible zero risk)",{"type":32,"tag":33,"props":1693,"children":1694},{},[1695],{"type":37,"value":1696},"Гибридный setup самый распространённый: Plausible ловит весь трафик сайта, GA4 срабатывает только на critical conversion-funnel через server-side GTM. Так ты получаешь privacy и performance одновременно.",{"type":32,"tag":33,"props":1698,"children":1699},{},[1700],{"type":37,"value":1701},"Privacy-first analytics — это уже не «было б неплохо», это обязательно. Chrome удалил cookies в 2024, штрафы GDPR выросли на 300% в 2025. Plausible + server-side aggregation — единственное production-ready решение для двух этих давлений одновременно. Если ты всё ещё мучаешься с 60% data loss в GA4, планируй переход на cookieless-архитектуру — в 2026 году analytics без cookies — это baseline.",{"type":32,"tag":1703,"props":1704,"children":1705},"style",{},[1706],{"type":37,"value":1707},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}",{"title":16,"searchDepth":215,"depth":215,"links":1709},[1710,1711,1712,1713,1714],{"id":42,"depth":188,"text":45},{"id":137,"depth":188,"text":140},{"id":494,"depth":188,"text":497},{"id":855,"depth":188,"text":858},{"id":1631,"depth":188,"text":1634},"markdown","content:ru:data:privacy-first-analytics-plausible-server-side.md","content","ru\u002Fdata\u002Fprivacy-first-analytics-plausible-server-side.md","ru\u002Fdata\u002Fprivacy-first-analytics-plausible-server-side","md",1779314640716]