The number of immigrants moving from the European Union to Britain fell by a quarter to a five-year low last year.
ONS data shows figures for 2017 - the first full calendar year since the Brexit vote.
An estimated 101,000 more people arrived in the UK from the bloc than left during the year.
It is the lowest for any 12-month period since the year to March 2013, when it stood at 95,000.
Overall net long-term migration, including arrivals and departures of non-EU nationals, was about 282,000 in 2017.
The figure was up by 33,000 on the year before, but statisticians attributed the rise to an "unusual pattern" in estimates of non-EU student immigration for 2016 which research suggests was an "anomaly".
Net (LSE: 0LN0.L - news) migration from eight eastern European countries that joined the EU in 2004 - Poland, Lithuania, Czech Republic, Hungary, Slovakia, Slovenia, Estonia and Latvia - has fallen from 42,000 in the year prior to the referendum to 6,000 in 2017.
Net migration from 14 more established member states, such as Germany, Italy, Spain and France, has almost halved since the vote, falling from 84,000 in the 12 months to June 2016 to 46,000 last year.
It is estimated that 40,000 more Romanians and Bulgarians migrated to the UK than left last year, the joint lowest net migration figure for the two countries since the year to September 2014.
Non-EU net migration was estimated to be 227,000 last year which is more than twice the figure for the EU.
Nicola White, of the ONS's migration statistics division, said: "With (Other OTC: WWTH - news) around 280,000 more people coming to the UK than leaving in 2017, these latest figures show that migration has continued to add to the UK population.
"Net migration fell following record levels in 2015 and early 2016 and has been broadly stable since. This is similar to the level recorded in the year ending September 2014.
"Underlying this, immigration has remained broadly stable at around 630,000 and emigration has shown a gradual increase since 2015 and is currently at around 350,000."
The government said last week in a paper setting out its Brexit negotiating aims that it wanted to control the number of EU immigrants after Brexit to address the public's concerns about pressures on public services and wages for low earners.
But the Institute of Directors said businesses were struggling to find people with the skills they needed and urged Prime Minister Theresa May to keep the door open on immigration.
The institute's chief economist, Tej Parikh, said: "The government's aim for an ambitious post-Brexit labour mobility scheme is welcome, but we also need to see the government creating a positive overall migration policy later on this year."
The latest figures triggered new calls for the government to ditch its target to bring net migration below six figures.
Shadow home secretary Diane Abbott said: "Like the 'hostile environment', it's clear to almost everyone except Theresa May that the net migration target should go."
Immigration minister Caroline Nokes said the figures showed that "more of the people who are coming to the UK are coming for the reasons we would want - to take up a definite job or to study".
"But while it is not unusual to see quarterly ups and downs, we know more needs to be done if we are to bring net migration down to sustainable levels."