We extract ICE/IC schedules, Sparpreis fares, real-time delay metrics, and station intelligence from bahn.de. Delivered as clean JSON, CSV, or Parquet to S3, BigQuery, or Postgres on your cadence.
Structured, schema-consistent data across all major object types — delivered clean, typed, and ready to query.
Complete list of extractable fields for Train Schedules objects from bahn.de. All fields typed and schema-versioned.
"train_number": "ICE 74", "train_type": "ICE", "origin": "Berlin Hbf", "destination": "Frankfurt(Main)Hbf", "departure_time": "2026-10-12T08:30:00Z", "arrival_time": "2026-10-12T12:45:00Z", "duration_minutes": 255, "transfers": 0
| # | train_number | train_type | origin | destination | departure_time | arrival_time |
|---|---|---|---|---|---|---|
| 1 | ||||||
| 2 | ||||||
| 3 |
Complete list of extractable fields for Pricing & Fares objects from bahn.de. All fields typed and schema-versioned.
"train_number": "ICE 74", "fare_class": "2nd Class", "fare_name": "Super Sparpreis", "price": 29.9, "currency": "EUR", "bahncard_25_price": 22.4, "city_ticket_included": false, "scraped_at": "2026-05-12T09:14:00Z"
| # | train_number | fare_class | fare_name | price | currency | bahncard_25_price |
|---|---|---|---|---|---|---|
| 1 | ||||||
| 2 | ||||||
| 3 |
Complete list of extractable fields for Real-Time Status objects from bahn.de. All fields typed and schema-versioned.
"train_number": "ICE 74", "date": "2026-10-12", "scheduled_departure": "08:30:00", "actual_departure": "08:42:00", "delay_minutes": 12, "platform_change": true, "original_platform": "4", "new_platform": "2", "status": "DELAYED"
| # | train_number | date | scheduled_departure | actual_departure | delay_minutes | platform_change |
|---|---|---|---|---|---|---|
| 1 | ||||||
| 2 | ||||||
| 3 |
Complete list of extractable fields for Route & Stops objects from bahn.de. All fields typed and schema-versioned.
"train_number": "ICE 74", "stop_sequence": 3, "station_name": "Halle(Saale)Hbf", "scheduled_arrival": "09:45:00", "actual_arrival": "09:47:00", "scheduled_departure": "09:48:00", "actual_departure": "09:50:00", "stop_duration_minutes": 3
| # | train_number | stop_sequence | station_name | scheduled_arrival | actual_arrival | scheduled_departure |
|---|---|---|---|---|---|---|
| 1 | ||||||
| 2 | ||||||
| 3 |
Complete list of extractable fields for Station Data objects from bahn.de. All fields typed and schema-versioned.
"station_id": "8011160", "station_name": "Berlin Hbf", "category": 1, "db_lounge": true, "lockers": true, "wifi": true, "step_free_access": true, "parking_spaces": 800
| # | station_id | station_name | category | db_lounge | lockers | wifi |
|---|---|---|---|---|---|---|
| 1 | ||||||
| 2 | ||||||
| 3 |
Our bahn.de scraper handles every layer of the platform: schedule generation, dynamic fare extraction, real-time delay tracking, and station facility mapping — with strict session management and IP rotation built in.
Capture ICE, IC, RE, and S-Bahn schedules including origin, destination, transfers, and total duration across any date range.
Extract Super Sparpreis, Sparpreis, and Flexpreis tiers in real time. Track price volatility leading up to departure dates.
Monitor live delays, platform changes, and disruption messages across the entire DB network.
Capture adjusted pricing for BahnCard 25 and BahnCard 50 holders across 1st and 2nd class fares.
Extract international connections operated in partnership with ÖBB, SBB, and SNCF directly from the bahn.de interface.
Map station facilities, DB Lounge availability, locker access, and local transit connections.
Detect high-occupancy warnings and mandatory reservation flags for specific high-speed routes.
Extract pricing natively in EUR, CHF, or GBP based on selected point of sale parameters.
Run one-off bulk route exports or configure continuous pipelines at hourly cadences with change-detection diffing.
Brief in. Clean data out.
Provide origin-destination pairs, station IDs, or train numbers. We design the extraction schema together.
We configure Scrapy / Playwright crawlers, proxy rotation, session management, and HAFAS API parsing for bahn.de.
Schema validation, null-rate checks, price-outlier detection, and sample schedules before full launch.
JSON / CSV / Parquet pushed to your S3 bucket, BigQuery dataset, or Postgres database on agreed cadence.
Deutsche Bahn utilises strict session tokens and rate limits to prevent aggressive polling. Here's how we stay resilient.
Bahn.de relies heavily on stateful session tokens for pricing and route generation. Our pipelines manage full cookie jars and token lifecycles, ensuring valid requests without triggering session invalidation errors.
DB blocks IPs that exhibit aggressive polling behaviour. We route requests through German and European residential ISP proxies, normalising request rates to mimic human search patterns.
Instead of purely scraping the DOM, we intercept and parse the underlying JSON payloads from the HAFAS routing engine, guaranteeing structured, typed data extraction for complex route topologies.
For large route matrices, we maintain a hash index of last-seen prices and delays. Subsequent runs only push diffs, reducing compute cost and downstream processing load.
Every run emits structured logs to our observability stack. We alert on null-rate spikes, missing fare tiers, and schema drift, responding before you notice.
OTAs and multimodal travel platforms integrate DB schedules and pricing into their consumer booking engines.
Long-distance bus operators and regional airlines monitor DB pricing to optimise their own dynamic fare models.
Corporate booking tools track ticket prices and delay metrics to enforce travel policies and forecast budgets.
Insurtech and compensation platforms model historical delay data to assess risk and automate passenger claims.
Logistics providers track passenger rail delays as proxy indicators for broader rail network congestion affecting freight.
Sustainability platforms extract route distances and train types to calculate comparative CO2 emissions against air travel.
"bahn.de orchestrates European rail mobility, exposing vast schedule and pricing datasets — but querying it at scale requires navigating complex session tokens and aggressive rate limits."
Extracting reliable data from Deutsche Bahn means managing HAFAS API tokens, bypassing strict IP rate limits, and parsing deeply nested JSON responses for dynamic pricing. DataFlirt manages this infrastructure so your engineering team can focus on integrating the data, not maintaining the scrapers.
Everything supported by our bahn.de scraper — rendered SPA elements, auth walls, rate-limit evasion and beyond.
Open-source tooling on proven cloud infra — no vendor lock-in, full observability.
Scrapy handles crawl orchestration and HAFAS API parsing. Playwright handles initial session generation and cookie management. Combined via scrapy-playwright middleware.
We maintain pools of residential ISP proxies across DE regions. Rotation happens carefully to maintain session stickiness where required by bahn.de.
Pipelines run on AWS Lambda (burst) and ECS (sustained). Airflow handles scheduling and dependency management. All state stored in managed Postgres.
Data delivered to where your team already works — no new tooling required.
About bahn.de scraping, legality, and pipeline operations.
Ask us directly →Scraping publicly available schedule, pricing, and delay information is generally permissible. DataFlirt targets only public, non-authenticated data. We do not extract personal user data or circumvent authentication walls. Clients should review DB's terms of service and consult legal counsel for specific commercial use cases.
DB relies on strict session state for pricing queries. We use Playwright to initialise valid sessions, extract necessary cookies and tokens, and pass them to our HTTP clients. Sessions are rotated automatically before expiration.
Yes. We can configure high-frequency polling on specific train numbers or stations to capture delays, platform changes, and disruption messages with sub-minute latency.
Yes. We pass the necessary parameters to extract standard fares alongside BahnCard 25 and BahnCard 50 discounted rates for both 1st and 2nd class.
Yes. Any route visible on bahn.de, including those operated by partner networks like ÖBB, SBB, or SNCF, can be extracted using our pipeline.
Our smallest packages start at a defined list of origin-destination pairs or station IDs with daily delivery. For high-frequency real-time monitoring, we price based on request volume and compute requirements.
20-minute scoping call. Pilot dataset within the week. Production within two. Whether you need a daily snapshot of Sparpreis fares or real-time delay feeds across the ICE network — we scope, build, and operate the pipeline. Tell us what you need.