A tested walkthrough for AliExpress Products -- the right proxy type, 88% tested success rate, working code, and what to avoid to stay compliant.
AliExpress product title, price range, orders count, and store rating live in an embedded window.runParams JSON blob, reachable with residential rotating proxies on a short sticky session. AliExpress's risk engine issues a slider CAPTCHA to sessions without valid cookies or realistic pacing, and KnoxProxy residential sessions held an 88% success rate on product pages. The same AliExpress scraper logic scales from a single product lookup to monitoring an entire catalog of listings.
| Anti-bot system | Custom bot detection (Alibaba Group risk engine) |
| Challenge types | Slider "puzzle" CAPTCHA on flagged sessions, Rate-based IP throttling, Session token validation (_m_h5_tk cookie), Country-based storefront redirect enforcement |
| Rate limit behavior | Requests without a valid session cookie, or originating from datacenter IP ranges, are frequently redirected to a slider CAPTCHA page after single-digit request counts; established residential sessions with human-like pacing browse many listings before a challenge appears. |
| Tested success rate | 88% |
"""
KnoxProxy scraper for AliExpress product pages.
Product data is embedded in a window.runParams JavaScript object in the
raw page HTML rather than static attributes.
"""
import json
import random
import re
import time
import requests
PROXY_HOST = "proxy.knoxproxy.com"
PROXY_PORT = 10000 # residential rotating
PROXY_USER = "your_username"
PROXY_PASS = "your_password"
HEADERS = {
"User-Agent": (
"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 "
"(KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36"
),
"Accept-Language": "en-US,en;q=0.9",
}
RUN_PARAMS_RE = re.compile(r"window\.runParams\s*=\s*(\{.*?\});", re.DOTALL)
def proxy_dict(country: str = "us") -> dict:
user = f"{PROXY_USER}-country-{country}-session-aliexpress1"
proxy_url = f"http://{user}:{PROXY_PASS}@{PROXY_HOST}:{PROXY_PORT}"
return {"http": proxy_url, "https": proxy_url}
def fetch_aliexpress_product(product_id: str, max_retries: int = 3) -> dict:
url = f"https://www.aliexpress.com/item/{product_id}.html"
proxies = proxy_dict()
for attempt in range(1, max_retries + 1):
try:
resp = requests.get(url, headers=HEADERS, proxies=proxies, timeout=20)
if resp.status_code == 200 and "punish" not in resp.url:
return parse_aliexpress_page(resp.text, product_id)
print(f"Attempt {attempt}: redirected to verification page")
except requests.exceptions.RequestException as exc:
print(f"Attempt {attempt}: request failed ({exc})")
time.sleep(random.uniform(2, 5))
raise RuntimeError(f"Failed to fetch AliExpress item {product_id} after {max_retries} attempts")
def parse_aliexpress_page(html: str, product_id: str) -> dict:
match = RUN_PARAMS_RE.search(html)
if not match:
return {"product_id": product_id, "error": "runParams not found"}
data = json.loads(match.group(1))
page_data = data.get("data", {})
return {
"product_id": product_id,
"title": page_data.get("titleModule", {}).get("subject"),
"price": page_data.get("priceModule", {}).get("formatedPrice"),
"orders": page_data.get("titleModule", {}).get("tradeCount"),
"store_rating": page_data.get("storeModule", {}).get("positiveRate"),
}
if __name__ == "__main__":
product_ids = ["1005006109083792"]
for pid in product_ids:
print(fetch_aliexpress_product(pid))
time.sleep(random.uniform(2, 5))
{
"product_id": "1005006109083792",
"title": "Wireless Bluetooth Earbuds Noise Cancelling Sport Headset",
"price": "US $18.32",
"orders": "2,341 sold",
"store_rating": "97.8%"
}Install requests and Python's built-in json and re modules for extracting the embedded product data.
pip install requestsHold one IP for the duration of a browsing run so cookies and session tokens stay consistent.
PROXY_HOST = "proxy.knoxproxy.com"
PROXY_PORT = 10000
PROXY_USER = "your_username"
PROXY_PASS = "your_password"Fetch the AliExpress item page and locate the window.runParams JavaScript variable in the raw HTML.
Extract and json.loads() the runParams payload rather than parsing rendered DOM, since most pricing data is injected via JavaScript.
AliExpress Products runs custom bot detection (Alibaba Group risk engine). The tested setup is residential rotating proxies, targeting match the proxy country to the desired storefront currency and language, with this rotation: Sticky session for roughly 10 minutes per browsing run. That combination held a 88% success rate on the Jun 30, 2026 test run.
The proxy is half the job — sticky session for roughly 10 minutes per browsing run is what turns a working request into a repeatable one.
Sticky session for roughly 10 minutes per browsing run.
Match the proxy country to the desired storefront currency and language.
AliExpress Products leans on slider "puzzle" CAPTCHA on flagged sessions. Requests without a valid session cookie, or originating from datacenter IP ranges, are frequently redirected to a slider CAPTCHA page after single-digit request counts; established residential sessions with human-like pacing browse many listings before a challenge appears.
Our legality guide and AUP cover the boundaries in full — staying inside them is what keeps a scraping program durable.
The slider puzzle is a CAPTCHA issued by Alibaba Group's risk engine when a session lacks a valid cookie or shows non-human request timing. Residential IPs with realistic pacing encounter it far less often than datacenter IPs.
Residential rotating proxies held on a short sticky session, around 10 minutes, work best because AliExpress ties session cookies to a consistent IP during normal browsing.
Set the proxy's country to match the storefront you want, since AliExpress adjusts currency, shipping cost, and sometimes the displayed price based on the visitor's apparent location.
Most pricing and inventory data is embedded in a window.runParams JavaScript object rather than static HTML attributes, so parsing that JSON blob is more reliable than CSS selectors alone.
The Python code above is a tested AliExpress scraper you can run as-is or extend. It already parses the window.runParams JSON blob and handles proxy rotation, so there's no separate service required to get product data.
Free trial on residential proxies -- 88% tested success, no credit card.