COOTEHALL, Ireland — In his twilight years, the writer John McGahern returned to the northern Irish countryside where he’d spent his boyhood to find it much as he’d left it: a land of blue lakes and green fields lined by hedges that erupted in wild color every summer.

McGahern, whose novels were celebrated for their elegiac depictions of rural Ireland, marveled in his 2005 memoir that Europe’s swift economic transformation had spared the landscape of his youth. “Amazingly, amid unrelenting change,” he wrote, “these fields have hardly changed at all since I ran and played and worked in them as a boy.”

If McGahern, who died a year later, could see some of those fields now, “he’d be spinning in his grave,” said geographer Rob Kitchin.

Across huge swaths of Ireland’s countryside, an astonishing housing bubble devoured acre after acre, transforming storied fields into charmless subdivisions reminiscent of American retirement communities.

Four years after the 2008 global crash, as many as 200,000 of those new homes are vacant, according to census figures. Property values have fallen to half their 2007 highs. The construction industry is at a standstill, and half of all mortgages are underwater. Irish banks still have on their books tens of thousands of mortgages for homes that can be neither sold nor rented.

The scenario would be familiar to American communities from California to Florida, where subdivisions built in the boom years lie largely empty, their houses, unsold or foreclosed on, now as much a hazard as an amenity. In the Irish countryside, the mind-boggling oversupply of homes is a stark reminder of how far Ireland has fallen — and how intractable Europe’s economic malaise may be.

In Cootehall, the scenic riverside village where McGahern grew up, there were fewer than 200 residents a few years ago. The surrounding area had seen a steady outflow of people for decades. Yet during the boom, developers built 83 new homes in this village alone — more than one-third of which remain unoccupied.

“Nobody gave any thought to who would actually live here,” said Maurice Gannon, 45, an information technology instructor and community activist in Cootehall. “It was pure greed.”

When asked to explain how this conservative island of 4.5 million devolved into a frenzy of real estate speculation — with farmers and lawyers and barkeepers flipping homes among one another like so many playing cards — the Irish often resort to drinking metaphors.

“We all partied and we’re now all having the hangover,” said Kitchin, a professor at the National University of Ireland in Maynooth. “We can blame the economists and the politicians and the developers, but we were all partying.”

Cash had never come as easily to Ireland as it did in the 1990s and early 2000s. After decades as an economic backwater, its entry into the European Union galvanized one of the most dramatic periods of industrialization of the last century.

Thanks to Ireland’s low corporate tax rate and its educated, English-speaking work force, foreign investors flocked to the island — 600 American companies set up offices here, including giants like Intel and Google — and helped bankroll the construction boom.

From 1991 through 2010, Ireland built 933,000 homes, nearly doubling its housing stock. (Even with Ireland’s growing population, that worked out to 1.5 new homes for every new household, according to government data.) Construction came to account for 14 percent of the economy as banks funneled most of their loans to real estate, and politicians instituted tax breaks to spur building in every corner of the country.

There were no tricky American-style financial instruments needed here — just cash, or the paper version of it, with both Irish and foreign banks falling over themselves to offer 115 percent loans and other easy credit to borrowers. The government raked in billions from capital gains taxes and transaction duties on every house sale.

Then the recession hit, the tax revenues dried up and bank balance sheets were eviscerated. A nation of fiscally risk-averse people who historically had low rates of borrowing suddenly found itself buried under mountains of debt.

“As a society, we never had money before,” said Elaine Byrne, a journalist and lecturer at Trinity College in Dublin. “The first opportunity we had with money, we went crazy.”

Michael Keane, a lawyer and farmer who took out a second mortgage on his home to chase the real estate fairy tale, bought 3 acres in Cootehall with a business partner in 2007 and made plans to build 32 houses. Within months, the bubble had burst.

Only eight houses were built and the Linden Wood development — a collection of cookie-cutter white stucco dwellings with black roofs — is in receivership. Recently, a three-bedroom house sold for about $100,000 — less than a third what it would have fetched in 2007, Keane said.

“We took a punt and it didn’t work out, and it’s cost me extremely dearly,” he said. “I won’t make it back if I live to a million.”

Across the road from his development is a triangular field that John McGahern described in his memoir as the center of the village when he was a boy.

“No two shops or houses adjoined one another,” he wrote, “and they were set down as haphazardly as if as if they had been carried there on various breezes.”

Atop the field today sits a tract of 42 pale yellow homes, each with identical wood trim and postage-stamp front yards, most of which are unoccupied.

“He would just be absolutely horrified at what has happened,” said Dymphna O’Regan, 77, a former classmate of McGahern’s who now runs one of the village’s two pubs. “To us it has made a huge difference. We were used to the beauty of the open big field here, and they’ve spoiled it.”

O’Regan wouldn’t say this, but the man who sold Keane the land for Linden Wood was her husband, Paddy. The sale price was about $1.25 million, and the O’Regans cashed out by building a large house on the outskirts of the village. Paddy, 80, now tools around Cootehall in a Mercedes.

“We gave him more money than he’ll ever be able to spend,” Keane said, “but I don’t begrudge him that. Money was cheap and everyone was trying to do something. Perhaps people got carried away. That’s just the way it was.”