SAN FRANCISCO — Google Maps has found its way back to the iPhone.
The world’s most popular online mapping system returned late Wednesday with the release of the Google Maps iPhone app. The release comes nearly three months after Apple Inc. replaced Google Maps as the device’s built-in navigation system and inserted its own map software into the latest version of its mobile operating system.
Apple’s maps application proved to be far inferior to Google’s, turning what was supposed to be a setback for Google into a vindication. The product’s shoddiness prompted Apple chief executive Tim Cook to issue a rare public apology and recommend that iPhone owners consider using Google maps through a Web browser or seek other alternatives until his company could fix the problems. Cook also replaced Scott Forstall, the executive in charge of Apple’s mobile operating system, after the company’s maps app became the subject of widespread ridicule.
Among other things, Apple’s maps misplaced landmarks, overlooked towns, and sometimes got people horribly lost. In one example brought to light this week, Australian police derided Apple’s maps as ‘‘life-threatening’’ because the system steered people looking for the city of Mildura into a sweltering, remote desert 44 miles from their desired destination.
Google Inc., in contrast, is hailing its new iPhone app as a major improvement from the one evicted by Apple.
‘‘We started from scratch,’’ said Daniel Graf, mobile director of Google Maps. Google engineers started working on the new app before Apple’s Sept. 19 ouster, Graf said.
Digital maps are key battleground in mobile computing because they get used frequently on smartphones and can pinpoint a user’s whereabouts. That information is so prized by advertisers that they are willing to pay much higher rates for marketing messages aimed at a prospective customer in a particular location, said Greg Sterling, an analyst at Opus Research.
Google’s mapping app for the iPhone doesn’t include ads, but that is likely to change, based on the steady stream of marketing flowing through the Google Maps app on Android phones.
The additional tools in the free iPhone app include turn-by-turn directions. Google’s previous refusal to include that popular feature on the iPhone app —while making it available for smartphones running on its own Android software— is believed to be one of the reasons Apple decided to develop its own technology. The increasing friction between Google and Apple as they jostle for leadership in the smartphone market also played a role in the mapping switch.
Google’s new iPhone mapping app also offers street-level photography of local neighborhoods, three-dimensional views, public transit directions, and listings for more than 80 million businesses around the world. The app still lacks some of the mapping features available on Android-powered phones, such as directions inside malls and other buildings.
All those improvements are positives for Apple, too, Sterling said, because the availability of a more comprehensive mapping option makes it less likely that iPhone owners will switch to Android devices.
‘‘The irony is that Apple ended up getting a better version of Google Maps on its system by booting it off,’’ Sterling said. ‘‘At the same time, you could argue that Google is making a triumphant return to cheering crowds. So, in a way, everyone wins in this situation.’’
Investors didn’t see anything positive for Apple. The company’s stock slid $9.31 to close at $529.84, while Google shares crept up $5.14 to finish at $702.70.
There still isn’t a Google mapping app for Apple’s top-selling tablet computer, the iPad, but the company plans to make one eventually. For now, iPad owners can use the maps in an iPhone mode.