Setting up goals and tracking conversions
Learn how to define meaningful goals, set up conversion tracking, and measure what matters most for your website success.
Pageviews tell you people visited. Goals tell you they did something valuable. Setting up proper conversion tracking transforms analytics from interesting to actionable.
What is a [goal](/glossary/goal)?
A goal is a specific action you want visitors to take. When they complete that action, it's a conversion.
Common goal types
Lead generation goals:
- Form submission
- Email signup
- Demo request
- Contact form completion
E-commerce goals:
- Purchase completed
- Add to cart
- Checkout started
- Wishlist addition
Engagement goals:
- Account created
- Video watched
- PDF downloaded
- Tool used
Content goals:
- Article read (scroll depth)
- Multiple pages viewed
- Time on site threshold
- Comment submitted
Choosing the right goals
Start with business objectives
What does success look like for your website? Work backward:
- Business goal: Increase revenue
- Website goal: More purchases
- Micro-goals: Add to cart, begin checkout, view product
Macro vs micro conversions
Macro conversions: Primary business objectives
- Purchase
- Lead form submission
- Subscription signup
Micro conversions: Steps toward macro conversions
- Email signup
- Product page view
- Pricing page visit
- Add to cart
Track both. Micro conversions help you understand the journey to macro conversions.
The "so what" test
For each potential goal, ask: "If this number goes up, does it matter?"
- Newsletter signups: Matters if subscribers become customers
- Page views: Matters less than engaged page views
- Time on site: Matters if it correlates with conversions
Choose goals that connect to business outcomes.
Setting up goals in Glyphex
Page-based goals
Track when visitors reach specific pages:
Thank you pages: After form submissions
// Automatically tracked when visitor reaches /thank-youConfirmation pages: After purchases or signups
// Automatically tracked when visitor reaches /order-confirmationEvent-based goals
Track specific actions with custom events:
Form submission:
document.querySelector('form').addEventListener('submit', function() {
glyphex.track('form_submitted', {
form_name: 'contact',
form_location: 'homepage'
});
});Button click:
document.querySelector('.cta-button').addEventListener('click', function() {
glyphex.track('cta_clicked', {
button_text: 'Start Free Trial',
page: window.location.pathname
});
});Video engagement:
// When video reaches 50% watched
glyphex.track('video_progress', {
video_title: 'Product Demo',
progress: 50
});Scroll depth:
// When user scrolls to bottom of article
glyphex.track('content_consumed', {
content_type: 'article',
scroll_depth: 100
});Building conversion funnels
A funnel tracks the steps toward a goal. This reveals where visitors drop off.
Example: Lead generation funnel
- Landing page view: 1,000 visitors
- Scroll to form: 600 visitors (60%)
- Form interaction: 200 visitors (20%)
- Form submitted: 50 visitors (5%)
The biggest drop is between page view and form scroll. Maybe the form needs to be higher on the page.
Example: E-commerce funnel
- Product page view: 5,000 visitors
- Add to cart: 500 visitors (10%)
- Begin checkout: 300 visitors (6%)
- Complete purchase: 150 visitors (3%)
The biggest drop is add-to-cart. Product pages might need better descriptions, images, or pricing.
Setting up funnels
Define funnel steps in order:
// Step 1: View product
glyphex.track('funnel_step', { funnel: 'purchase', step: 'product_view' });
// Step 2: Add to cart
glyphex.track('funnel_step', { funnel: 'purchase', step: 'add_to_cart' });
// Step 3: Begin checkout
glyphex.track('funnel_step', { funnel: 'purchase', step: 'checkout_start' });
// Step 4: Complete purchase
glyphex.track('funnel_step', { funnel: 'purchase', step: 'purchase_complete' });Measuring conversion rates
Overall conversion rate
Conversion rate = (Conversions / Visitors) × 100Conversion rate by segment
Compare conversion rates across:
- Traffic source: Which channels convert best?
- Device: Do mobile visitors convert differently?
- Landing page: Which pages lead to conversions?
- Time: Do conversion rates vary by day or time?
Benchmarks
Conversion rates vary widely by industry and goal type:
- E-commerce purchase: 1-4%
- Lead generation: 2-5%
- Email signup: 1-5%
- Free trial signup: 3-10%
Your own historical data is the best benchmark. Focus on improvement over time.
Common goal tracking mistakes
Tracking too many goals
More goals doesn't mean better insights. Focus on 3-5 key goals that matter most.
Tracking vanity metrics
"Button hover" isn't a meaningful goal. Track actions that indicate real intent or value.
Not tracking micro conversions
If your main goal has low volume, micro conversions provide faster feedback for optimization.
Forgetting to test
Always verify goal tracking works before relying on the data. Complete the goal yourself and check if it registers.
Goal optimization workflow
Weekly review
- Check conversion rates for each goal
- Compare to previous week
- Note any significant changes
- Identify top-performing segments
Monthly analysis
- Review funnel drop-off points
- Analyze conversion by traffic source
- Identify optimization opportunities
- Plan tests for next month
Quarterly planning
- Review goal relevance (still measuring what matters?)
- Assess progress toward business objectives
- Adjust goals if business priorities changed
- Set targets for next quarter
Getting started checklist
- List your business objectives: What does success look like?
- Define 3-5 key goals: What actions indicate success?
- Identify micro conversions: What steps lead to goals?
- Implement tracking: Add goal tracking code
- Test thoroughly: Verify tracking works correctly
- Build funnels: Map the path to conversion
- Set up regular reviews: Schedule weekly check-ins
Goals transform analytics from "how many visited" to "how many converted." Start tracking what matters, and you'll start improving what matters.