Apple increases US smartphone share ahead of anticipated iPhone 6 launch

People looking at iPhones at an Apple store.
Getty Images
People looking at iPhones at an Apple store.

Apple increased its lead in the U.S. smartphone market as it prepares to unveil its next-generation iPhone, according to the latest data from measurement firm comScore.

The iPhone ranked as the top smartphone in the U.S., with a 42.4 percent share of the market for the three months ending in July. That's up from roughly the same period a year ago when iPhones accounted for 40.7 percent of all smartphones in the U.S.

Rival Samsung Electronics ranked second with 28.4 percent (up 0.7 percentage points from the April quarter), followed by LG's 6.4 percent, Motorola's 5.7 percent and HTC's 4.7 percent, according to comScore.

More from Re/code:
Twitter media boss Katie Jacobs Stanton wants more partners in more countries
LA's tech startup scene is coming of age
Seven ways to extend your smartphone's battery life

Some 173 million Americans now own smartphones, or about 71.8 percent of all mobile phones. These nearly ubiquitous devices have become a digital staple, especially with young consumers aged 18 to 34.

The latest research from Nielsen shows that this group is especially likely to own such a device, with about 85 percent of those aged 18 to 24 and 86 percent of 24- to 34-year-olds owning a smartphone.

Despite Apple's marketshare, Google's Android was once again the top mobile operating system, with over half of U.S. smartphones, or 52 percent, running the software, according to both comScore and Nielsen.

Read MoreWhat's (most likely) coming from Apple next week

By Dawn Chmielewski, Re/

CNBC's parent NBCUniversal is an investor in Re/code's parent Revere Digital, and the companies have a content-sharing arrangement.