Regular trading hours are 9:30 a.m. to 4 p.m. ET, but the major U.S. stock exchanges close early on certain days ahead of or just after market holidays.
A stock market exchange is, by definition, a marketplace where stocks can be bought and sold for certain hours throughout the day.
It functions as an entity that ensures orderly trading and efficient dissemination of price quotes for the companies that list on the exchange.