According to the Dawn newspaper, the Sindh High Court restrained the Karachi Port Trust (KPT) and other respondents from demolishing the Shri Laxmi Narayan Mandir at the Native Jetty Bridge.
A bench led by Chief Justice Mushir Alam asked a court official to inspect the temple and submit a report.
A constitutional petition was recently filed by Kailash Wishram, who lives in the residential quarters in the temple premises, saying that a private company in collaboration with the KPT had started some construction work, blocking access to seawater from the temple.
The petition said the construction threatened the place of worship and also the right of the minority community at large.
The secretary of ports and shipping ministry, the KPT chairman and the private firm that ran a food court under the bridge were named respondents.
It said access to seawater was one of the essential things to perform worship.
The Pakistan Hindu Council says the temple was constructed 200 years ago and many Hindu festivals are celebrated there.
It is also a sacred place for performing funerals and other religious rituals by the sea.
The court ordered that the temple, its staircase, boundary wall and corridors originally constructed may not be demolished.
Election Results for Lok Sabha Election 2019 will be out on May 23. Get the latest election news and live updates on ndtv.com/elections. Catch all the action on NDTV Live. Like us on Facebook or follow us on Twitter and Instagram for news updates from each of the 543 parliamentary seats for the election 2019