How to build a Python price tracker: tutorial with rate-limit handling

The primary risk of any custom price scraper is silent degradation without error logs. During setup, a Python price tracker feels like a straightforward combination of a scheduler and a basic script. In practice, however, retailers quickly spot predictable request patterns and start throttling your traffic, throw up CAPTCHAs, or slyly serve HTTP 200 responses with placeholder data instead of actual prices.
I’ll show you how to build a tracking bot that survives in production, with a full-fledged infrastructure stack backed by respectful request pacing, custom headers, and exponential backoff on retries. Telegram, Slack, or email alerts handle instant notifications. As your watchlist grows, a proxy pool behind it all routes checks across multiple IPs to keep traffic safely under store rate limits.
Price tracking with rate-limit handling in Python: key insights
- A reliable price tracker requires five core components: a scraper, SQLite storage, alerts, scheduling, and a stability layer for repeated checks.
- The main risk of a DIY setup is silent failure: blocks often look like a normal HTTP 200 page with no price in it.
- To handle rate limits, your script should honor Retry-After when present, or double the delay after each attempt.
- Browser headers can still earn a 403 because of Python’s TLS fingerprint, which curl_cffi impersonation fixes by reproducing Chrome’s handshake.
- Proxies are a scaling step: a few products run fine from one address, while dozens of daily checks need a pool of IPs.
What a Python price tracker does, step by step
A Python price tracker repeatedly checks product pages and notifies you when an item’s price meets a condition you set, such as a steep drop or a crossed target. Left running on a timer, it builds a historical dataset sellers use to follow competitor shifts, spot discounts, and decide on repricing.
The workflow has six steps:
- Fetch the product page and retrieve its HTML.
- Extract the price and normalize the value.
- Store it with a timestamp in a database.
- Compare the value with the prior check.
- Alert when the change crosses the threshold.
- Repeat on a schedule.
A single-product dropshipper and an e-commerce team tracking dozens of SKUs across retailers share the same core loop, differing only in concurrency and infrastructure requirements.
Key tools and libraries for price scraping Python projects
The right library set depends on how a retailer renders its content (static or JavaScript-heavy) and how it treats automated traffic (stores rejecting Python’s TLS handshake call for curl_cffi).
Job | Tool | When you need it |
Fetch static pages | requests | Prices live in raw HTML |
Render dynamic pages | Playwright | Prices load with JavaScript |
Match browser TLS fingerprint | curl_cffi | Resolving 403 failures on a TLS mismatch |
Parse HTML tree | BeautifulSoup | Extracting price strings from markup |
Convert price text into numbers | price-parser | Handling currency symbols and separators |
Store price snapshots | sqlite3 | Price diffing and historical tracking |
Send alerts | smtplib / Telegram Bot API / Slack incoming webhook | Getting notifications on price changes; one channel is enough |
Repeat checks automatically | APScheduler | Running tracker on a schedule |
If parsing with BeautifulSoup’s CSS selectors is new to you, start with the Python web scraping guide.
Initial setup and product tracking list
Start with a project directory and set up an isolated Python 3.10+ environment with all required packages.
Python
# Create the environment and install dependencies
mkdir -p price-tracker && cd price-tracker
python3 -m venv .venv || python -m venv .venv
source .venv/bin/activate 2>/dev/null || source .venv/Scripts/activate
pip install requests beautifulsoup4 price-parser playwright curl_cffi apscheduler python-dotenv
playwright install chromiumOn Windows, run the terminal commands in Git Bash or WSL.
Next, list the items to monitor in products.csv, with optional alert settings per row; I’ll use the web-scraping.dev sandbox as a working example.
Python
# Create the watchlist
cat > products.csv <<'CSV'
url,target_price,drop_pct
https://web-scraping.dev/product/1,8.50,5
https://web-scraping.dev/product/2,,10
CSVAlert parameters:
- target_price sends a notification when the cost falls to it or below; if left blank, no target check runs.
- drop_pct sets the percentage drop between two consecutive checks that triggers an alert; defaults to 5% when omitted.
Store credentials outside the source code using a runtime .env file. Add it to .gitignore so Git never commits it: pushed files remain in repository history even after deletion.
Python
# Create the secrets file kept out of Git
cat > .env <<'ENV'
TELEGRAM_TOKEN=123456:replace-me
TELEGRAM_CHAT_ID=987654321
SMTP_USER=you@gmail.com
SMTP_APP_PASSWORD=your-app-password
SLACK_WEBHOOK_URL=https://hooks.slack.com/services/T000/B000/XXXX
ENV
echo ".env" >> .gitignoreKeep only the alert channels you need, replacing the placeholders with your real secrets.
Scrape current product prices
The first script fetches a product page with the requests library and browser-like headers, finds the price value with a BeautifulSoup CSS selector (.product-price in this case), and turns it into a float with price-parser.
Python
# scraper.py: get prices via HTTP as floats
import requests
from bs4 import BeautifulSoup
from price_parser import Price
HEADERS = {
"User-Agent": ("Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 "
"(KHTML, like Gecko) Chrome/157.0.0.0 Safari/537.36"),
"Accept-Language": "en-US,en;q=0.9",
}
def parse_price(html: str, selector: str = ".product-price") -> float | None:
node = BeautifulSoup(html, "html.parser").select_one(selector)
return Price.fromstring(node.get_text()).amount_float if node else None
def get_price(url: str) -> float | None:
resp = requests.get(url, headers=HEADERS, timeout=15)
resp.raise_for_status()
return parse_price(resp.text)To find the selector on your target store, right-click the price, choose Inspect, and copy a class unique to that element (broad ones like .price may catch other product variants too).
A failed extraction with a 429 or 403 means the site rejects the request, so adjust the pace or rotate IPs and headers, respectively. If get_price() returns None, check the response HTML: update the selector if markup changed, or switch to Playwright if the price is missing (meaning it’s JS-rendered). If the HTML is a CAPTCHA page, that’s also a refusal, like a 403.
RESIDENTIAL PROXIES
Stop losing price checks to rate limits
Proxy-Seller residential proxies route each request through a pool of ~47M IPs/month, with a 99.5% success rate. Plans start at 1 GB, $3.5/GB.
Handling JavaScript-rendered prices with Playwright
For stores with dynamic prices, I use Playwright with headless Chromium: it waits for client-side scripts to populate elements and reads the rendered DOM.
Python
# render.py: get JavaScript-loaded prices
import os
from types import SimpleNamespace
from urllib.parse import urlparse
from playwright.sync_api import sync_playwright, TimeoutError as PWTimeout
from scraper import parse_price
def browser_get(url: str, selector: str = ".product-price"):
p = urlparse(os.getenv("PROXY_URL", ""))
proxy = {"server": f"{p.scheme}://{p.hostname}:{p.port}",
"username": p.username, "password": p.password} if p.hostname else None
with sync_playwright() as pw:
page = pw.chromium.launch(proxy=proxy).new_page()
page.route("**/*.{png,jpg,jpeg,webp,gif,woff2}", lambda route: route.abort())
resp = page.goto(url)
if resp.status == 200:
try:
page.wait_for_selector(selector, timeout=10_000)
except PWTimeout:
pass # no price: parse_price() returns None
html = page.content()
headers = {k.title(): v for k, v in resp.headers.items()}
return SimpleNamespace(status_code=resp.status, text=html, headers=headers)
def get_price_rendered(url: str) -> float | None:
return parse_price(browser_get(url).text)A headless browser downloads every script and asset, so checks take longer and move more traffic than a plain GET; page.route() drops images and fonts to cut that cost. That’s also the reason Playwright is worth enabling only for JS-based stores.
Wrapping the call in a try block avoids a classic beginner trap, where wait_for_selector() raises a TimeoutError instead of returning None, causing a script crash.
Make your Python price tracker survive rate limits and blocks
Blocks show up in different ways: an explicit HTTP 403 or 429, a stealthy CAPTCHA page, or a clean HTTP 200 stripped of the price. Since the last two slip past raise_for_status(), code that only catches exceptions records a false success or writes empty rows, making the tracker look healthy while price history goes stale.
To eliminate these blind spots, the hardening steps below build a polite and reliable collection routine, from basic request discipline to network-level changes. Whatever you apply, make logging your baseline.
Realistic HTTP headers and User-Agent rotation
Out of the box, the requests library ships Accept: */* with zero Accept-Language, a pairing no real browser exposes. Next to a Chrome User-Agent, these default HTTP headers create a mismatch strict servers flag. That’s why User-Agent rotation alone isn’t enough: match the full browser profile instead.
Python
# headers.py: rotate browser profiles
import random
# bump versions as browsers update
CHROME_UA = ("Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 "
"(KHTML, like Gecko) Chrome/157.0.0.0 Safari/537.36")
FIREFOX_UA = ("Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:159.0) "
"Gecko/20100101 Firefox/159.0")
PROFILES = [
{"User-Agent": CHROME_UA, "Accept-Language": "en-US,en;q=0.9",
"Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,"
"image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7"},
{"User-Agent": FIREFOX_UA, "Accept-Language": "en-US,en;q=0.5",
"Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"},
]
def browser_headers() -> dict:
return random.choice(PROFILES)Use one browser_headers() profile per IP: a real shopper doesn’t jump from Chrome to Firefox between two product pages.
TLS fingerprints and curl_cffi
Even flawless headers can earn a 403: the TLS handshake identifies the client first, and Python’s native stack negotiates it differently than Chrome or Firefox. curl_cffi resolves this by reproducing a browser’s TLS and HTTP/2 fingerprint.
Python
# tls_fetch.py: fetch a page using browser impersonation
from curl_cffi import requests as cffi_requests
from scraper import parse_price
url = "https://web-scraping.dev/product/1"
resp = cffi_requests.get(url, impersonate="chrome", timeout=15)
print(resp.status_code, parse_price(resp.text))The snippet passes no custom headers on purpose: impersonate="chrome" already sends Chrome’s defaults, and layering a Firefox profile on top would bring the mismatch back. Client-rendered prices still require Playwright alongside, as curl_cffi can’t execute JavaScript.
Rotating residential proxies for repeated price checks
At dozens of daily checks, repeated requests from one IP quickly start triggering 403s and CAPTCHAs. Rotating proxies spread traffic across multiple IPs, cutting calls per address.
For retail price monitoring, the choice usually comes down to two options:
- Datacenter addresses cost less, but many stores flag traffic from such IP ranges as automated.
- Residential IPs belong to home internet subscribers and hold up better on demanding platforms.
Which of the proxy types for scraping fits depends on how strict the target is.
Proxies replace only the address: headers and the TLS fingerprint stay whatever your script sends.
Residential pools offer two routing modes: rotating proxies switch IPs per request or on a timer, while sticky sessions hold the same exit point for a set period. IP rotation is a typical fit for price tracking, where each product check stands alone.
To move the tracker onto proxies, add your provider’s connection string to .env:
Python
# Store proxy credentials
echo 'PROXY_URL=http://USERNAME:PASSWORD@HOST:PORT' >> .envThe script then loads it into a PROXIES dict that sends both HTTP and HTTPS traffic through the rented IPs:
Python
# proxy_fetch.py: send requests through a proxy pool
import os, requests
from dotenv import load_dotenv
from headers import browser_headers
load_dotenv()
PROXY = os.environ["PROXY_URL"]
PROXIES = {"http": PROXY, "https": PROXY}
def get_via_proxy(url: str) -> requests.Response:
return requests.get(url, headers=browser_headers(), proxies=PROXIES, timeout=20)For region-priced stores, Proxy-Seller’s residential proxies pin geo-targeting to the city level across 47M+ IPs in 220+ locations, so each check returns what local shoppers see.
Request delays, retries, and exponential backoff
To avoid hammering a store when rate limiting kicks in, the tracker should slow down and retry throttled calls. It uses the Retry-After header, when provided, or exponential backoff with jitter to delay retries. Every 429 and 5xx response is logged for troubleshooting.
Python
# fetch.py: retry throttled requests with backoff and jitter
import logging, os, random, time
from curl_cffi import requests as cffi_requests
PROXY = os.getenv("PROXY_URL")
PROXIES = {"http": PROXY, "https": PROXY} if PROXY else None
def http_get(url: str):
return cffi_requests.get(url, impersonate="chrome", proxies=PROXIES, timeout=15)
def polite_get(url: str, retries: int = 4, getter=http_get):
for attempt in range(retries + 1):
resp = getter(url)
if resp.status_code not in (429, 500, 502, 503, 504):
return resp # passed to the tracker to handle
if attempt == retries:
logging.error("%s: gave up after %d retries", url, retries)
return resp
header = resp.headers.get("Retry-After", "")
wait = int(header) if header.isdigit() else min(5 * 2 ** attempt, 300)
logging.warning("%s: HTTP %s, retry in %ss", url, resp.status_code, wait)
time.sleep(wait + random.uniform(0, 3))This module is the one to keep. It brings the previous layers into a single call, so every check carries curl_cffi’s Chrome fingerprint with matching headers, proxy credentials, and retry logic capped at five attempts.
HTTP 403 stays out of the repeat list on purpose: it rejects the client itself, so asking again moments later burns resources for zero gain. Even without errors, space product checks 5 to 10 random seconds apart to avoid request spikes.
DATACENTER PROXIES
Cut tracking costs on lightly protected stores
Route checks on lenient retailers through dedicated datacenter IPs with 99.7% uptime at $1.64 per IP, so costs stay predictable as your watchlist grows.
Store price history in SQLite instead of CSV
CSV works for a prototype, but history queries break it: finding the lowest price ever means rereading the whole file on every check. I keep records in SQLite: it ships with Python, needs no server, and uses an index to jump straight to one product’s rows.
Python
# db.py: two tables and a product/time index
import os, sqlite3
conn = sqlite3.connect(os.getenv("DB_PATH", "prices.db"), check_same_thread=False)
conn.executescript("""
CREATE TABLE IF NOT EXISTS products (id INTEGER PRIMARY KEY, url TEXT UNIQUE NOT NULL);
CREATE TABLE IF NOT EXISTS prices (
id INTEGER PRIMARY KEY, product_id INTEGER NOT NULL,
price REAL NOT NULL, checked_at TEXT NOT NULL DEFAULT (datetime('now')));
CREATE INDEX IF NOT EXISTS idx_prices_product_time ON prices(product_id, checked_at);
""")
def save_price(url: str, price: float) -> int:
conn.execute("INSERT OR IGNORE INTO products(url) VALUES (?)", (url,))
row = conn.execute("SELECT id FROM products WHERE url = ?", (url,)).fetchone()
conn.execute("INSERT INTO prices(product_id, price) VALUES (?, ?)", (row[0], price))
conn.commit()
return row[0]Here, check_same_thread=False is required because the scheduler runs checks in worker threads. sqlite3 rejects cross-thread connection use, so without this flag every single write would fail.
The two lookups I run most are the all-time low and the last week of prices:
Python
-- Lowest price ever per product
SELECT p.url, MIN(pr.price) AS lowest, pr.checked_at
FROM prices pr JOIN products p ON p.id = pr.product_id
GROUP BY p.id;
-- Prices for the last 7 days, newest first
SELECT p.url, pr.price, pr.checked_at
FROM prices pr JOIN products p ON p.id = pr.product_id
WHERE pr.checked_at >= datetime('now', '-7 days')
ORDER BY pr.checked_at DESC, pr.id DESC;The first query also returns the date of the low: when MIN() picks a row, SQLite takes checked_at from that same record. This won’t port: other DBs reject that statement.
Detect price changes against a threshold
Two alert rules cover most cases: a percentage drop between checks (drop_pct) to catch sales, and the first crossing of target_price to flag when the item gets cheap enough. You set both thresholds for each product back in products.csv.
Python
# detect.py: alert on price drops and target hits
def price_change(conn, product_id):
rows = conn.execute("SELECT price FROM prices WHERE product_id = ? "
"ORDER BY checked_at DESC, id DESC LIMIT 2", (product_id,)).fetchall()
if len(rows) < 2:
return None # first check
new, old = rows[0][0], rows[1][0]
return old, new, (new - old) / old * 100
def should_alert(change, row):
old, new, pct = change
target = float(row["target_price"] or 0)
return pct <= -float(row["drop_pct"] or 5) or new <= target < oldHere, target < old keeps a product parked below its target_price from alerting on every pass.
Send price alerts by email, Telegram, or Slack
Pick a notification channel for your workflow: email needs no extra app, Telegram pushes updates straight to your phone, and Slack suits shared team monitoring. Each sender reads its credentials from .env.
Email with smtplib
Gmail requires an app password tied to 2-Step Verification, which Google automatically revokes whenever you change the main account password.
Python
# alerts.py, email: send alerts through Gmail SMTP
import os, smtplib
from email.message import EmailMessage
def send_email(subject: str, body: str) -> None:
msg = EmailMessage()
msg["Subject"], msg["From"] = subject, os.environ["SMTP_USER"]
msg["To"] = os.environ["SMTP_USER"]
msg.set_content(body)
with smtplib.SMTP_SSL("smtp.gmail.com", 465) as smtp:
smtp.login(os.environ["SMTP_USER"], os.environ["SMTP_APP_PASSWORD"])
smtp.send_message(msg)Telegram Bot API
Create a bot with @BotFather, message it once, then grab the token and read your chat_id from getUpdates to populate the .env file.
Python
# alerts.py, Telegram: send alerts to your chat
import os
import requests
def send_telegram(text: str) -> None:
url = f"https://api.telegram.org/bot{os.environ['TELEGRAM_TOKEN']}/sendMessage"
data = {"chat_id": os.environ["TELEGRAM_CHAT_ID"], "text": text}
requests.post(url, data=data, timeout=10).raise_for_status()Slack incoming webhook
Create a Slack app, turn on Incoming Webhooks, pick the channel, and copy the webhook URL into .env.
Python
# alerts.py, Slack: send alerts to a team channel
import os
import requests
def send_slack(text: str) -> None:
url = os.environ["SLACK_WEBHOOK_URL"]
requests.post(url, json={"text": text}, timeout=10).raise_for_status()To check the alert path without waiting for a real drop, save two prices and let the detector compare them.
From here on, I’ll use Telegram; replace it with alerts.send_slack() or alerts.send_email("Price drop", ...) to switch, or stack calls on separate lines for multi-channel notification.
Python
# test_alert.py: trigger a fake price-drop alert
import os
from dotenv import load_dotenv
load_dotenv()
os.environ["DB_PATH"] = ":memory:" # nothing is written to disk
from db import conn, save_price
from detect import price_change, should_alert
import alerts
url = "https://web-scraping.dev/product/1"
save_price(url, 12.49)
change = price_change(conn, save_price(url, 9.99)) # fake lower price
if should_alert(change, {"target_price": "", "drop_pct": ""}):
alerts.send_telegram(f"{url}: {change[0]:.2f} -> {change[1]:.2f}")Telegram should show the product URL followed by 12.49 -> 9.99.
Run the watchlist check with a Playwright fallback
This loop runs a single pass over the watchlist, wiring the earlier modules together: it fetches prices over HTTP, saves the history, alerts on drops, and logs misses. If a page loads but the price is missing, Playwright handles the retry.
Python
# tracker.py: check the whole watchlist
import csv, logging, os, random, time
os.chdir(os.path.dirname(os.path.abspath(__file__))) # for cron runs
logging.basicConfig(handlers=[logging.FileHandler("tracker.log"), logging.StreamHandler()])
from dotenv import load_dotenv
load_dotenv() # must run before the imports below
import alerts
from db import conn, save_price
from detect import price_change, should_alert
from fetch import polite_get
from render import browser_get
from scraper import parse_price
CAPTCHA_MARKERS = ("g-recaptcha", "h-captcha", "cf-turnstile")
def is_block(resp) -> bool:
return (resp is None or resp.status_code in (403, 429)
or resp.headers.get("Cf-Mitigated") == "challenge"
or any(m in resp.text for m in CAPTCHA_MARKERS))
def read_price(resp):
return parse_price(resp.text) if resp and resp.status_code == 200 else None
def check_all() -> None:
with open("products.csv", newline="", encoding="utf-8-sig") as f:
for row in csv.DictReader(f):
url, blocked = row["url"], False
try:
resp = polite_get(url)
price = read_price(resp)
if price is None and resp and resp.status_code == 200 and not is_block(resp):
resp = polite_get(url, getter=browser_get) # price rendered by JavaScript
price = read_price(resp)
blocked = price is None and is_block(resp)
if blocked:
logging.warning("blocked: %s", url)
elif price is None and resp.status_code != 200:
logging.warning("HTTP %s: %s", resp.status_code, url)
elif price is None:
logging.warning("no price, check the selector: %s", url)
elif change := price_change(conn, save_price(url, price)):
if should_alert(change, row):
alerts.send_telegram(f"{url}: {change[0]:.2f} -> {change[1]:.2f}")
except Exception as e: # timeout, network or alert error
logging.warning("failed: %s (%s)", url, e)
time.sleep(60 if blocked else random.uniform(5, 10))
if __name__ == "__main__":
check_all()is_block() filters what the fallback skips: HTTP 403, 429, Cloudflare’s cf-mitigated:challenge header, and CAPTCHA widget classes. After a block, the loop sleeps a minute before the next product and retries the blocked item on the following pass. The widget list is a heuristic, so tweak it for your stores.
Turn the script into a scheduled tracking bot
A price bot needs a scheduler to repeat that loop on its own. I consider a six-hour interval a practical baseline for most price-monitoring tasks, assuming the retailer tolerates that frequency. For volatile catalogs, use a tighter cadence; for low-churn ones, slow to daily checks.
Three scheduling options cover most setups:
Tool | Setup effort | Survives reboots | Where it runs |
APScheduler | A short launcher script | No | An open terminal on your local machine |
cron / Task Scheduler | One line in the OS scheduler | Yes | An always-on PC or server |
GitHub Actions | A workflow file and repository secrets | Yes | GitHub’s cloud |
APScheduler runs inside a script next to the tracker, starting a pass right away and every six hours after, as long as the process stays up:
Python
# run.py: launch the scheduled price checks
from datetime import datetime
from apscheduler.schedulers.blocking import BlockingScheduler
from tracker import check_all
scheduler = BlockingScheduler()
scheduler.add_job(check_all, "interval", hours=6, next_run_time=datetime.now())
scheduler.start()For a price bot that survives reboots, let a cron job (Linux/macOS) or Task Scheduler (Windows) invoke the tracker directly; the initial check waits for the first scheduled slot:
Python
# Linux/macOS (crontab -e)
0 */6 * * * /opt/tracker/.venv/bin/python /opt/tracker/tracker.py
# Windows Command Prompt
schtasks /Create /TN PriceTracker /SC HOURLY /MO 6 ^
/TR "C:\tracker\.venv\Scripts\python.exe C:\tracker\tracker.py"GitHub Actions runs scheduled workflows on GitHub’s servers, so your computer can stay off. Since each job starts on a clean machine, the workflow has to commit prices.db back to the repository after every pass, and the .env values go to repository secrets.
Where DIY price trackers break at scale
Signs a homegrown tracker is reaching its limits:
- Constant selector fixes after silent store redesigns
- Climbing block rates despite backoff
- Passes that overrun their interval or overlap
- SQLite locks under concurrent writes
At that point, the script should grow into a distributed pipeline: CSV gives way to a URL queue, sequential checks to parallel workers, and SQLite to PostgreSQL, with dedicated proxy infrastructure keeping per-IP rates flat under concurrency.
Legal and ethical price scraping
Rules for price scraping Python projects vary by jurisdiction and store terms, yet a few universal principles apply:
- Collect public prices only and stay out of anything behind a login.
- Read robots.txt and the ToS before adding a site, skip disallowed paths, and drop it if automated access is banned.
- Keep the request rate moderate so the tracker never strains retailer servers.
I’d also suggest clearing commercial projects with a lawyer.
Which price tracking setup fits your project
For a handful of products, I’d keep the tracker lean: browser headers, SQLite, and instant Telegram alerts, all running from your home IP via APScheduler in your terminal. With four checks per SKU a day, spaced 5 to 10 seconds apart, it gives a store little reason to throttle you.
At dozens to hundreds of items tracked daily, the full stack earns its place. Cron or GitHub Actions runs passes while your laptop sleeps, Slack puts the team in the loop, backoff absorbs rate limits, and rotating residential proxies split the load across the IP pool. My cue to switch is the first 403 or CAPTCHA a retailer sends back.
PER-REQUEST ROTATION
Don’t let your price history go stale
Residential IPs start at $3.5/GB and give the tracker a new address for every call, so fresh rows keep landing on schedule.
FAQ
The scraping frequency depends on the industry and your target retailer’s update cadence. Every 6 to 12 hours suits most retail products. Use hourly checks for fast categories such as electronics or flash sales, and daily or weekly ones for slow catalogs like B2B supplies or books. Pick the longest interval that still catches changes in time, since the load adds up quickly: four checks a day for 50 products means 200 requests to one store, which lenient sites absorb while strict ones may flag.
A Python price tracker gets blocked when repeated checks form a pattern a store can spot: one IP, default requests headers, Python’s TLS fingerprint, and clockwork timing. The response reveals the trigger. HTTP 429 means you check too often, so slow down with backoff. HTTP 403 or CAPTCHA means the client itself is flagged: match browser headers, switch to curl_cffi, and add IP rotation. A 200 without a price raises no error, so inspect the HTML: a challenge page counts as a block, while an empty price element calls for Playwright.
Use each retailer’s affiliate data program if you’re eligible. Amazon’s Creators API, which replaced Product Advertising API 5.0, requires an Associates account with 10 qualifying sales in 30 days. Walmart’s Affiliate Program, run through Impact, gives approved members product data feeds. Without either, use commercial scraper APIs that sell already-parsed product pages, or run a DIY tracker with a slow pace and rotating residential IPs, since both retailers block repeated requests from one address fast.
Use Keepa or CamelCamelCamel for Amazon-only shopping alerts, and build your own tracker for everything else. The two services show years of Amazon price history for free. CamelCamelCamel emails you on price drops, while Keepa adds push and Telegram notifications and sells API access for your own code. By contrast, a DIY tracker can cover any store alongside Amazon (such as Walmart, Target, or Shopify shops) and save raw data from custom fields in your database for repricing. On the downside, it requires ongoing maintenance and records prices only from the day you start it.
PROXIES FROM $0.02/IP
Ready to put this into practice?
Pick a proxy type and location, and start using it within minutes.
Instant delivery
24/7 support
Refund policy
About the author


