T-Mobile is warning of a security breach that may have exposed the data of millions of customers.

The hack, which occurred Monday, may have compromised information including names, zip codes, phone numbers, email address, account numbers and account types, the nation's third-largest wireless provider said in a statement.

The company's security team shut down the intrusion, and financial information such as credit card and Social Security numbers was not exposed.

Get Breaking News Delivered to Your Inbox

Affected customers have either been notified or would be shortly, T-Mobile stated.

A spokesperson confirmed in an email that the breach affected about 3 percent of T-Mobile's 77 million customers, or 2 million people.

The security incident is only the latest at T-Mobile. In May, researchers detected a bug in the company's website that allowed anyone to access the personal data of customers with just a phone number.

The company is waiting for regulatory approval of a proposed $26.5 billion takeover of Sprint, the fourth-largest carrier in the U.S.