Trip.com Scraper
Extract global hotel inventory, flight bookings, and travel package deals from Trip.com international travel platform.
curl -X POST https://api.spider.cloud/scrape \
-H "Content-Type: application/json" \
-d '{"url": "https://www.trip.com/hot/hotel-ranking/", "return_format": "markdown"}' This exact call produced the response beside it. Get a key →
- Content
- 421 lines 19.8 KB markdown
- Render
- No browser plain request is enough
- Fetch time
- 772 ms one measured fetch
- This fetch cost
- $0.000292 bandwidth plus compute
# Search for Top-Ranking Hotels
## Most People Searched for Following Top-ranking Hotels
## Most People Booked Following Top-ranking Hotels
* Top 10 Beijing Hutong Hotels
* Top 10 Quality Sweets Hotels
* Top 10 Willamette University Hotels
* Top 10 Bowling-Center Hotels
* Top 10 Les Pierres Blanches Hotels
* Top 10 Amana Waterpark Hotels
## Most People Checked Following Top-ranking Hotels
* Top 10 Galeri Kristal Hotels
* TOP 10 Sharm El Sheikh hotels
## Recommend
* Top 10 Windermere Motor Boat Racing Club Hotels
* Top 10 Cinnamon Grand Colombo Hotels
* Top 10 The Summit at Fritz Farm Hotels
* Top 10 Palais des Congres Hotels
* Top 10 The Ascott Limited Hotels
* Top 10 Casino de Montreal Hotels
* Top 10 Salt Lake City Marriott City Center Hotels
* Top 10 Antelope Valley Hotels You just saw the output.
That was one page. A key runs the same call across every URL on trip.com, with browser rendering, proxies, and concurrency. Sign up and a free balance lands on your account. No card required to test.
- Free balance on signup, no card
- Failed requests cost $0
- robots.txt respected by default
The same call, in code.
The keyless call above returns markdown. These examples add a key, so you get browser rendering, proxies, and concurrency on trip.com.
import { SpiderBrowser } from "spider-browser";
const spider = new SpiderBrowser({
apiKey: process.env.SPIDER_API_KEY!,
});
await spider.connect();
const page = spider.page!;
await page.goto("https://www.trip.com/hotels/list?city=318&checkin=2026-06-01&checkout=2026-06-05");
// No selectors, no schema. Spider reads the page and names the fields.
const data = await page.scrape();
console.log(data);
await spider.close(); import { SpiderBrowser } from "spider-browser";
const spider = new SpiderBrowser({
apiKey: process.env.SPIDER_API_KEY!,
stealth: 2,
});
await spider.connect();
const page = spider.page!;
await page.goto("https://www.trip.com/hotels/list?city=318&checkin=2026-06-01&checkout=2026-06-05");
await page.content(12000);
const data = await page.evaluate(`(() => {
const hotels = [];
document.querySelectorAll(".hotel-list-card").forEach(el => {
const name = el.querySelector(".hotel-card-name")?.textContent?.trim();
const price = el.querySelector(".hotel-card-price")?.textContent?.trim();
const rating = el.querySelector(".hotel-card-score")?.textContent?.trim();
const stars = el.querySelector(".hotel-card-star")?.children.length;
const location = el.querySelector(".hotel-card-location")?.textContent?.trim();
if (name) hotels.push({ name, price, rating, stars, location });
});
return JSON.stringify({ total: hotels.length, hotels: hotels.slice(0, 10) });
})()`);
console.log(JSON.parse(data));
await spider.close(); Ready for volume? Get an API key →
Fields you can pull.
Spider names these from the page. The capture above came back as markdown; the same
call with return_format: "json" returns them as keys.
What trip.com costs to scrape.
The capture above cost $0.000292 to fetch. Pricing is $1 per GB of pre-transformation bandwidth plus $0.001 per CPU minute, so a page like this one lands at a fraction of a cent. Failed requests are billed at $0.
- Free balance on signup
- No card required to test
- Balance never expires
More Travel scrapers.
Expedia Scraper
Extract travel deals, hotel listings, flight prices, and booking data from Expedia.
Airbnb Scraper
Extract Airbnb listings, pricing, host info, reviews, and availability from search results.
TripAdvisor Scraper
Extract hotel reviews, restaurant ratings, attraction data, and traveler photos from TripAdvisor.
Start scraping trip.com.
You already have the call. A key raises the rate limit and turns on browser rendering, proxies, and concurrency. Balance never expires, and top-ups go through secure checkout.