Fire tenders were able to bring the flames under control after nearly three hours.
The deceased have been identified as Ria Thakur (25), a beauty parlour owner, and her cousin Manish (24). Those with burn injuries were admitted to a hospital.
DIG, Kanpur Range, Sonia Singh said, "Prima facie it seems that the fire was caused due to a short circuit."
According to Circle Officer (CO), Kalyanpur, Rajneesh Verma, the hostel owner Baijnath and one of his sons KK Singh live in their native village, while his elder son Dharmendra lived in the hostel and carried out a cable business.
Police said a complaint was lodged by local residents, and investigations are on.
In the hostel-cum-residence, 15 persons -- eight family members of Mr Singh, five students of a coaching institute, a beauty parlour owner and one of her cousins who had come to visit her -- were present when the fire broke out.
A car and huge stock of electric cables kept in the underground store room were destroyed in the blaze.
Get the latest election news, live updates and election schedule for Lok Sabha Elections 2019 on ndtv.com/elections. Like us on Facebook or follow us on Twitter and Instagram for updates from each of the 543 parliamentary seats for the 2019 Indian general elections.