The results topped Wall Street expectations, and the company raised its full-year guidance. Starbucks' shares were up almost 7 percent in aftermarket trading.
The Seattle-based chain, which has more than 19,000 locations around the world, said global sales rose 8 percent at cafes open at least 13 months, with all regions registering growth. In its flagship U.S. market, the figure rose 9 percent.
The performance is in contrast to McDonald's Corp., which reported an underwhelming 1 percent increase in U.S. locations open at least a year earlier this week. The fast-food chain had partly blamed economic conditions, saying people have been reluctant to eat out.
Troy Alstead, chief financial officer for the chain, said the results demonstrate people's loyalty to the Starbucks brand, despite factors such as bad weather or a weak economy cited by other companies for underwhelming results in the quarter.
"We have some resilience, some insulation," Alstead said.
"Starbucks today exists within a universe of one," CEO Howard Schultz emphasized n a call with analysts.
Starbucks has been making a number of changes to drive up sales. In April, it rolled out revamped sandwiches in new packaging that come with slightly higher prices; the new egg salad sandwich, for example, costs $5.25, up from $5.15 previously.
New salads and grain bowls were also introduced at about $7 per box.
Moving forward, the company has been testing new baked goods - acknowledging that its baked goods don't have a great reputation. It also announced that it's teaming up with Danone to offer new, branded Greek yogurt parfaits that are set to start replacing its current offerings in cafes by next year.
It's also pushing aggressively to enroll people in its loyalty program, offering incentives such as a $5 load on cards for people who sign up. The benefits are twofold; Alstead said people tend to visit more often and spend more once they enroll.
In the meantime, Starbucks is also benefiting greatly from lower coffee costs, which are expected to continue for at least another year and half. Despite its lower costs, the company last month instituted price hikes in the U.S., a move which should help widen its operating margins even further.
Starbucks said sales rose 9 percent in China and the greater Asia region for the quarter. It also managed to increase sales by 2 percent at established cafes in Europe, where the company has been struggling. The company has been closing underperforming stores and licensing out operations in other regions.
Looking ahead, it cautioned that sales at established locations would ease back into the 5 percent to 7 percent range it saw in the first half of the year.
Starbucks Corp. earned $417.8 million, or 55 cents per share, for the period ended June 30. That's up from $333.1 million, or 43 cents per share, a year ago.
Analysts on average expected 53 cents per share.
Revenue rose to $3.74 billion, more than the $3.72 billion analysts had forecast.
It now expects earnings per share in the range of $2.22 to $2.23, up from $2.12 to $2.18.
Its shares rose to $72.30, after closing up 2 percent at $68.17. Its stock is up 34 percent over the past year.