A web scraping application that collects daily USD-INR TT buy rates from multiple Indian bank websites and visualizes the trends over time.
Live Dashboard: https://g-akshay.github.io/ForexScrapper/
- Multi-bank scraping — Fetches TT buy rates from SBI, ICICI, HSBC, Kotak, Canara, IOB, IDFC, BOB, BOI, and Yes Bank
- Automated daily runs — GitHub Actions workflow triggers at 11 AM IST to collect fresh rates
- Historical tracking — Maintains the last 15 days of rate data in JSON format
- Interactive chart — Plotly.js-powered line chart showing rate trends across banks
- Top banks table — Displays the top 5 banks with the highest average rates
- Scraping: Python, BeautifulSoup, Selenium (for JS-rendered pages)
- Visualization: Plotly.js, HTML/CSS
- Automation: GitHub Actions (scheduled cron job)
- Hosting: GitHub Pages
ForexScrapper/
├── .github/workflows/
│ └── forex_scraper.yml # GitHub Actions workflow (daily cron)
├── src/
│ ├── banks/ # Individual bank scraper modules
│ │ ├── scraper_sbi.py
│ │ ├── scraper_icici.py
│ │ ├── scraper_hsbc.py
│ │ ├── scraper_kotak.py
│ │ ├── scraper_canara.py
│ │ ├── scraper_iob.py
│ │ ├── scraper_idfc.py
│ │ ├── scraper_bob.py
│ │ ├── scraper_boi.py
│ │ └── scraper_yes.py
│ ├── all_banks_data.json # Aggregated historical rate data
│ ├── bank_urls.json # Bank forex page URLs
│ ├── requirements.txt # Python dependencies
│ └── run_all_scrapers.py # Main scraper orchestrator
├── index.html # Frontend dashboard
├── LICENSE # MIT License
└── README.md
- Python 3.9+
- Google Chrome (for Selenium-based scrapers)
pip install -r src/requirements.txtpython src/run_all_scrapers.pyThis runs all bank scrapers concurrently (Selenium-based scrapers in parallel, followed by request-based ones) and updates src/all_banks_data.json with the latest rates.
Open index.html in a browser. It reads from src/all_banks_data.json to render the chart and table.
run_all_scrapers.pyorchestrates all scrapers usingThreadPoolExecutor- Selenium-based scrapers (Kotak, IOB, IDFC) run in parallel with headless Chrome
- Request-based scrapers (SBI, Canara, HSBC, ICICI) run concurrently after
- Results are merged into
all_banks_data.json, retaining the last 15 days of data - GitHub Actions commits and pushes the updated data daily, which is served via GitHub Pages
MIT