The U.S. Justice Department has opened a criminal investigation into whether top officials at Equifax Inc. violated insider trading laws when they sold stock before the company disclosed that it had been hacked, according to people familiar with the investigation.

Equifax disclosed earlier this month that it discovered a security breach on July 29. The three executives sold shares worth almost $1.8 million in early August. The company has said the managers didn’t know of the breach at the time they sold the shares.

More than one third of U.S. senators have called on the Securities and Exchange Commission, in addition to the Justice Department, to get to the bottom of whether Equifax managers violated insider trading laws when they sold stock days after the company found out it was hacked.

Separately, state and federal regulators and law enforcers are scrutinizing the company’s data security practices and its response to the breach. The U.S. Federal Trade Commission and a Congressional committee with subpoena power last week joined the growing number of bodies scrutinizing the cyber attack.

The U.S. Justice Department has opened a criminal investigation into whether top officials at Equifax Inc. violated insider trading laws when they sold stock before the company disclosed that it had been hacked, according to people familiar with the...