The Obama administration warned federal agencies Wednesday that monitoring their employees’ personal e-mail communications could violate the law if the intent is to retaliate against whistleblowers.

A memo to chief information officers and general counsels across government from the Office of Management and Budget sets out guidelines from Special Counsel Carolyn N. Lerner that agencies should heed when they consider surveillance of employee communications.

The legal guidance — from the head of the independent office that represents whistleblowers— comes five months after The Washington Post reported that the Food and Drug Administration secretly monitored the personal e-mail of a group of scientists who warned Congress and others that the agency was approving medical devices they considered dangerous.

The FDA surveillance, detailed in e-mails and memos written by six medical-device reviewers, took place over two years as they accessed their personal Gmail accounts from government computers. The FDA took electronic snapshots of the employees’ computer desktops and reviewed documents they saved on their computers’ hard drives.

The scientists have filed a lawsuit against the FDA in U.S. District Court in Washington, alleging that the monitoring contributed to the harassment or dismissal of the six employees. They say the government violated their constitutional privacy rights by reading communications with Congress, journalists, the inspector general’s office and the Office of Special Counsel.

The FDA said the scientists had improperly disclosed confidential business information about the radiological devices, which detect breast cancer, diagnose osteoporosis, screen for colon cancer and monitor pregnant women in labor.

Two congressional committees are investigating the monitoring.

On Wednesday, the Obama administration stepped in, with a memo from chief information officer Steven VanRoekel and general counsel Boris Bershteyn informing agencies of Lerner’s warning.

“We strongly urge you to carefully review [the guidelines] when evaluating your agency’s monitoring policies and practices,” VanRoekel and Bershteyn wrote, “and to take appropriate steps to ensure that [they] do not interfere with or chill employees’ use of appropriate channels to disclose wrongdoing.”

FDA spokeswoman Erica Jefferson declined to comment on the memo.

Federal law prohibits retaliation against an employee who discloses wrongdoing, whether mismanagement, waste, abuse of authority or a danger to public health and safety. With some exceptions it also protects employees who expose wrongdoing to an inspector general or the special counsel’s office.

“In light of this legal framework, agency monitoring specifically designed to target protected disclosures to the OSC and IGs is highly problematic,” Lerner wrote. She warned that such “deliberate targeting,” or “deliberate monitoring” of communications between an employee and these agencies “could lead to a determination that the agency has retaliated against the employee,” as the FDA scientists allege.

A lawyer representing the scientists called the directive a “significant” step forward for whistleblower rights that puts a dent in the government’s practice of monitoring employees’ personal communications.

“This is the first time the federal government is acknowledging that there are limits to the surveillance of employees’ computers and e-mails,” said Stephen Kohn of the Washington law firm Kohn, Kohn & Colapinto. “It’s a significant first step.”

The memo does not directly address the government’s ability to monitor employees’ communications with Congress. Federal agencies are not allowed to “interfere” with such communications, but the law is murkier on whether they are protected by whistleblower laws.

It is unclear how widespread the practice of e-mail monitoring is.