MSPs have backed a proposal that a safe warm home should be available to everyone and measures to reduce the dependence on temporary accommodation like bed and breakfasts.

In a unanimous vote, all parties in the Scottish Parliament backed the motion and a call by the Conservatives that there should be a limit of seven days on people in “unsuitable temporary accommodation”.

The Tories said that the next Programme for Government should include imposing a time limit of one week.

Kevin Stewart, Housing Minister, said the government would consult on the issue early in 2019.

He said: “We recognise that work needs to be done here. We will consult on all of this at a very early stage next year and bring forward legislation in due course to tackle this.”

A labour amendment calling for recognition of the complex reasons behind homelessness and for gender specific reasons for homelessness to be taken into account was also accepted.

The Greens however are disappointed that their amendment which called for a law to curb “unfair rent rises was defeated by SNP and Conservative MSPs.

The Green amendment was defeated by 85 votes to 20

Andy Wightman, Green Housing spokesman said: “The law, as it currently stands, allows tenants to be evicted on eighteen statutory grounds, which include landlords selling up at short notice, going bust, or converting a residential tenancy to a short-term let. That falls well short of delivering on any sense of housing as a human right.”

The vote comes as a petition by housing campaigner calling for £40m from a £50m ending homelessness fund to be “front loaded” has been sent to the housing minister to consider.

The Local Government Committee has this week asked Housing Minister, Kevin Stewart if a statement by the Communities secretary that “rapid rehousing will be a crucial part of ending homelessness” is consistent with the views of the petitioner.

The petition asks for £40m of the £50m from the Ending Homelessness Together fund to be used in the next year for new homes and refurbish existing properties in tandem with an expanded Housing First policy.

The Petitions Committee previously said the suggestions “had merit” and passed it to the Local Government committee for consideration.