Shopify · Airbyte · BigQuery · Looker · E-commerce

AOT — E-commerce Data Pipeline & Insights Reporting

A robust data pipeline integrating Shopify, Facebook Ads, and Klaviyo into BigQuery via Airbyte — powering automated Looker dashboards on CAC:LTV, cohort analysis, paid marketing performance, customer retention, and decile segmentation.

My Role: Full Stack Developer
3
Data Sources
Shopify, Meta, Klaviyo
Live
BigQuery Warehouse
290K+ orders synced
CAC
vs LTV Analysis
Per customer view
10x
Looker Dashboards
Full analytics suite

What We Built & Why

Art of Tea (AOT) runs a multi-channel e-commerce business across Shopify, Facebook Ads, and Klaviyo email campaigns. With data siloed across three platforms, there was no unified view of customer acquisition cost, lifetime value, or which channels were actually driving profitable growth.

We designed a full ETL pipeline using Airbyte to centralise all three sources into BigQuery, built custom SQL views for CAC, LTV, cohort analysis, and decile segmentation, then surfaced everything in interactive Looker dashboards — giving every team real-time, actionable intelligence.

Core problem solved: Marketing, sales, and executive teams making decisions without a unified view of customer data. This pipeline delivers CAC:LTV ratios, cohort retention, decile segmentation, and campaign ROAS — all in one place, automatically updated every 24 hours.

Shopify Integration

Orders, customers, refunds — 290K+ records synced live via Airbyte every 24 hours.

Facebook Ads Data

Campaign spend, impressions, clicks, and conversions — for real ROAS measurement.

Klaviyo Email Data

Open rates, click rates, and campaign engagement — linked to purchase behaviour.

Cohort & LTV Analysis

Customer segments by loyalty — Champions, At Risk, Hibernating — with trend tracking 2020–2025.

Pipeline & Dashboards Running in Production

Airbyte connections dashboard — 7 healthy Shopify, Facebook, Klaviyo to BigQuery connections
Airbyte — 7 Healthy Connections Running

The live Airbyte dashboard shows 7 healthy connections and 2 paused — Shopify stores (Dreamiere, Hoist, Nicolette, Pura, Country Meats), Facebook Marketing, and BR_COLLABORATIVE all syncing to BigQuery every 24 hours.

· 7 active connections — all syncing every 24 hours
· Multiple Shopify stores → separate BigQuery datasets
· Facebook Marketing → BigQuery for ad data
· Last sync: 5–6 hours ago across all connections
Shopify → BigQuery — Active Streams

The Shopify → BigQuery connection syncs 3 active streams: customers (2,046 loaded), order_refunds (2 loaded), and orders (1,372 loaded) — all data fresh as of 6 hours ago, next sync in 18 hours.

· customers: 2,046 records loaded
· orders: 1,372 records loaded in last run
· order_refunds: 2 records — clean incremental sync
· All streams: Synced ✓ — data fresh 6 hours ago
Airbyte Shopify to BigQuery active streams — customers, orders, order_refunds synced
BigQuery AOT dataset showing orders partitioned table with 290K rows and multiple analytics views
BigQuery — 290K Orders + Analytics Views

The utopian_goods_364016_AOT_data dataset in BigQuery shows the partitioned orders table with 290,318 rows, plus dozens of business logic views — LTV_AOC_and_OPC_view, ads_performance_metrics_view, and more.

· orders: 290,318 rows — partitioned table
· ATC VS CONV, CPP, LTV_AOC_and_OPC_view
· ads_creatives, ads_insights, ads_performance_metrics_view
· avg_months_to_repurchase, avg_repurchase_aov, cohort tables
Looker — Art of Tea GA4 Overview Dashboard

The live Looker dashboard shows 154,758 sessions, 127,030 active users, 92,213 new users — with device breakdown, top traffic sources (Google, Klaviyo, Meta), session funnel, and ecommerce engagement snapshot.

· 154,758 sessions — Dec 20, 2025 to Jan 18, 2026
· Top source: google/organic — 32,512 sessions
· Session funnel: 63K start → 4.5K add-to-cart → 1.8K purchase
· 10 tabs: GA4, Meta, Cohort, Klaviyo, CAC:LTV, Decile...
Art of Tea Looker dashboard — GA4 overview with sessions, traffic sources, funnel analysis
Art of Tea cohort analysis dashboard — customer loyalty groups, Champions, At Risk, Hibernating trend 2020-2025
Cohort Analysis — Customer Loyalty Intelligence

The cohort dashboard segments all customers into loyalty groups — Champions, Loyal, Promising, Recent, At Risk, Hibernating, and Lost — with revenue per segment ($5.84M Champions, $5.03M At Risk) and loyalty trends from 2020–2025.

· Champions: 8.2K customers — $5.84M revenue
· At Risk: 70.1K customers — $5.03M revenue
· Loyalty trend charted 2020–2025 — all segments
· Green / Yellow / Red zone segmentation with action plans

How the Pipeline Flows

Source Systems
Shopify
Sales data, transaction details, customer behaviour — orders, refunds, customers synced every 24 hours via Airbyte
Facebook Ads
Campaign performance — impressions, clicks, conversions, spend — linked to Shopify purchase data for true ROAS
Klaviyo
Email marketing data — open rates, click rates, engagement — connected to purchase behaviour and LTV analysis
Pipeline Steps
01
Airbyte Extraction

Airbyte connectors pull data from Shopify, Facebook Ads, and Klaviyo on a 24-hour schedule — cleaning and structuring data in-flight.

02
BigQuery Raw Load

Raw data loaded into BigQuery tables — sales_data, ads_data, email_engagement — as the single source of truth.

03
SQL Transformation

Custom BigQuery SQL calculates CAC, LTV, cohort groups, decile segments, ad ROAS — stored in scheduled views updated automatically.

04
Looker Dashboards

Looker connects to BigQuery — delivering 10+ dashboards covering GA4, Meta, cohort analysis, CAC:LTV, Klaviyo, decile, and more.

Three Phases of Delivery

Phase 1 — Airbyte Integration
· Airbyte deployed on GCP environment
· Shopify connector — customers, orders, refunds
· Facebook Ads connector — campaigns, ad sets, ads
· Klaviyo connector — email events & engagement
· 24-hour scheduled sync — auto-refresh all sources
Phase 2 — BigQuery Transformation
· Schema: sales_data, ads_data, email_engagement
· CAC = Ad Spend / New Customers SQL view
· LTV calculation across customer order history
· Cohort analysis — grouped by first purchase date
· Decile segmentation by total purchase value
Phase 3 — Looker Reporting
· Looker → BigQuery connected on GCP
· CAC:LTV, Cohort, Decile Looker models built
· 10+ dashboards — all business teams covered
· Role-based access control per dashboard
· Auto-refresh every 24 hours on data sync

What the Dashboards Track

CAC vs Lifetime Value (LTV)

Cost to acquire each customer vs their lifetime revenue — per channel, per campaign. Identifies which marketing spend delivers the best return.

Cohort Analysis

Customers grouped by first purchase date — loyalty segments (Champions, At Risk, Hibernating) with revenue and trend analysis 2020–2025.

Sales Analysis

Conversion rates, average order value (AOV), and customer segmentation — optimise product mix and pricing based on actual purchase data.

Paid Marketing Performance

Facebook Ads spend vs Shopify conversions — true ROAS per campaign, ad set, and creative. Identify which ads drive the most profitable customers.

Customer Retention

Email engagement, purchase frequency, and recency — track which customers are at risk of churning and trigger retention campaigns proactively.

Decile Analysis

Customers segmented into deciles by total purchase value — identify the top 10% who drive the majority of revenue for targeted VIP campaigns.

What This Pipeline Delivers

Marketing teams see CAC:LTV ratios per channel in real time — budgets reallocated to channels that deliver the highest lifetime customer value.

Cohort and decile segmentation enables hyper-targeted campaigns — Champions retained, At Risk customers re-engaged before they churn.

Sales teams prioritise high-conversion products and high-value customers — driven by AOV, purchase frequency, and retention data rather than guesswork.

Executives see real-time CAC, LTV, and cohort performance — making financial decisions based on live pipeline data rather than monthly reports.

Unified view across Shopify, Facebook Ads, and Klaviyo — for the first time, marketing spend is directly linked to customer LTV and repeat purchase behaviour.

Technologies Used

Airbyte
ETL connector tool
Shopify
E-commerce source
Facebook Ads
Ad performance data
BigQuery
Data warehouse
Looker
BI dashboards
Klaviyo
Email marketing data

What Was Built & Applied

Airbyte Data Integration
Google BigQuery
Looker Dashboard Development
Shopify API Integration
CAC & LTV Analysis
Cohort & Decile Analysis
Paid Marketing Analytics
ETL Pipeline Architecture

Want a unified e-commerce analytics pipeline for your brand?

From Shopify, Meta, and Klaviyo integration to CAC:LTV dashboards, cohort analysis, and decile segmentation — we build data pipelines that tell you exactly where to invest.

Start Your Project →