Few place names are as burdened with history as Soweto. Nelson Mandela once called it home. The infamous center of resistance to apartheid — South Africa’s entrenched system of white supremacy — the township was a symbol of poverty and oppression on the one hand and heroism and sacrifice on the other. Fittingly, it gave its name to a 1976 uprising of young activists that forever changed the country’s political landscape.

Today, 18 years after Mr. Mandela became South Africa’s first democratically elected president, the sprawling township’s cultural dynamism and growing prosperity have transformed it into a symbol of hope rather than despair. Home to more than two million people, it rivals nearby Johannesburg in size and is the perfect spot to document the surprises and contradictions of South Africa’s transformation. Poverty has not disappeared, but it no longer defines the area, according to Per-Anders Pettersson, a Swedish photographer who has long documented the township.

“Soweto fascinates me,” he said. “It’s one of the must-see places in South Africa, a microcosm of the new South Africa.”

It was this emerging Soweto that captured Mr.Pettersson’s imagination the moment he first encountered it in 1994. Mr. Pettersson, who was based in New York at the time, had gone to South Africa to cover the elections that marked the end of apartheid. Although he was in the country for only a month, the experience affected him deeply. “South Africa just drew me back,” he said. “I lost interest in other stories, in other things that were happening.”

He relocated there in 2000 and now supports himself through photojournalism and commercial assignments, especially in Africa. His personal work, however, documents how democracy and development are changing South Africa. The country is his passion. “I found something that became my project,” he said. “Something that I really loved.”

For Mr. Pettersson, Soweto is much more than a subject. Having worked in the township for nearly two decades, he says, many of its residents have become friends. “It’s actually my favorite place in South Africa,” he said, “and sometimes I would say, the safest and the most fun.”

Soweto’s energy and creativity are as evident in Mr. Pettersson’s photographs as its many quandaries. He describes the photos as taking viewers on “a journey from the old into the new.” In almost all of the photos, the frames are packed with motion and color. In some, businessmen sip brandy in a upscale bar (Slide 4), children golf on manicured greens (Slide 9) and beauty pageant contestants strut across a stage (Slide 13). In others, street vendors sell their wares in a desolate urban landscape (Slide 15) and young women participate in a traditional Zulu rite of passage.

While Mr. Pettersson plans to publish a book of his Soweto photographs, he knows he still has a long road ahead of him. “I’ve shot quite a lot in the last few months, and I’m about 50 percent there,” he said. “If I can spend a couple of months full time, that would be really good. I’ll get a long way to the end.”

Like many photojournalists, Mr. Pettersson has turned to emphas.is, a crowd-funding Web site that connects photographers with donors to raise the money he needs to allow him to settle in Soweto and finish the project. Those who pledge support can get in return anything from prints from the series to workshops with the photographer. Crowd-funding is no panacea, however; Mr. Pettersson is still some distance from his goal.

But he remains close to his motivation. Soweto has been attracting photographers for more than 50 years. The best of them have taught audiences something new and have shown them things they never expected.

“In Soweto you can see changing very fast — fancy shopping malls and car dealerships and festivals,” he said. “They even have a Fashion Week now.”

John Edwin Mason teaches African history and the history of photography at the University of Virginia. A photographer in his own right, he divides his time between Charlottesville, Va., and Cape Town. He is on Twitter — @johnedwinmason — and so is @nytimesphoto.

