On a warm morning last August, three conservationists set out for a walk in the woods in Queens. The conservationists—Sarah Charlop-Powers, Jennifer Greenfeld, and Kristie King—work for the Parks Department and the Natural Areas Conservancy. Shod in hiking shoes and carrying reusable water bottles, they crossed a series of playing fields near the entrance to Alley Pond Park, where children in matching T-shirts were spidering about on a ropes course. Following a wide mulched path, the conservationists stepped into the forest. The atmosphere changed abruptly: the familiar clamor of an American summer morning—cars whooshing, kids chirping—fell away; the air became cool, dark, faintly damp; the sky overhead was embroidered with bright threads of birdsong. All these are signs of a healthy forest. The conservationists’ job was to somehow keep it that way, while also persuading more people to visit it. King, the department’s director of forest restoration, stopped to inspect a map of the park’s trail network—a loose tangle of Crayola-hued lines representing the six official paths, and a ghostly network of dotted white lines signifying the informal paths, called desire lines.

Desire lines, also known as cow paths, pirate paths, social trails, kemonomichi (beast trails), chemins de l’âne (donkey paths), and Olifantenpad (elephant trails), can be found all over the city and all over the world, scarring pristine lawns and worming through forest undergrowth. They appear anywhere people want to walk, where no formal paths have been provided. (Sometimes they even appear despite the existence of formal paths, out of what seems to be sheer mulishness—or, perhaps, cowishness.) Some view them as evidence of pedestrians’ inability or unwillingness to do what they’re told; in the words of one academic journal, they “record collective disobedience.” Others believe that they reveal the inherent flaws in a city’s design—the places where paths ought to have been built, rather than where they were built. For this reason, desire lines infuriate some landscape architects and enrapture others. They also fascinate scholars, inspire artists, and enchant poets. There is a fifty-five-thousand-member-strong Reddit thread dedicated to them, in which new posts appear daily with impassioned titles like “Desire never ends” and “Don’t tell me where to go.” People seem to relish discovering odd new desire lines, the more illogical the better, and theorizing about what desire they express.

For members of the Parks Department, desire lines pose a riddle. “The desire lines, while they’re expressive of people’s interest in being in the woods, they also damage the ecology,” Greenfeld, the assistant commissioner for forestry, horticulture, and natural resources, told me. As a result, whenever it is worth the effort, the city tries to close them down. After a few more minutes of walking through the oaks and tulip poplars, the conservationists ran across one such defunct trail. It led down to a small pond, where local residents like to regard the turtles. In front of the trail was a black steel fence and a laminated sign reading, “Please do not disturb the restoration area.”

This is the authoritarian approach to erasing a desire line: block it off with some type of obstacle—a fence, a bush, a pile of brush, a sharply (if, in this case, politely) worded sign. Builders of hiking trails often install menacing rocks, called gargoyles, to discourage hikers from straying from the path. One trail-builder on Reddit even admitted to obstructing unwanted paths with heaps of poison oak. But, to designers’ dismay, walkers often trample these obstacles and continue following their original route; bushes are stomped down, fences broken apart. Other times, an obstruction will simply give birth to a new trail leading to the same location. Indeed, perhaps a hundred metres away from the fenced-off trail, King spotted a new desire line leading down to the pond’s edge. “People want to go down to the pond,” she said with a shrug. “Maybe this opened up because we closed that other access.”

The more democratic approach to managing desire lines is to listen to and learn from them. Many college campuses, eager to signify that they have shed the authoritarian educational approach that predominated before the campus uprisings of the late nineteen-sixties, lay claim to a common creation myth: once, their quad was riddled with desire lines, so they tore up all the paths, resodded the lawn (or, in some variants, waited for a snowfall), allowed the students to make their own trails, and then paved those. This philosophy has become instructive for designers in varying fields, especially in the tech industry. The approach can be loosely traced back to the design theorist Christopher Alexander, who argued that paths and other design elements should “emerge gradually and organically, almost of their own accord.”

But blindly formalizing the whims of the crowd can have its own pitfalls. Until the nineteen-eighties, for example, it was common practice to pave the desire lines in Central Park. But, as Elizabeth Barlow Rogers notes in her 1985 book “Rebuilding Central Park,” in high-use areas, this can lead to a manic accumulation of concrete. “Since many of these foot trails have been ‘legitimized’ with pavement, the Park landscape has become more and more chopped up and webbed with asphalt,” Rogers writes. The Conservancy ultimately resorted to paving some desire lines but blocking others. The results have been largely successful, though eruptions of civil disobedience still occur.

In 2013, the Parks Department took a novel step toward solving the riddle of desire lines. The city, in partnership with the Natural Areas Conservancy, commissioned a digital map of all the trails in New York’s wild areas. The map was originally intended to help Parks employees spatially situate themselves beneath the otherwise featureless tree canopy. But they quickly realized that such a map would also provide a better view of which trails they should formalize and which they should block. That autumn, a young Parks employee named Hayley Small walked some two hundred miles with a G.P.S. unit in hand, mapping the trails and noting their conditions, such as incline and surface quality. Two volunteers later helped complete the on-the-ground survey.

The result of their work is a remarkable document, a comprehensive map of the city’s desires. Charlop-Powers, who once built hiking trails in the Catskills, has noticed that desire lines usually form because hikers want to see something, like a waterfall, that the trail doesn’t lead to. But New York City, she said, “is a different kettle of fish.” In Alley Pond Park, a desire line had formed to reach a clearing where teen-agers liked to drink. In Marine Park, in Brooklyn, residents had created new trails by (illegally) racing their A.T.V.s across the sandy dunes. And in Bronx River Park, still a popular cruising spot for gay and bisexual men, a wild tangle of paths had sprung up. “Desire takes many forms,” Greenfeld said, laughing.

The conservationists spent the rest of the morning wandering through the forest, double-checking to make sure the map lined up with the current trail conditions (a process called ground-truthing). The formalized paths had been marked with brightly colored plastic medallions nailed to nearby tree trunks, which, King noted with dismay, pedestrians like to pilfer as mementos.

On the far side of the forest, the conservationists encountered a patch of wineberries, a cousin of the raspberry, which glistened red like wet hard candy. They began plucking the berries and popping them into their mouths.

“They’re just so good right now!” Greenfeld said.

“And by eating them, we’re fighting an invasive,” King said. (The genus was introduced to North America from East Asia in the eighteen-nineties.)

“I mean, this is technically a restoration activity,” Charlop-Powers joked. Straying farther from the trail to access a particularly plump cluster, she called out behind her, “I’m going to create a desire line now!”

*This article has been updated to correct the name of the borough in which the conservationists were walking.