# App Store and Google Play Keyword Rankings Scraper (`datamule/app-store-search-scraper`) Actor

Search a keyword in the Apple App Store or Google Play and get the ranked apps: rank, title, developer, rating, price, genre, app ID, URL. For ASO keyword tracking. $0.0005 per app (free plan).

- **URL**: https://apify.com/datamule/app-store-search-scraper.md
- **Developed by:** [Datamule](https://apify.com/datamule) (community)
- **Categories:** Developer tools, E-commerce, AI
- **Features:** Limited permissions
- **Stats:** 10 total users, 4 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.35 / 1,000 app results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

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 examples already wired to this Actor's own input schema, see the [API](#api) section below.

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`).

# README

## App Store and Google Play Search / Rankings Scraper

Search the Apple App Store or Google Play by keyword and get the ranked list of apps the store shows: rank, title, developer, rating, price, genre, app ID and URL. For app-store-optimization (ASO) keyword tracking, competitor discovery and market research. **Price: $0.0005 per app returned on the free plan ($0.50 per 1,000), lower on higher Apify plans; no start fee.**

Empty `{}` input searches the App Store for "habit tracker" in the US and returns up to 50 apps (about $0.025). Use `maxResults: 5` for a cheap first test. One store per run; run twice to compare stores.

### Example input

```json
{
  "searchTerms": ["habit tracker"],
  "store": "app_store",
  "country": "us",
  "maxResults": 10
}
```

### Example output

Real row (App Store, rank 1 for "habit tracker", US):

```json
{
  "store": "app_store",
  "query": "habit tracker",
  "country": "us",
  "rank": 1,
  "appId": "1438388363",
  "bundleId": "com.davetech.habit",
  "title": "Habit Tracker",
  "developer": "InnerGrow",
  "rating": 4.79179,
  "ratingCount": 147771,
  "price": 0,
  "currency": "USD",
  "genre": "Productivity",
  "url": "https://apps.apple.com/us/app/habit-tracker/id1438388363?uo=4",
  "icon": "https://is1-ssl.mzstatic.com/image/thumb/Purple211/v4/d4/b3/2b/d4b32bd9-f4dd-e9cb-9a26-207f33befafb/AppIcon-pink-gr-0-0-1x_U007epad-0-1-0-85-220.png/100x100bb.jpg"
}
```

Google Play rows have the same fields; `ratingCount` is `null` there and the App Store `appId` is the numeric track ID.

### Output fields

`store`, `query`, `country`, `rank` (1 = first in the store's order), `appId`, `bundleId`, `title`, `developer`, `rating`, `ratingCount`, `price`, `currency`, `genre`, `url`, `icon`. Field details are in the table further below.

### Limits

- App Store: up to 200 apps per term; Google Play: about 30.
- Ranks are the store's order at run time for that country/language, not a stable index.
- Cost = terms x apps returned x $0.0005. Set a maximum charge per run; the Actor stops cleanly when it is reached.

### Use from an AI agent / API

**Python (apify-client)**

```python
from apify_client import ApifyClient
client = ApifyClient("<APIFY_TOKEN>")
run = client.actor("datamule/app-store-search-scraper").call(
    run_input={"searchTerms": ["habit tracker"], "store": "app_store", "maxResults": 10},
    max_total_charge_usd=0.05,   # hard cost cap for the run
)
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)
```

**MCP (Claude, Cursor, any MCP client):** add `https://mcp.apify.com/?tools=datamule/app-store-search-scraper` as a remote MCP server with your Apify token as a Bearer header. The Actor then appears as one tool whose arguments are the input fields above; call it with the example input.

**Agent rules:** pass JSON matching the input schema; `{}` is valid and returns real default data; always set a maximum charge per run; read results from the run's default dataset (one row per result).

### FAQ

**Which store does it search?** Apple App Store by default; set `store` to `google_play` for Google Play.
**Why fewer results than `maxResults`?** The store returned fewer matches (Google Play caps near 30).
**Can I track rank over time?** Schedule runs and compare `rank` by `appId` across datasets.
**Does it need a login or key?** No.

### Inputs

| Field | Required | Accepted format | Default or prefill | Limits and store behavior |
|---|---|---|---|---|
| `searchTerms` | Yes | Non-empty JSON array of keyword strings | Console prefill: `["meditation", "habit tracker"]`; no runtime default | Each term is searched separately. The schema does not set a maximum number of terms, so keep the list small to control result count and cost. |
| `store` | No | `app_store` or `google_play` | `app_store` | Selects one source for the whole run. The two stores have different catalogs and ranking systems. |
| `country` | No | Two-letter country or storefront code such as `us`, `gb`, `sg`, or `de` | `us` | The Actor lowercases the value. Both sources use it, and results can differ by country. |
| `language` | No | Two-letter language code such as `en` or `de` | `en` | The Actor lowercases the value. Google Play uses it; the App Store ignores it. |
| `maxResults` | No | Integer | `50` | Schema range: 1–200 per term. The App Store can return up to 200; Google Play is clamped to roughly 30. |

The same keyword can return different apps and a different order across stores, countries, or languages. `rank` is the source's observed result order at run time; the Actor does not normalize or combine the two ranking systems.

### Output fields

| Field | Type | Meaning |
|---|---|---|
| `store` | string | Source used: `app_store` or `google_play`. |
| `query` | string | Search term that produced the row. |
| `country` | string or null | Country or storefront code sent to the source. |
| `rank` | integer | One-based position in the returned source order. |
| `appId` | string or null | App Store numeric track ID as a string, or Google Play package ID. |
| `bundleId` | string or null | Apple bundle ID or Google Play package ID. |
| `title` | string or null | App name reported by the source. |
| `developer` | string or null | Developer or publisher name reported by the source. |
| `rating` | number or null | Average user rating when the source returns it. |
| `ratingCount` | integer or null | Rating count for App Store results; the current Google Play search path returns `null`. |
| `price` | number or null | Listed numeric price; free Google Play apps are recorded as `0.0`. |
| `currency` | string or null | Currency code reported by the source. |
| `genre` | string or null | Primary genre or category. |
| `url` | string or null | Canonical app detail URL. |
| `icon` | string or null | App icon URL reported by the source. |

### Use cases

- Take keyword-rank snapshots for app store optimization work.
- Compare the apps visible for the same term across countries or between the two stores.
- Find competing apps, their publishers, ratings, prices, and categories.
- Schedule repeated runs and compare exported datasets to track source-order changes over time.

### Source, coverage, freshness, and responsible use

Apple results come from the public iTunes Search API. Google Play results come from the public catalog through the maintained `google-play-scraper` search client. The Actor fetches both sources at run time and does not maintain a historical index.

Source catalogs, localization, availability, and ranking logic differ. The App Store supports up to 200 requested results per term, while Google Play usually exposes roughly 30 through this search path. A returned list is a current source observation, not a complete catalog or a promise that the same order will appear later.

Use the data in line with Apple and Google terms and applicable law. Do not use ratings or rankings as proof of quality, and avoid decisions that require stronger evidence than a public catalog snapshot.

### Troubleshooting

- **Input rejected:** `searchTerms` must be a non-empty array, and `maxResults` must be an integer from 1 to 200. Use only `app_store` or `google_play` for `store`.
- **Zero results:** check the keyword and two-letter country code. For Google Play, also check the language code. Try a broad public term such as `habit tracker`; a source can also return no data during a temporary failure.
- **Fewer results than requested:** the source may have fewer matches. Google Play is limited to roughly 30 even when `maxResults` is higher.
- **Ranks differ from another storefront or later run:** country, language, catalog changes, and each store's own ranking logic can change both membership and order.

# Actor input Schema

## `searchTerms` (type: `array`):

Keywords to search, e.g. \["habit tracker"]. You get the ranked list of apps the chosen store returns for each term, one row per app, in the store's order (rank 1 = first). Each term is billed per app returned, so total cost ≈ terms × max results × $0.0005. Default: \["habit tracker"] so an empty {} input returns real data.

## `store` (type: `string`):

Which store to search: 'app_store' (Apple App Store, via the iTunes Search API) or 'google_play'. One store per run; run twice to compare both. Default 'app_store'.

## `country` (type: `string`):

Two-letter storefront country code, lower- or upper-case (us, gb, sg, de…). Rankings differ per country. Default 'us'.

## `language` (type: `string`):

Two-letter language code for Google Play (en, de…). Ignored for the App Store. Default 'en'.

## `maxResults` (type: `integer`):

Max ranked apps returned PER search term (1–200). App Store supports up to 200; Google Play returns about 30 at most. Default 50 (≈ $0.025 per term at the base price); use 5–10 for a cheap first run.

## Actor input object example

```json
{
  "searchTerms": [
    "habit tracker",
    "meditation"
  ],
  "store": "google_play",
  "country": "sg",
  "language": "en",
  "maxResults": 10
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("datamule/app-store-search-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("datamule/app-store-search-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call datamule/app-store-search-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,datamule/app-store-search-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/aejgcKxdUNCcybT7n/builds/268Xwvo2X4Ffp5M8r/openapi.json
