A complete eBay sold listings URL
This URL opens used Nintendo Switch OLED sales on ebay.com, newest first, 240 per page:
https://www.ebay.com/sch/i.html?_nkw=nintendo+switch+oled&LH_Sold=1&LH_Complete=1&_sop=13&_ipg=240&LH_ItemCondition=3000Everything after ? is a parameter. eBay does not publish documentation for these; the table below reflects how eBay's search pages behave as of October 2026, and it is the same mapping CompSniper's engine uses for every sold search it runs.
eBay search URL parameter reference
| Parameter | What it does | CompSniper API field |
|---|---|---|
| _nkw=nintendo+switch+oled | Search keywords | keyword |
| LH_Sold=1 | Only listings that ended with a sale | sold=true |
| LH_Complete=1 | Only ended listings, sold or not. Pair it with LH_Sold=1 | sold=true |
| _sacat=139971 | Category ID. 0 means all categories | categoryId |
| _ipg=240 | Results per page. eBay honors 60, 120 and 240 | count |
| _pgn=2 | Page number, starting at 1 | page |
| _sop=13 | Sort: 13 ended recently, 10 newly listed, 15 lowest price + shipping, 16 highest, 7 nearest | sortOrder |
| _udlo=100&_udhi=300 | Minimum and maximum price | minPrice, maxPrice |
| LH_ItemCondition=3000 | Condition: 1000 New, 3000 Used. Others (such as 1500 Open box) vary by category | itemCondition, conditionId |
| LH_BIN=1 or LH_Auction=1 | Buy It Now only, or auctions only | buyingFormat |
| LH_BO=1 | Listings that accepted offers | buyingFormat |
| LH_PrefLoc=1 | Item location: 1 domestic, 2 worldwide | itemLocation |
Category IDs differ by country and change over time. Look them up in our eBay category ID reference rather than hard-coding one you found in an old forum post.
Build sold listings URLs in Python or JavaScript
Use your language's URL encoder so spaces, quotes and symbols in the keyword are escaped correctly.
from urllib.parse import urlencode
def ebay_sold_url(keyword, site="www.ebay.com", category=None, condition=None,
min_price=None, max_price=None, page=1, per_page=240):
query = {"_nkw": keyword, "LH_Sold": "1", "LH_Complete": "1",
"_sop": "13", "_ipg": str(per_page)}
if category: query["_sacat"] = category
if condition: query["LH_ItemCondition"] = condition # 1000 new, 3000 used
if min_price: query["_udlo"] = min_price
if max_price: query["_udhi"] = max_price
if page > 1: query["_pgn"] = str(page)
return f"https://{site}/sch/i.html?{urlencode(query)}"
print(ebay_sold_url("nintendo switch oled", condition="3000"))The same parameters work on other eBay countries
Swap the host to search another marketplace: www.ebay.co.uk, www.ebay.de, www.ebay.fr, www.ebay.it, www.ebay.es, www.ebay.ca or www.ebay.com.au. The parameters stay the same; prices come back in the local currency, and category IDs can differ.
Opening the URL is easy. Fetching it from code is not
A sold URL works perfectly in your browser. Requesting it from a script is a different story: eBay increasingly needs a signed-in session to show sold results, challenges automated traffic with captchas, and changes its result markup (the old li.s-item selectors no longer match). eBay's own APIs do not fill the gap either; see how to get sold items with the eBay API.
CompSniper runs these exact URL parameters behind a REST API, with signed-in sessions, proxies and a maintained parser, and returns clean JSON:
curl --get "https://api.compsniper.com/v1/scrape" \
-H "Authorization: Bearer $COMPSNIPER_API_KEY" \
--data-urlencode "keyword=nintendo switch oled" \
--data-urlencode "sold=true" \
--data-urlencode "itemCondition=used" \
--data-urlencode "sortOrder=endedRecently" \
--data-urlencode "count=240" \
--data-urlencode "ebaySite=ebay.com"eBay URL parameter questions
What does LH_Sold=1 mean in an eBay URL?
LH_Sold=1 limits eBay search results to listings that ended with a sale. It is the URL version of ticking Sold items in the filter sidebar. Pair it with LH_Complete=1, which is what eBay itself adds when you tick the filter.
What is the difference between LH_Sold and LH_Complete?
LH_Complete=1 shows every ended listing, sold or not. LH_Sold=1 narrows that to listings that actually sold. Use both for sold prices, and LH_Complete=1 alone if you also want to see what failed to sell.
What does _sop=13 mean on eBay?
_sop is the sort order. 13 sorts sold and completed results by ended recently, so the newest sales come first. 10 is newly listed, 15 is price plus shipping lowest first, and 16 is highest first.
How do I show 240 results per page on eBay?
Add _ipg=240 to the search URL. eBay honors page sizes of 60, 120 and 240; other values fall back to a default. Use _pgn=2, 3 and so on for later pages.
What is _sacat in an eBay URL?
_sacat is the category ID. _sacat=0 searches all categories, and a number such as 139971 (video game consoles on ebay.com) limits the search to one category. Our eBay category ID reference lists 17,000+ IDs.
Can I scrape the eBay sold listings URL with code?
eBay requires a signed-in session for reliable sold results and challenges automated traffic, so a plain HTTP request to the URL usually gets a captcha or a partial page. A sold listings API handles sessions, parsing and retries and returns JSON instead.
Written by CompSniper's founder. The parameter mapping is the one CompSniper uses in production as of October 3, 2026. eBay can change undocumented parameters at any time.