Miami’s Wynwood neighborhood epitomizes hip. A neglected industrial enclave that sat mostly empty just a few years ago, Wynwood today thrums with energy. Its low-slung warehouses and onetime auto garages are filled with buzz-worthy eateries, high-end tattoo studios, vegan juice bars and edgy art spaces. At Wood Tavern, twentysomethings gather around graffiti-covered picnic tables to sip La Rubia blonde ale, brewed just a couple of blocks away at the Wynwood Brewing Company. At nearby Wynwood Kitchen and Bar, diners eat Latin-tinged cuisine under wall-sized paintings by popular street artists. A block down, the line at Panther Coffee can stretch out the door. Throughout the neighborhood, at all hours of the day, people stop to snap selfies in front of the colorful new murals that cover seemingly every inch of every building in Wynwood.

It’s the kind of dynamic urban scene that cities dream about. And it would never have happened, Miami planners say -- or at least not to the same degree of success -- without the city’s new zoning code known as Miami 21. “I cannot imagine it,” says Francisco Garcia, the city’s planning director, shaking his head at the thought. “I just can’t even imagine.”

Miami 21 isn’t actually brand-new: It’s been on the books since 2010. But it was the first true overhaul of the city’s code in nearly 80 years, and it points toward major change in the way Miami will grow for generations to come. The controversial code has altered every aspect of the city’s development, from the way a builder interacts with the planning department to the size of the windows of a finished storefront. And it touches every part of the city, from the shimmering urban high-rises of downtown Brickell to the single-family homes in historic, tree-lined residential neighborhoods like Little Havana and The Roads.

Public zoning codes are typically filled with mind-numbingly dry details of frontages, setbacks and floor-area ratios -- and Miami’s is too. But these codes ultimately determine the way a city looks and feels and functions. They’re the 1s and 0s that build the matrix. Miami 21 may be abstruse, but it’s also a new vision for what the city wants to be.

Miami 21 is what’s known as a form-based code. Rather than prescribing development based on how a plot of land will be used -- residential, say, or mixed-use commercial -- the code defines the physical shape development should take in different parts of the city. That means buildings are considered in context with what’s around them, regardless of what goes on inside. The goal is a more walkable, more human-scale form of development. When Miami adopted the code in 2010, it was the first big U.S. city to implement a form-based code citywide. Six years later, it’s still the only one.

Most of the impact of Miami 21 isn’t as tangible or as concentrated as in Wynwood. But its effects are suffused in properties throughout the city. On a recent sunny Friday, as Assistant Planning Director Luciana Gonzalez drove around town with a couple of visitors, she couldn’t help interrupting herself every so often to point out the role of the new code. “That’s Miami 21,” she says, as she drives past a new bank branch building set close to the street, with parking hidden behind it. “That’s Miami 21,” she says again, pointing out a multistory self-storage facility that looks more like a sleek office tower, with inviting plate-glass windows along the sidewalk and a soon-to-open high-end rooftop restaurant that will take advantage of the views of the Miami River. A little later, Gonzalez passes an under-construction residential high-rise that’s wrapped in street-level retail spaces. “That’s Miami 21, too.”

Miami’s form-based code has been lauded by the international planning community as a progressive commitment to New Urbanist ideals. But getting to this point involved years of convincing skeptical developers, architects, neighborhood organizers and political leaders that this change was the right thing for the city. And the code still has plenty of critics, including, perhaps surprisingly, Tomás Regalado, the city’s current mayor. He acknowledges that Miami 21 “looks good on paper,” but says it’s proven difficult to implement on the ground. When asked whether the new code is an improvement over the way things used to be, Regalado pauses, holds up a finger and says, “Maybe.”

The Catalonia apartment building, which sits in a neighborhood of small single-family homes, is emblematic of the unregulated growth that took place before Miami 21.

There’s nothing all that remarkable about the Catalonia apartment building on SW 27th Ave. A bland 13-story building finished in two tones of beige, it’s the kind of faceless, nondescript mid-rise you drive past without giving it much thought. But one thing makes the Catalonia, which was completed in 2007, stand out. It sits smack next door to a small single-family home, a modest one-story house with a red tile roof and a patio out front. And that’s made the Catalonia emblematic of the kind of unregulated growth Miami planners hope never to see again.

The former zoning code was adopted in 1936, and for many decades it seemed to serve the city just fine. Higher-density buildings -- and some skyscrapers -- were concentrated downtown and along Biscayne Bay, while residential neighborhoods were left mostly untouched. But the code became increasingly complicated as a succession of city leaders tacked on modifications and revisions and exceptions. As in most U.S. cities, Miami’s old code was based on separation of uses. But the number of “uses” eventually exceeded 360 and didn’t seem to make sense: A barbershop was considered a different use than a beauty salon.

Then came the 1990s population boom, and things really went haywire. Miami and surrounding Dade County grew by more than 18 percent in the 1990s, a growth trend that would continue into the 2000s and 2010s. Much of the influx was driven by immigrants from Latin America. By 2002, Miami-Dade had a higher percentage of foreign-born residents, 51.4 percent, than any other county in the country. The city went on a building binge. Height allowance was determined solely by the size of a lot, so if developers could simply cobble together enough plots of land, they could build 15- or 25- or 40-story buildings anywhere they wanted, even right next to a leafy neighborhood of small homes. High-rises sprouted like weeds overnight. One building might be 10 feet from the sidewalk, while the one next door was set back 30 feet. Blank walls stretched along sidewalks for entire blocks.

It was haphazard and random growth, “and it was all perfectly legal,” says Ana Gelabert-Sanchez, who was the city planning director at the time. “It was all done by the book, within the code at the time. But it didn’t result in a city that was nice to live in.”

Manny Diaz was elected mayor in November 2001, and he sensed that Miami’s development had gotten off track, even if he couldn’t articulate it. “I wasn’t trained in urban planning or design, but instinctively I knew something was wrong, because I just looked around,” he says. “I saw pretty buildings that had no connection to the street, no connection to the buildings around them. I knew something had to be done, but I didn’t know what that meant.”

Diaz turned to Gelabert-Sanchez and to Elizabeth Plater-Zyberk, the renowned Miami-based architect who, along with her husband, Andrés Duany, has become an international leader in New Urbanist design. “The old code,” says Plater-Zyberk, “was completely unpredictable.” It had resulted in a “totally incoherent” city.

Miami architect Elizabeth Plater-Zyberk: “The old code was completely unpredictable.” It had resulted in a “totally incoherent” city.

Plater-Zyberk and the city planning team got to work on a code that would help guide the form of new buildings, rather than just prescribe how a specific property would be put to use. It would emphasize street-level activity and public spaces to encourage walking, and it would bring a sense of order to Miami’s explosive new growth.

Other cities had already implemented partial form-based codes in certain areas, such as a downtown core or a tourist district. In most places, the new code existed in parallel to a traditional use-based code. Cities would incentivize developers by, say, offering faster permitting for those choosing to abide by the form-based code, but it wasn’t mandatory. The planners in Miami began drafting something similar, a code that could be used to augment planning in certain hot spots around town.

Diaz had a different idea: Scrap the old code completely and start over from scratch. If a form-based code was good for certain parts of the city, he felt, then it would be good for the city as a whole. “It just made sense,” he says. “Let’s just do it all at once. I know it’s crazy, but let’s just do it now.”

The plan was hit by opposition almost immediately. “There was a lot of concern, reluctance -- fear, even -- at the very beginning,” says Garcia, Miami’s planning director, who at the time was working in the private sector, on Plater-Zyberk’s team.

“Some people in the design community were worried that everything would end up looking the same,” says Gelabert-Sanchez. “Or they were worried that we in the city were going to say, ‘I don’t like those windows. I don’t like that arch.’ But we just wanted to establish principles. We don’t care about the style.”

Since the Great Recession, Miami has seen a building boom coinciding with the implementation of its new zoning code.

Over a period of six years starting in 2003, the city held 60 formal public hearings on the new code, in addition to another 500 meetings with residents and other stakeholders -- ranging from events with hundreds of attendees in large downtown convention halls to intimate sit-downs in residents’ living rooms. Many of the meetings were in Spanish. “We knew we’d have skeptics,” says Diaz. “So we wanted the process to be as transparent and as inclusive as possible. One thing no one can say is that this was some backroom deal between the city and developers, or land use attorneys.”

As the city coalesced around a plan, developers got on board. Because the new code provided much more predictability in terms of what was allowed on a given plot, the approval process need no longer involve acrimonious public hearings and contentious fights with the city over building plans. Everything would be spelled out in the code itself. And neighborhood conservationists appreciated that a new plan could better preserve the character of Miami’s distinct communities.

Still, there were critics. Property owners said the new code would devalue their land by limiting the amount of future development they could undertake. Builders said the code would throw all the city’s existing structures into legal limbo because they wouldn’t conform with the new regulations. And some of the preservationists and neighborhood groups that had initially supported the idea began to complain that the new code didn’t go far enough in protecting Miami neighborhoods; they waged fights with the city to “downzone” residential areas even further.

On Oct. 22, 2009, after an embarrassing initial rejection, Miami 21 was approved during Diaz’s very last meeting as mayor. The new code was law. But that didn’t end the opposition. The lone city council vote against the final code had been cast by Regalado, who 12 days later was elected mayor. Many people expected he might dismantle Miami 21 as soon as he took office. Indeed, some in the community hoped he would. Today, Regalado says he never even considered doing that. But at the time, advocates were worried. “Two or three [city commissioners] -- and in particular Mayor Regalado -- were set to take it apart,” says one person who was tracking the issue closely.

Then came the Great Recession. Ironically, it may have been the best thing that could have happened to Miami 21. Development in South Florida ground to a halt, and city leaders were overwhelmed by other concerns. Suddenly, debate over a zoning code was no longer a front-burner issue.

Gonzalez in the city planning office agrees. “It was good timing, actually, because then when the economy did come back, we were ready to receive the development. And ever since the beginning of 2013, it’s been, like, boom!”

Assistant Planning Director Luciana Gonzalez says the new code offers greater predictability for builders while also ensuring Miami’s neighborhoods retain their unique character.

It can be hard to appreciate the staggering rate of change Miami has seen in the past decade. From 2000 to 2014, the city’s downtown doubled in residential population, and almost half the residents who live there now are between 25 and 44 years old. In the past decade alone, the city has added 113 new high-rises. Some of that development happened prior to Miami 21, which officially became law in May 2010. But most of it has happened since.

For many in the city, the jury is still out. Regalado complains that with so many details spelled out in the code itself, or hammered out between developers and city planners, less of the process is subject to public input. “In the old code, every minor zoning change had to be done by public hearing,” he says. “Miami 21 [offers] less transparency.”

Garcia says that’s not the case. “Under the old code,” he says, “the public hearings were much more acrimonious than they have been under Miami 21. Now we get out there and engage with the stakeholders.” By the time a public hearing does occur, he says, everything has already been worked out.

Francisco Garcia, the city’s planning director, says that public hearings used to be much more acrimonious than they have been under Miami 21.

Aside from dissatisfaction with the process, there are still some people who think the new code is a substantively bad deal. A few lawsuits have been filed by landowners -- including the Catholic Archdiocese of Miami, which sued the city for $89 million in 2013 -- who say the new code has devalued their property. None of the suits has gone anywhere. Others have accused the city of applying the code inconsistently, letting certain projects skirt the regulations: A proposed Walmart in Midtown became a particular lightning rod for controversy, as urban big-box stores often are. But the city says the store has been designed to comply with Miami 21; ground was broken on the project in January.

For the most part, Miamians seem to be living with the new code. Architects and developers appreciate the predictability of it; city planners like the way it’s shaping new growth. In fact, nearly everyone seems to agree that it’s working extremely well downtown. But it becomes more problematic when applied to smaller neighborhoods. “Miami 21 is great in the areas of town that are already designated as high-density, high-intensity development,” says Ines Marrero-Priegues, a local land use attorney. The process for upzoning to add new denser projects in other parts of the city, however, is “very lengthy. It’s easy to get projects approved in the urban core, but it can be very onerous for people who are doing smaller projects where there’s less density already.”

There’s one thing you won’t find mentioned anywhere in the pages of Miami 21: climate change. According to some of the latest projections of sea-level rise, large parts of Miami could be underwater in as little as 85 years, which can make Miami 21’s intense focus on walkability and livability seem a bit ironic. It’s not quite like rearranging the deck chairs on the Titanic, but some fear it might be close. “I think we’re behind the curve,” says Regalado. “Sea-level rise is something no one wants to talk about because the condos are selling very well; Latin American people are buying condos by the dozen. It’s going to be painful, but we do need to create a code that takes sea-level rise into account.”

Regalado says he wants to add a climate change component to Miami 21 before he leaves office in November 2017. That’s something that Garcia would love to see as well. The climate change conversation, he says, has typically been dominated by architects, not planners, and has focused on making single buildings climate-resilient. “What I think is being left out of the conversation,” he says, “is neighborhood resiliency, as opposed to building resiliency.”

Mayor Tomás Regalado acknowledges that Miami 21 “looks good on paper,” but says it’s proven difficult to implement on the ground.

The full impact of Miami 21 won’t be felt for decades. But simply getting to this point has been a remarkable event. “Those seven years we spent developing the code,” Garcia says, “were seven years of getting a better understanding of what the concerns of the citizens were, and engaging the citizens to wrestle with planning and zoning issues. The knowledge base improved significantly, so now we can have much more advanced, sophisticated conversations with stakeholders. The profile of planning as a whole has been elevated.”

Walking around Wynwood, or popping into a sidewalk coffee shop in a new skyscraper downtown, most people aren’t thinking about the building code. They just know that Miami is becoming a nicer place to live. But the city as a whole has indeed come to appreciate the role zoning plays in creating a better built environment. Former mayor Diaz says that’s something he learned as well. “You don’t run for office on urban planning. You run because you say, I’m going to fight poverty, or fight crime, or improve education. But I realized that planning is the most important issue. We fight crime, and it goes down, and that’s good. But in a few years, it might go up again. You move the needle as best you can, but these are constantly changing issues.” But a new building, he says, will impact residents for generations. “When you put up a building, it’s there for a hundred years.”