Both the S&P 500 and Nasdaq secured fresh closing highs on Tuesday on the back of bullish consumer confidence and housing data.

Here's how the market settled on Tuesday:

S&P 500 Index (SPY  ): +0.03% or +1.19 points to 4,291.80

Dow Jones Industrial Average (DIA  ): +0.03% or +9.02 points to 34,292.29

Nasdaq Composite Index (QQQ  ): +0.19% or +27.83 points to 14,528.34

United announces largest-ever aircraft order:

United Airlines (UAL  ) announced Tuesday its largest-ever aircraft order as the commercial airline looks to recover from the coronavirus pandemic and recoup some losses from depressed travel volumes: 270 Max 10 and A321neo jetliners from Boeing (BA  ) and Airbus (EADSY  ), respectively.

Chief Commercial Officer Andrea Nocella told CNBC that the fleet plan is central to United's goal of capturing more travelers, especially high-paying passengers from major coastal hubs like San Francisco and Newark. The two models are the largest in their families and the company plans to use them to help alleviate capacity constraints and grow in these markets.

Consumer confidence jumps for a fifth straight month in June:

Consumer confidence soared to the highest level in more than a year in June, rising for a fifth straight month as the United States continues to reopen following extended coronavirus pandemic-related restrictions.

The Conference Board's monthly consumer confidence index jumped to 127.3 in June from 120.0 in May, which was upwardly revised from the 117.2 previously reported.

"Consumers' short-term optimum rebounded, buoyed by expectations that business condition and their own financial prospects will continue improving in the months ahead," said Lynn Franco, senior director of economic indicators at the Conference board, in a press statement. "While short-term inflation expectations increased, this had little impact on consumers' confidence or purchasing intention. In fact, the proportion of consumers planning to purchase homes, automobiles, and major appliances all rose--a sign that consumer spending will continue to support economic growth in the short-term. Vaccination intention also rose, reflecting a continued increase in spending on services."

Walmart to offer less expensive insulin:

Walmart (WMT  ) announced Tuesday that it will offer a less expensive insulin that could better benefit millions of Americans who either don't have health insurance or struggle to pay for the high-cost diabetes drug developed by other pharmaceuticals like Sanofi (SNY  ) and Eli Lilly (LLY  ).

Starting this week, the Dow-component retailer will sell its exclusive private-label version of analog insulin, ReliOn NovoLog, to adults and children with a prescription. The drug will also be available at Walmart's membership-based Sam's Club in July. The insulin will cost about $73 per vial or roughly $86 for a package of prefilled insulin pens.

Here's how benchmarks stood after opening bell:

S&P 500 Index: +0.17% or +7.16 points to 4,297.77

Dow Jones Industrial Average: +0.50% or +170.61 points to 34,459.85

Nasdaq Composite Index: -0.08% or -9.41 points to 14,485.01

Home prices rose at the fastest pace in more than 30 years in April:

Home prices surged in April, with tight inventory levels and high demand pushing prices up, which ultimately weighs on affordability.

The S&P CoreLogic Case-Shiller national home price index rose by 14.6% in April over last year, accelerating from March's 13.3% rise, marking an 11th consecutive month of climbing home prices and the highest reading in over 30 years.

The firm's 20-city composite index, which tracks home prices increases across 20 major metropolitan areas, jumped by 14.9% in April over last year, up from the 13.4% increase recorded for March.