What Did We Build?
- Allows you to select a country, then choose a cricket ground within it.
- This will output the weather forecast for the next five days
- You can find out whether the result might be rained off, shortened, suffer bad light, etc
Inspiration For This Project
The initial inspiration for the project came from the fourth test of the 2023 Ashes series. In short, England were on course for an important victory in a must-win game against Australia, only for rain to halt play for extended periods of time. Having spent two straight days frantically checking weather apps and praying for sunshine, I decided it might be useful to build a tool to help cricket fans to track the weather at stadiums around the globe. In a cricketing sense, weather conditions can determine whether a match will be shortened or abandoned, what the result might be, and whether the conditions will favour batting or bowling. This makes a tracking tool incredibly useful for determining whether to attend a particular match and what the expected result might be.
What We Did
Choosing Countries and Grounds
Gathering the choice of country and ground. This data object populates the second dropdown and also includes a reference to the ground’s actual location (or as near as I can get via the OpenWeather API locations)


Getting the Weather Data
Getting the weather via the API. How is it secure, how do I submit the city and why do I use
Updating the Content
Updating content via dropdowns and asynchronous calls for more data


Displaying the Weather Data
Setting degrees from Kelvin to celsius, setting the content into days and dynamically generating the HTML code
The Result and Future Improvements
I am relatively happy with the project in that the system is extremely fast and functional. The code is well optimised, easily extensible and offers some interesting functionality throughout. However, it doesn’t quite meet the lofty goals that I set myself when first starting out. My initial vision for the project was to allow users to select a cricket ground, then choose a current or future date for up to thirty days in the future. This would provide a comprehensive five day weather forecast for the location, beginning on the date selected and broken down into one hour increments. To help people identify appropriate dates to check, I had also hoped to provide a list of all future fixtures that were scheduled at each venue.
Unfortunately the OpenWeather API contains several subscription tiers, which limit both the types of data available and the format in which they are provided. This limitation meant that I could not access data in hourly intervals, nor provide a comprehensive breakdown containing the percentage chance of rain, humidity and wind speed, unless I upgraded to a higher access tier for more than £2000 per annum. Consequently, whilst the idea is viable and the proof of concept is functional, it simply isn’t financially feasible for me to implement my ideal build at this time.
In addition to the above, I was also unable to locate an API which could provide a list of upcoming cricket fixtures by venue. As the tool currently contains weather tracking for around one hundred different stadiums, it simply isn’t feasible to update this information manually. I have, however, noted that the Cricket Data API is both affordable and in active development. As their API is currently able to provide fixture data that includes the venue name, I’m hopeful that I might be able to add this functionality in the near future!
If I can find a way to include the additional fixture and weather data, I will also overhaul the design to make the tool more visually appealing. There are a number of simple styling additions which would greatly improve the aesthetics of the tool, including the use of country flags, the addition of weather icons and styling the selection boxes using the Select2 JavaScript library. Given the growing popularity of the game globally, it would also be nice to include some additional countries and stadiums, such as the Netherlands, Scotland or the USA.
How It Looks
Similar Projects
Get In Touch
Thank you for your interest in our business. If you have any questions about our services, a project you’d like us to help with, or if you just want to say hello, please don’t hesitate to get in touch. We look forward to hearing from you!