Arizona has more homeless veterans than most other states — roughly one in five homeless adults, according to statistics from the state’s Department of Veterans’ Services. In an interview, Greg Stanton, the mayor of Phoenix and a longtime proponent of increasing investment and partnerships on homeless outreach, characterized the recent achievement as “important because we’re helping people in need, but also important because it helps our economy.”

According to local and national surveys, it is more expensive to cover the costs of emergency room visits or nights in jail for homeless people than it is to give them homes. A 2009 analysis commissioned by the Los Angeles Homeless Services Authority, which handles the largest population of homeless veterans in the country, found that the monthly cost of housing and supportive services for one person was $605, while the public costs of a person living on the streets were roughly $2,900 a month.

Across the country, the strategy is centered on an approach called Housing First, through which a home is not treated as a reward for good behavior. As Ms. Zeilinger put it, it is instead “the platform of stability that lets previously homeless people work on the other issues they’re facing,” like mental illness and addiction, which are particularly common among the chronically homeless. The term is defined as those who have continuously lived on the streets for a year or have done so at least four times over three years.

Some advocates say the concept works more easily in places like Phoenix, where there is room to build. Victory Place, the 104-apartment complex where Mr. Mackenstadt and Mr. Hankins live, opened last year on the city’s south side. (An additional 96 units are under construction on the same campus.) Meanwhile, in cities like Los Angeles, building is expensive and competition is stiff for existing affordable-housing units, which are already scarce, said Steve Peck, president and chief executive of U.S. Vets, the nation’s largest nonprofit service provider for veterans.

There is also the challenge of sustaining the investment, given the steady stream of soldiers back from Iraq and Afghanistan who have been ending up on the streets.

“The question,” said Mr. Peck, who served in the Marine Corps in Vietnam, “is how we create enough housing units to house those who are homeless and where we find the money to provide all the services that are essential to keep them in those units.”

Through a joint program that is the backbone of the federal effort, the Departments of Housing and Urban Development and Veterans Affairs have given $913 million since 2010 in vouchers, as well as clinical and social services, to chronically homeless veterans in or near the communities where they live. (The veterans contribute 30 percent of their gross income toward housing.)