WASHINGTON—Google Inc. told lawmakers it continues to allow other companies to scan and share data from Gmail accounts, responding to questions raised on Capitol Hill about privacy and potential misuse of the information contained in users’ emails.

In a letter to senators, a top Google official said the company allows app developers to scan Gmail accounts, even though Google itself stopped the practice for the purpose of ad targeting last year. The company also disclosed that app developers generally are free to share the data with others, as long as Google determines that their privacy policies adequately disclose potential uses.

“Developers may share data with third parties so long as they are transparent with the users about how they are using the data,” Susan Molinari, the company’s vice president for public policy and government affairs for the Americas, wrote in the letter. She added that the company, a unit of Alphabet Inc., makes sure the relevant privacy policy is “easily accessible to users to review before deciding whether to grant access.”

Using software tools provided by Gmail and other email services, outside app developers can access information about what products people buy, where they travel and which friends and colleagues they interact with the most. In some cases, employees at these app companies have read people’s actual emails in order to improve their software algorithms.

Google’s letter, received by lawmakers in July, came in response to written questions from several lawmakers, including Commerce Committee Chairman John Thune (R., S.D.), following a Wall Street Journal report detailing how app developers frequently gain access to the contents of users’ Gmail accounts.