Solar AI Finance: Building an AI Solar Advisor App for Pakistan

Case Study
Solar AI Finance: Building an AI Solar Advisor App for Pakistan
A cross-platform product that turns a few questions about a household into a properly sized solar, inverter and battery system — with transparent cost and payback estimates tuned to Pakistani tariffs and load-shedding.
Overview
Solar AI Finance is an AI-powered solar advisor app for Pakistan. It analyses a household’s appliances, location, electricity provider and backup needs, then sizes an appropriate solar system and estimates its cost, savings and payback period. An in-app AI assistant answers follow-up questions about sizing, backup and net metering.
designed and built the product end to end: a React Native mobile app and a Next.js web app that share a single backend and a single calculation engine, so a household receives identical recommendations on whichever platform it uses. This case study covers the problem, the product, the sizing and ROI methodology, the technical architecture, and the path from concept to a Google Play beta.
The Problem: Solar Is Booming, but Buyers Are Flying Blind
Electricity tariffs in Pakistan have risen sharply, and persistent load-shedding has pushed large numbers of households toward rooftop solar. The buying journey, however, is confusing and stacked against the consumer. Most homeowners have no independent way to know how many panels they need, what inverter rating to ask for, or how much battery storage actually covers their outages. They depend on a single installer’s quote, which is often oversized, hard to compare and impossible to sanity-check.
Net metering rules, NEPRA regulations and DISCO-specific application procedures compound the problem: they are poorly documented and change frequently. The outcome is predictable — buyers overspend, under-plan their backup, or stall entirely.
set out to build a neutral first opinion: a tool that gives any household a credible, transparent starting point before it ever speaks to an installer.
The Solution: A Guided Solar Plan in Minutes
The core of the product is the Solar Starter wizard, a short guided flow that produces a complete system plan:
Location — province and city, used to tailor DISCO and regulatory information.
Electricity provider (DISCO) — the distribution company shown on the user’s bill.
Appliances — each appliance with quantity, wattage and hours of use per day, with a flag for the ones that must keep running during an outage.
Backup target — 2, 4, 6 or 8 hours of battery backup, or no battery at all.
From those inputs the app instantly returns daily energy consumption, recommended solar array size and panel count, inverter continuous and surge ratings, and battery capacity — all computed on the device. Users can name and save multiple plans, then rename, edit or delete them, making it easy to compare a “whole-house AC” scenario against a “fans and fridge only” one.
Supporting tools
Electricity bill check — look up a current bill directly from the user’s DISCO by reference number.
Electricity bill history — save bills over time, including photo uploads where an AI model extracts the amount due, due date, units consumed and billing month, with a consumption trend chart.
Pakistan solar regulations — a sourced, dated knowledge base covering net metering, NEPRA prosumer rules, tariffs and per-DISCO application processes.
AI Solar Assistant — an in-app chat assistant for follow-up questions about sizing, backup and savings.
Cost and payback projections — estimated system cost, year-one savings, payback period and 10- and 20-year net position across conservative, expected and optimistic scenarios.
Downloadable PDF reports — a shareable plan summary generated server-side.
When the regulations knowledge base lacks authoritative information, the assistant says it cannot answer confidently — rather than inventing a regulatory requirement.
How the Solar Sizing Is Calculated
Transparency was a design principle: every number the app shows can be traced back to a stated assumption, and the same calculation code runs on both web and mobile so results never diverge between platforms.
Solar array size is derived from estimated daily consumption, Pakistan’s average peak sun hours (5.5) and a system efficiency factor (0.78). Panel count assumes 585 W N-type modules, the current standard rooftop panel on the Pakistani market.
Inverter sizing starts from the user’s peak simultaneous load and adds a 25% surge margin to handle the startup currents of motors and compressors in air conditioners, water pumps and refrigerators.
Battery sizing is based only on the appliances the user marked to keep running during an outage, multiplied by the chosen backup hours, then adjusted for depth of discharge and round-trip efficiency. Storage is expressed in roughly 5 kWh (48 V, 100 Ah) lithium modules, a common local unit.
Financial projections use national-average inputs — an average unit rate of Rs 55/kWh, an installed cost of Rs 160,000 per kW of solar plus Rs 40,000 per kWh of usable battery, and a 25-year horizon. The three scenarios differ in annual tariff inflation (5%, 8%, 12%) and in how much of the modelled generation is actually realised, which also absorbs panel degradation and timing losses. Users can override the unit rate and system cost with their own figures to refine the estimate.
Every results screen is explicit that these are planning estimates, not a site survey, and that the final design should be confirmed with a licensed installer.
Technical Architecture
Solar AI Finance is two clients on one backend.
Mobile app
FrameworkExpo SDK 54, React Native 0.81, React 19 NavigationExpo Router (file-based, typed routes) — a drawer wrapping a four-tab product area Formsreact-hook-form with yup validation Design systemCustom theme tokens and shared UI primitives; Sora for headings, Manrope for body Storageexpo-secure-store for auth tokens, AsyncStorage for preferences LocalisationCustom i18n context — full English and Urdu with right-to-left layout Builds & updatesEAS Build for store binaries, EAS Update for over-the-air fixes
Web app and shared backend
FrameworkNext.js 16 (App Router), TypeScript, React 19 StylingTailwind CSS v4 DatabaseMongoDB via Mongoose AuthCustom JWT access tokens with opaque refresh tokens, bcrypt hashing, email verification and password reset via one-time codes AIGroq — assistant and electricity-bill extraction EmailNodemailer over SMTP for transactional mail Image storageCloudinary for uploaded bill photos PDFReact-PDF for server-generated plan reports
The most consequential architectural decision was keeping the solar and financial calculation modules identical on both platforms. The same household must get the same system size, the same panel count and the same payback figure whether it opens the web app or the phone, so the calculation layer is treated as a shared contract and kept in exact sync.
Designing for the Pakistani Context
Several product decisions were driven specifically by the local market:
Urdu and RTL from day one. The entire app, not just marketing copy, is translated and lays out right-to-left in Urdu.
Load-shedding as a first-class input. Backup duration is a core wizard step, because outage resilience is often the main reason a household buys solar.
Local hardware defaults. Panel wattage and battery module sizes track what installers actually stock; when the market moved from 550 W to 585 W panels, the defaults and saved-plan recalculation followed.
Regulatory honesty. The regulations knowledge base is sourced and dated, and the assistant declines rather than hallucinates when authoritative guidance is missing.
Play Store data-safety compliance. A full account and data deletion request flow is built into the app and exposed on a public web URL.
Delivery and Current Status
The product was built UI-first, with each screen sequenced early so the design could be reviewed as it came together, and shipped incrementally. The first release delivered authentication, the Solar Starter wizard, saved plans, the DISCO bill check and full English/Urdu support. The following release brought a complete redesign, a new navigation model, a “no battery” sizing option, panel and battery purchasing guidance, and an expanded in-app About and “What’s new” section.
Solar AI Finance is currently in beta (v0.1.0), distributed through Google Play Closed testing via an opt-in link, with premium features staged behind a “Coming soon” state ahead of the paid-tier launch. The AI Solar Assistant has been unlocked ahead of the rest of the paid features.
Results and Impact
A household can go from zero to a saved, named solar plan — system size, inverter rating and battery capacity — in a few minutes, without handing any installer its phone number.
Every recommendation is backed by a visible assumption, giving buyers a concrete document to take to installers and to compare quotes against.
One calculation engine across web and mobile means the two platforms can never give conflicting advice, which protects user trust as the product scales.
The regulations knowledge base and AI assistant turn scattered, out-of-date net metering information into a single answerable resource.
Technologies Used
React Native, Expo, Expo Router, React 19, TypeScript, Next.js 16, Tailwind CSS v4, MongoDB, Mongoose, Groq AI, Cloudinary, Nodemailer, React-PDF, react-hook-form, yup, EAS Build, EAS Update.
Frequently Asked Questions
What does Solar AI Finance do?
It sizes a solar, inverter and battery system for a Pakistani household from its appliances, location, electricity provider and backup needs, then estimates system cost, yearly savings and payback period.
Is it a mobile app or a web app?
Both. There is a React Native app for Android and a Next.js web app, and they share one backend and one calculation engine so recommendations match across platforms.
How accurate are the estimates?
They are planning estimates based on Pakistan national averages for sun hours, system efficiency, tariffs and equipment pricing. Real output depends on roof orientation, shading, equipment quality and installation, so the app recommends confirming the final design with a licensed installer.
Does it support Urdu?
Yes. The entire app is available in English and Urdu with full right-to-left layout.
Who built it?
, a software product studio.
Solar AI Finance is a product of Solar and financial figures reflect Pakistan national-average assumptions as of 2026 and are planning estimates, not financial advice.



