The UK should stay as close as possible to the EU after Brexit, Irish premier Leo Varadkar has said.

The “enormous” trade between Britain and Ireland should be protected to ensure Irish jobs, the premier added.

But he said it was up to the UK to propose a solution on the vexed Irish border question if it rejected that put forward by European leaders.

On Friday morning leaders of the 27 EU member states meeting in Brussels adopted guidelines for future EU-UK relations after the separation in a year’s time.

The Taoiseach said: “The UK has decided to leave the EU. The best way we can get a good outcome for Ireland is to make sure that we have an agreement that keeps the UK as close to the EU as possible.

“That is the best way to avoid a hard border between Ireland and Northern Ireland and also the best way to protect the enormous trade that occurs between Britain and Ireland, and that is so important for Irish jobs and our economy, and agriculture in particular.”

He said everything, including the border, had to be agreed by October.

“If they cannot agree to it at least put forward alternative options that allow the same outcome.

“We need to have a solution that is legal and operable. We have put one on the table backed up not just by us but by the entire EU.

“If that is not acceptable to the UK the onus is on them to come up with alternatives.”

European Council president Donald Tusk said EU leaders wanted to see positive momentum in the negotiations to finalise a solution avoiding a hard border.

He added: “Leaders will assess in June if the Irish question has been resolved and how to go about a common declaration on our future.”

European Commission president Jean Claude Juncker is to visit Ireland in the next quarter, the Taoiseach said.

Mr Varadkar said a backstop, meaning Northern Ireland continued to follow EU rules relating to North-South issues and the all-island economy, was now part of the agreement and talks between Irish and UK officials would be held in Brussels on the text of the protocol over the border.

Mr Varadkar added: “It is not a case of when they are winning we are losing or when they are losing we are winning.

“We are not going to get a good outcome for Ireland on that basis.”

Little agreement has been reached on the detail of measures to avoid a hard frontier with checks on goods and services.

Unionists have opposed any solution which would create differences between Northern Ireland and the rest of the UK, and Prime Minister Theresa May is reliant on Democratic Unionist support in key Westminster votes.

Avoiding a hard border is generally defined as one without frontier checks on goods and services, but there has been no evidence of a technological solution for frictionless trade anywhere else in the world, a committee of MPs said.