# Pagespeed

## Page Speed and Performance-First Testing

Performance is the cornerstone of effective conversion rate optimization (CRO). Shoplift is engineered specifically for the Shopify ecosystem to ensure your testing program does not compromise the speed or stability of your storefront.

Our **Performance-First** methodology ensures near-zero latency and eliminates the common issues of page flicker (content flashing) and degraded Core Web Vitals (CWV) scores.

### The Performance Advantage: How Shoplift Maintains Speed

Shoplift's minimal impact on your storefront's load time is achieved through three key architectural principles:

#### 1. Near-Zero Latency with Native Integration

Shoplift leverages Shopify's native infrastructure to serve test variants as quickly as possible.

* **Theme & Template Testing:** By working directly with Shopify's built-in theme and template structure, we harness Shopify's native caching and edge delivery mechanisms. This process embeds the test logic directly within the page, avoiding the need for external network requests that bottleneck traditional client-side tools.
* **Flicker Elimination:** Since test logic is executed efficiently before the page renders, visitors are immediately delivered the correct variant, eliminating the visible flicker or "content flash" that frustrates users and invalidates test results.

#### 2. Minimal and Dynamic Payload

The Shoplift script is purposefully lightweight and runs on an **as-needed basis** to minimize resource load across the customer journey.

* **Dynamic Execution:** Our script only executes logic relevant to the pages being tested. Areas of your website that are *not* included in any active experiments will experience near-zero performance drag from Shoplift.
* **Optimized Script Size:** We prioritize minimal JavaScript payload to ensure fast parsing and execution, especially on mobile devices where script loading is a major performance barrier.

#### 3. Server-Side Reliability and Clean Data Collection

For conversion tracking, Shoplift utilizes server-side methods to ensure accuracy and reduce client-side performance load.

* **Shopify Web Pixel API:** We utilize the Shopify Web Pixel API (or similar server-side mechanisms) to track events like purchases, cart actions, and checkouts. This robust method ensures high fidelity data collection without relying on brittle, slow, client-side JavaScript tracking that can slow down the browser.

### Quantified Performance Impact

We are dedicated to ensuring your optimization efforts do not introduce systematic performance degradation.

When measured against industry standards (such as Google Lighthouse), Shoplift's testing script introduces a negligible performance impact, typically resulting in a **minimal 1-2 point reduction** in the overall Lighthouse score. We've optimized our script to execute on an as-needed basis on storefronts so that unnecessary load times are excluded from multiple page loads in the customer journey. Furthermore, certain components of the script only execute on tested pages, so that active tests have a near-zero effect on areas of your website that aren't included in tests.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.shoplift.ai/partners-and-developers/performance/pagespeed.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
