I want to create a website that will fetch data from other websites' databases and display it on my website. When a user visits my website and enters their unique reference number to check their electricity bills according to their reference number, my website scrapes data from the original website and shows it on my website. Due to my lack of experience with Laravel, I do not know how to do that. This same scenario has been implemented in PHP using cURL, but I'm not sure how it will be implemented in Laravel.
If there is anyone who can assist me in completing this task, please let me know.
@jason06 I don't think the company whose data you are using will care. Without a written permission from them, you might be heading up shit creek, and no one here will want to be in any way involved in such.
@jlrdw A user wants a simple, clean user interface that the original website does not have, so this idea clicked in our heads to solve the user's problem of bad UI and help them get their electricity bills without hesitation.
In addition, there is another website that does the same thing, but with another electricity company
This same scenario has been implemented in PHP using cURL, but I'm not sure how it will be implemented in Laravel.
pretty much the same
I hope you are holding users credentials encrypted?
Its not a service I would personally use since i would not share one sites password with another, but that's just me. Maybe your customers are more naive
Thats true here many websites using the same things some are using iframe like this and some are using scrapping techniques and also you can use api from website to use it the one which is using iframe for Sepco online bill is
@zahid0046 API exists for a reason. They are created so that consumers can be assured that the API will be stable at a specific version. Scrape pages and you are on your own. Wake up one day to a stream of annoyed customers because the target website changed the layout and basically you are on your own and your service is broken until you can reverse engineer the new layout.
If you’re planning to fetch electricity bill data by reference number, one important thing to keep in mind is legal access. Scraping data directly from official utility websites without permission can violate their terms.
A safer and more practical approach is to build a helper platform that guides users to check their bills online using publicly accessible methods, without storing or scraping private data.
For example, I’ve seen similar implementations where users simply enter their reference number and the system redirects or helps them retrieve bill details in a user-friendly way. One such implementation is available here: fescoebillcheck.pk. From a Laravel perspective, you can:
Use Laravel HTTP client (Guzzle) instead of raw cURL
Validate and sanitize reference numbers
Avoid storing sensitive customer data
Focus on UX, caching, and performance rather than scraping databases
This approach keeps things scalable, legal, and much easier to maintain in Laravel.