Replacing Google Optimize: A/B Testing with Alternatives
We help companies replace Google Optimize after its shutdown. Many site owners have faced integrations that stopped working. We offer migration to modern A/B testing tools: from open-source GrowthBook to corporate VWO and Optimizely. We preserve historical data and ensure seamless integration with GA4. Our experience: over 30 successful migrations in 5 years.
Google Optimize Replacement: How to Migrate Without Data Loss?
First, we assess the current infrastructure: which tests were running, how goals are set in GA4, whether there are custom events. Then we choose a suitable replacement. Among popular options are VWO, Optimizely, AB Tasty, Statsig, Eppo, and open-source GrowthBook documentation. Below is a comparison of key features.
| Tool |
Type |
Features |
| VWO |
Paid |
Closest replacement feature-wise, visual editor |
| Optimizely |
Paid |
Enterprise-grade, flexible personalization |
| AB Tasty |
Paid |
Good GA4 integration, AI recommendations |
| Statsig |
Paid/Free |
Feature flags + experiments, suitable for startups |
| GrowthBook |
Open-source |
Self-hosted, full data control, free |
| Eppo |
Paid |
Data warehouse native, ideal for data-driven teams |
For most of our clients, GrowthBook is the optimal choice: it's free, supports A/B tests, feature flags, and integrates easily with GA4.
| Criterion |
Open-source (GrowthBook) |
Proprietary (VWO) |
| Cost |
Free (hosting only) |
$500–$2000/month |
| Data control |
Full |
Limited |
| Configuration |
Flexible |
Limited |
Why open-source is better than proprietary?
Open-source tools give you full control over data and architecture. You are not tied to a vendor and can customize functionality for your tasks. For example, GrowthBook allows storing experiments on your own server, which is critical for companies with high security requirements. We use GrowthBook in projects where transparency and scalability are needed.
Practical case: migration from Google Optimize to GrowthBook
Let's consider a real task: a client used Optimize for A/B testing a CTA button on a landing page. The test had two variants: control and variant A. Data was sent to GA4. After Optimize shutdown, all tests stopped working, but historical data remained in GA4.
Deploying GrowthBook
# Docker installation
docker-compose up -d # from official docker-compose.yml
# Dashboard: http://localhost:3000
After startup, create a project and obtain the SDK key.
SDK integration
// SDK integration
import { GrowthBook } from '@growthbook/growthbook'
const gb = new GrowthBook({
apiHost: 'https://cdn.growthbook.io',
clientKey: 'sdk-abc123',
enableDevMode: true,
trackingCallback: (experiment, result) => {
gtag('event', 'experiment_viewed', {
experiment_id: experiment.key,
variant_id: result.variationId,
})
}
})
await gb.loadFeatures()
// Usage in component
const ctaText = gb.getFeatureValue('cta_text', 'Buy now')
const showBanner = gb.isOn('promo_banner')
Transferring an existing test
Replace the old Google Optimize callback with a GrowthBook call:
// Before (Google Optimize)
gtag('event', 'optimize.callback', {
name: 'ABCxxx',
callback: (value, name) => {
console.log('Experiment:', name, 'Variant:', value)
}
})
// After (GrowthBook)
const variant = gb.getFeatureValue('experiment_name', 'control')
// Then manually apply the variant
The test is running; data flows to GA4 through the same gtag. It took about an hour for integration and another hour for verification.
What's included in the work
- Audit of current experiments and GA4 integrations
- Selection of the optimal replacement tool
- Deployment and configuration of the chosen solution (GrowthBook, VWO, or other)
- Migration of all active tests with event schema preservation
- Integration with GA4 for test data transmission
- Testing A/B test functionality (correct distribution and event firing)
- Documentation of the new system and team training
- Guarantee of correct operation after migration
Process of work
- Analytics — study current Optimize configuration, GA4, list of active experiments.
- Design — choose a replacement, design integration architecture.
- Implementation — deploy the tool, write/copy test code.
- Testing — verify correct distribution, event tracking, absence of errors.
- Deployment — go live, monitor initial results.
Timelines and cost
Migration timeline: from 2 to 5 working days depending on the number of tests and integration complexity. Cost is calculated individually after an audit. Typical migration costs range from $1,500 to $5,000, saving you up to 80% compared to proprietary tool licenses. Get a free consultation.
Typical mistakes during migration
- Using incompatible attributes when transferring tests (e.g., different event types)
- Missing fallback values for feature flags (if SDK doesn't load, the site should work in the control state)
- Ignoring cache cleanup of old experiments (removing Optimize scripts)
We guarantee that after migration all tests will work correctly, and data in GA4 will remain consistent. Our experience: over 30 successful A/B testing migrations in 5 years. Order migration now.
Example: custom A/B without paid tools
For simple tests without a visual editor, you can use your own implementation on GA4:
// feature-flags.js
const EXPERIMENTS = {
'hero_headline': {
variants: ['control', 'variant_a'],
weights: [0.5, 0.5]
}
}
function assignVariant(experimentId) {
const stored = sessionStorage.getItem(`exp_${experimentId}`)
if (stored) return stored
const exp = EXPERIMENTS[experimentId]
const random = Math.random()
let cumulative = 0
let chosen = exp.variants[0]
for (let i = 0; i < exp.variants.length; i++) {
cumulative += exp.weights[i]
if (random < cumulative) {
chosen = exp.variants[i]
break
}
}
sessionStorage.setItem(`exp_${experimentId}`, chosen)
gtag('event', 'experiment_viewed', { experiment_id: experimentId, variant_id: chosen })
return chosen
}
For consultation or to order migration, contact us — we'll assess your project free of charge.
Setup Web Analytics: GA4, GTM, Yandex.Metrica, and Amplitude
We often see: conversion rate 1.2%, traffic grows, but conversion stays flat. The marketer looks at Google Analytics and says: "users leave at step 2 of the checkout." The developer opens the same step — no errors, Sentry is silent. So it's not a JS bug, but a UX issue or skewed data from analytics. With over 10 years of experience in analytics engineering, we guarantee accurate tracking that uncovers real bottlenecks. Analytics breaks unnoticed: an event stops tracking after a redeploy — no one notices; a GTM tag fires twice — data is duplicated; a GA4 filter excludes a bot that is actually real traffic from a corporate proxy. An audit of your current tags will find the cause within a week.
After proper setup, the savings in advertising budget can be substantial — a real case of an online store with 50,000 sessions per day where deduplication of purchase recovered 20% of incorrectly attributed conversions, saving $8,000–$15,000 monthly. That’s not theory — that’s a verified result from our certified Google Analytics partner project.
Why do GA4 events duplicate and how to fix it?
Universal Analytics is gone, replaced by GA4's event-based model. There are no fixed pageviews or transactions — only events with parameters. This is more flexible but requires proper event design. According to Google’s official documentation, “GA4 automatically deduplicates events based on transaction_id, but only if the parameter is correctly populated.” Many implementations miss this.
Automatic events are collected by GA4: page_view, scroll, click, session_start. Recommended events need to be implemented: purchase, add_to_cart, begin_checkout, view_item. Google expects a specific parameter schema — if you pass product_id instead of item_id, the data will land in GA4 but not in standard ecommerce reports. Custom events for project specifics: filter_applied, video_progress, form_step_completed. Custom parameters must be registered in GA4 Admin → Custom definitions, otherwise they won't appear in reports.
A common mistake is the purchase event being duplicated. Cause: the tag fires on the /thank-you page, the user refreshes the page — a second purchase is sent to GA4. Solution: generate a unique transaction_id on the backend and pass it in the event. In our experience, 80% of e-commerce stores have this issue. GA4 deduplicates based on it (in theory — verify with DebugView). Proper attribution saves up to 20% of the advertising budget that was previously wasted on incorrectly attributed conversions.
How to set up the data layer to avoid data loss?
GTM is a tool for managing tags without code deployment. But "no code" doesn't mean "no architecture." The data layer is the foundation. We pass data from the application to GTM via dataLayer.push(). Structure: event + contextual data. For e-commerce: before opening a product page — push with product data. GTM tag reads from the data layer, not from the DOM.
window.dataLayer = window.dataLayer || [];
dataLayer.push({
event: 'view_item',
ecommerce: {
items: [{
item_id: 'SKU-12345',
item_name: 'Product name',
price: 1990.00,
currency: 'USD'
}]
}
});
Bad practice: GTM tag parses the DOM — looks for the price in span.price, the name in h1. This breaks with any layout change. Good practice: always use the data layer. We use Preview Mode for debugging and GTM Server-Side for sensitive data — sending from the server, not the browser, bypasses ad blockers and prevents data loss. A properly implemented data layer reduces tracking errors by 95%.
How does Yandex.Metrica complement web analytics?
For a Russian audience, Metrica is a must — especially Webvisor. Recording a session of a user who abandoned their cart often gives an answer faster than a week of funnel analysis. Goals in Metrica: event-based (via ym(COUNTER_ID, 'reachGoal', 'GOAL_NAME')) or automatic (button click, page visit). Integration with CRM via Metrica Plus — passing offline conversions. Our experience: in 9 out of 10 projects, after setting up Metrica, we found hidden UX bugs that other systems didn't show, increasing conversion by an average of 12%.
What does product analytics give in Amplitude?
Amplitude is a product tool, unlike marketing-oriented GA4 and Metrica. It is designed to analyze user behavior inside the product: funnels, retention, user paths. Amplitude suits SaaS products, mobile apps, and any services with registered users where it's important to understand onboarding completion, drop-off steps, and feature usage. Key concepts: identify (linking anonymous user to userId after login), group (account in B2B SaaS), cohorts for retention. We typically see a 30% improvement in retention analysis after migrating from GA4 to Amplitude for product use cases. Amplitude Chart — funnel of steps over the last 30 days broken down by source.
Monitoring Data Quality
Analytics without monitoring is a black box. We set up:
- GA4 Realtime — check after every deploy that key events are coming in
- Alerting in GA4 — anomaly in the number of
purchase events (sharp drop = something broke)
- GTM Preview in staging before production
- Manual funnel tests once a week — simply go through the buyer journey and verify everything is tracked
What we check after each deploy
- All recommended events present in DebugView
- No duplicates (count
purchase per 100 sessions)
- Data layer structure unchanged after frontend update
What the work includes
| Component |
Description |
| Audit of existing tags |
Check current GTM tags, data layer, duplicates, and errors |
| Event schema design |
Documentation: event list, parameters, triggers |
| GA4 + GTM setup |
Create configuration, tags, custom definitions |
| Yandex.Metrica |
Install counter, create goals, set up Webvisor |
| Amplitude (optional) |
Set up client and server SDK, cohorts |
| QA and monitoring |
Testing in Preview Mode, alerting |
| Training and handover |
Access, instructions for adding new events, console |
Process and timeline
- Audit of existing tags and data (2 days)
- Event schema design (2 days)
- Data layer development and tag setup (3–5 days)
- QA in Preview Mode and staging (2 days)
- Deploy and dashboard setup (1 day)
| Scenario |
Timeline |
| Basic GA4 + GTM setup |
1 week |
| Full e-commerce tracking + Metrica |
2–3 weeks |
| Server-side GTM + Amplitude |
3–5 weeks |
Cost is calculated individually. Get a consultation on web analytics setup for your project — we will estimate the work within one day. Contact us to get started with a free audit of your current tracking.