# Compare mobile vs desktop Lighthouse scores

**Use case:** 

Audit each URL as a mobile phone and as a desktop computer in one run, then compare performance, accessibility, best-practices and SEO scores and lab LCP, CLS and TBT side by side. $0.02 per audit, so one URL on both devices costs $0.04. This example compares alpinejs.dev and htmx.org.

## Input

```json
{
  "urls": [
    "https://alpinejs.dev/",
    "https://htmx.org/"
  ],
  "strategies": [
    "mobile",
    "desktop"
  ],
  "categories": [
    "performance",
    "accessibility",
    "best-practices",
    "seo"
  ],
  "maxUrls": 1,
  "maxOpportunities": 5,
  "saveFullReport": false,
  "throttlingMethod": "simulate",
  "timeoutSecs": 120
}
```

## Output

```json
{
  "url": {
    "label": "URL",
    "format": "string"
  },
  "strategy": {
    "label": "Device",
    "format": "string"
  },
  "performanceScore": {
    "label": "Performance",
    "format": "integer"
  },
  "lcpMs": {
    "label": "LCP (ms)",
    "format": "integer"
  },
  "cls": {
    "label": "CLS",
    "format": "number"
  },
  "tbtMs": {
    "label": "TBT (ms)",
    "format": "integer"
  },
  "seoScore": {
    "label": "SEO",
    "format": "integer"
  },
  "accessibilityScore": {
    "label": "Accessibility",
    "format": "integer"
  },
  "passedBudgets": {
    "label": "Budgets passed",
    "format": "boolean"
  },
  "errorCode": {
    "label": "Error",
    "format": "string"
  }
}
```

## How it works

### 1. Sign up on Apify or log in

The Bulk Lighthouse & PageSpeed Test: Sitemap, Core Web Vitals Actor is ready to run with the inputs already set for "Compare mobile vs desktop Lighthouse scores". [Sign up or log in](https://console.apify.com/create-task-from-example/8snVTMiHE6JI066iR) and you'll land in Apify Console with a copy of this exact task.

### 2. Start the "Compare mobile vs desktop Lighthouse scores" task

The Bulk Lighthouse & PageSpeed Test: Sitemap, Core Web Vitals Actor will start running based on the input automatically. You can also change all the input fields, like URLs to audit, devices, and more, to match your specific use case.

### 3. Receive the "Compare mobile vs desktop Lighthouse scores" output

Monitor the progress in real time. You will be notified as soon as your dataset is complete and ready for review. Each result includes data such as URL, device, performance, and more.

### 4. Integrate into your workflow

The final output is delivered in JSON, CSV, or Excel format, ready to be plugged into your workflow. You can also [run the "Compare mobile vs desktop Lighthouse scores" task via API](https://apify.com/datatoolsforall/bulk-lighthouse-pagespeed-audit.md).

## FAQ

### How much does it cost to compare mobile vs desktop Lighthouse scores?

To compare mobile vs desktop Lighthouse scores costs $0.02 per audit, and each URL is two audits (one per device), so $0.04 per URL, plus a $0.0001 start fee (2 GB). This 2-URL example costs about $0.08. Failed audits are free.

### Why are mobile scores usually lower than desktop?

When you compare mobile vs desktop Lighthouse scores, the mobile audit emulates a mid-range phone on a throttled connection, as PageSpeed Insights does, so lab timings are slower and scores usually lower than on desktop.

### Can I set pass/fail targets?

Yes. When you compare mobile vs desktop Lighthouse scores, add budgets such as a minimum performance score or a maximum LCP. Each row then shows passedBudgets and which budgets failed.

## About this Actor

This example demonstrates how to use [Bulk Lighthouse & PageSpeed Test: Sitemap, Core Web Vitals](https://apify.com/datatoolsforall/bulk-lighthouse-pagespeed-audit.md) with a specific input configuration. Visit the [Actor detail page](https://apify.com/datatoolsforall/bulk-lighthouse-pagespeed-audit.md) to learn more, explore other use cases, and run it yourself.


## How to integrate an Actor?

This Task's input is already configured above. Use it as-is rather than inventing a new one.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For full API examples (JavaScript, Python, CLI, MCP, OpenAPI), see this Task's Actor page: https://apify.com/datatoolsforall/bulk-lighthouse-pagespeed-audit.md

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).
