Google Inc. said an internal investigation has discovered that the roving vans the company uses to create its online mapping services were mistakenly collecting data about websites people were visiting over wireless networks.

The Internet giant said it would stop collecting Wi-Fi data from its StreetView vans, which workers drive to capture street images and to locate Wi-Fi networks. The company said it would dispose of the data it had accidentally collected.

Alan Eustace, senior vice president of engineering and research for Google, wrote in a blog post that the company uncovered the mistake while responding to a German data-protection agency's request for it to audit the Wi-Fi data, amid mounting concerns that Google's practices violated users' privacy.

Google had previously said it was collecting the location of Wi-Fi hot spots from its StreetView vehicles, but not the information being transmitted over those networks by users.

"It's now clear that we have been mistakenly collecting samples of payload data from open (i.e. non-password-protected) Wi-Fi networks, even though we never used that data in any Google products," wrote Mr. Eustace. "We are profoundly sorry for this error and are determined to learn all the lessons we can from our mistake."