Yachts and caravans have all served as home for Alan Dall but it is his tiny house in Canterbury that has finally claimed his heart and where he’s firmly put down roots after 25 years of transient living.

Measuring just eight metres long and three metres wide, Dall’s tiny home has become something of an inspiration for the movement, with his fight to retain its status potentially having lasting ramifications around the country.

Dall, originally from Scotland, has been engaged in a high-profile legal battle with government and the local council for three years, after the council classified his tiny house a building, making it subject to the same building codes and consents as standard homes.

Dall appealed to the ministry of business, innovation and finance (MBIE) but it backed the council’s decision that the “house” must comply with the building code or face being demolished.

Determined not to lose his first-ever permanent home, built with his own hands, Dall took his fight to the Christchurch district court at a cost of around NZ$10,000 and last week Judge Callaghan ruled in his favour. The ruling could set a precedent as dozens of other tiny home owners around the country are engaged in similar disputes.

“Don’t get me wrong, I would love to be able to buy a house but at 56 years old I think I’ve missed the boat on that,” Dall said.

“I’ve had so many emails from people saying ‘thank you, thank you, we feel a bit safer now’. I’ve also heard of some of the councils backing off, though others are still going hard at it.”

As the housing crisis deepens in New Zealand, owners of alternative, low-cost homes say an overhaul of regulations is urgently needed, as many people interested in downsizing and lowering their carbon footprint have been “scared off” by legal battles.

Others, for whom tiny houses are their only affordable option, are experiencing stress and anxiety at the prospect of losing their home.

“The mental and physical stress has been huge,” Dall said. “It’s really taken a toll”

Alan Dall’s kitchen Photograph: Alan Dall

According to a recent Demographia International survey, New Zealand has one of the most unaffordable housing markets in the world. Over the past decade homelessness – defined in the country as “having no other options to acquire safe and secure housing” – has increased to more than 40,000 or one in 100 New Zealanders. Working families are also now feeling the bite, with some forced to sleep in cars, tents and shipping containers despite being in full-time employment.

The Green party MP Gareth Hughes said the rate of council evictions from tiny houses was rising as they increased in popularity, and evicting anyone in the midst of a housing crisis made no sense.

Hughes has visited Dall’s tiny house and said his court victory was “significant” clarifying the situation for others.

“It has increasingly become an issue of concern. Tiny homes are a grey area and I think that’s the problem, they’re stuck between transport and building standards codes,” Hughes said.

“We need stand-alone tiny house rules, particularly for relocatable buildings. We also need to modernise our land use rules, people are wanting more flexibility, and we should be open towards that in the middle of a housing crisis.”

“In a housing crisis it doesn’t make sense to be threatening people with eviction notices and potentially put them on to the street or into cars.”

There are no clear figures on how many tiny homes exist in New Zealand as many people keep them under the radar – for fear of persecution, or because the landowners hosting them might be slapped with fines in the tens of thousands of dollars.

Colin Wightman, who builds tiny houses for Eco Cottages, said New Zealand had its “head in the sand” about alternative housing. “While the government pretends they want to innovate for affordable housing, they are actually working against it and exacerbating the homeless problem themselves,” said Wightman, who plays an advocacy role for tiny house owners.

Wightman said the industry and owners wanted tiny homes to “have our own set of rules and regulations that maintain minimum standards”, similar to legislation enacted in the UK and the US where the tiny house movement is flourishing.

Tiny house owner Alan Dall protesting outside New Zealand parliament Photograph: Supplied/ Alan Dall

“I’m at the coalface of homelessness. I have people coming to me and crying on my shoulders,” said Wightman, adding that the popularity of the movement had stalled in New Zealand with many now “scared off”.

A recent visit by the UN special rapporteur on adequate housing, Leilani Farha, said that while the government was sincere in its efforts to tackle the housing crisis, it was lacking creativity and urgency. “I’ve seen and heard a lot of interesting and thoughtful policies, but I think what remains to be seen here is courageous acts, creative measures, and structural change,” Farha said. “In terms of innovation, I just didn’t get a feeling that really creative ideas were being explored. It’s a little bit same-old, same-old.”

For Dall the court case has taken a real strain and he is now looking forward to finally enjoying his home, without the looming threat of eviction.