The greater availability of affordable social housing in Scotland has kept its poverty rate down, according to a wide-ranging report.
Scotland currently has 19% of households living in poverty, the Joseph Rowntree Foundation (JRF) said.
This compares to a rate of 24% in Wales and 22% in England.
The Scottish rate has declined from 23% in the mid-1990s to a low of 18% between 2008 and 2013, before rising slightly to its current level.
But the foundation said in its annual report that poverty continued to have a "grip" on the UK as a whole.
About 14 million people are living in poverty across the UK in 2019-20 - four million of them children, according to the charity.
How does Scotland compare?
19%Living in poverty in Scotland
18%in Northern Ireland
At 19%, or just over one million people, Scotland has one of the lowest poverty rates in the UK - only Northern Ireland has a lower rate.
The foundation has also broken down this figure into some broad categories for Scotland.
Although poverty rates are lower than the rest of the UK, the trends are rising.
The foundation has criticised the Scottish government on the levels of child and in-work poverty following Thursday's budget.
Jim McCormick, the JRF's associate director for Scotland, said: "On most measures, poverty in Scotland is lower than in the UK as a whole.
"But that is cold comfort to the growing number of families caught in a rising tide of in-work poverty, especially those in low paid work, with limited hours and facing UK social security cuts.
"While the new Scottish Child Payment will help, now is the time to invest further in affordable housing and good work if we are to meet ambitious child poverty targets in four years."
Why is housing so important?
Housing is the biggest outgoing for most families, so the availability of affordable rented accommodation can have a big impact on poverty figures.
Since 2000, the UK private rented sector has doubled in size and the foundation says an increasing number of the lowest incomes households are renting in this sector. Housing costs in the social sector have also increased since 2002.
Scotland has bucked this trend with more social housing available at more affordable rents.
The report states: "New analysis in the JRF Poverty in Scotland 2019 report shows that the difference in rates between Scotland and the rest of the UK is mainly due to lower rents in the social housing sector as well as Scotland having a higher proportion of social rented properties."
But wherever you live in the UK, the less money you have, the more likely you are to live in poorer quality housing.
This data can be difficult to compare across the UK as each nation has its own housing standard, and newer social housing is also likely to be of a much better quality, the foundation said.
Figures from 2016 showed that 45% of lower income households in Scotland lived in what were classed as "unfit dwellings".
How does childcare affect poverty rates?
For families with young children - particularly large families - childcare costs can take big chunks out of income.
The foundation said childcare costs were increasing faster than the overall rate of inflation in England, Wales and Scotland.
Wales has the cheapest childcare costs, with Scotland in the middle of the table.
For Scotland, it costs about £146 a week to send a toddler to nursery, or £138 a week if they are looked after by a childminder.
The problem with 'problem debt'
The foundation said people on low incomes often speak of being trapped in a "never-ending circle" or being "stuck" in unaffordable housing.
Poverty is often described as a spiral and one way of illustrating that is through "problem debt". This is defined by the Family Resources Survey as being behind with any household bill or credit commitment.
In Scotland, 19% of the lowest income households have problem debt - the highest across the UK. Among the richest fifth in Scotland, the figure is just 1%.
As this chart shows, the percentage of working-age households with no-one in employment has actually seen a steady decrease over the past 20 years.
The current rates in Scotland, Wales and Northern Ireland are all around 18%.
However, the foundation says the increasing amount of work does not tell the whole story, with a "rising tide" of poverty among those who are in work.
More than three in five people in poverty are in a working family and in-work poverty has risen from 10% of workers 20 years ago to 13% now.
This increase continued across the UK despite the introduction of the National Living Wage in 2015.
The foundation argues that raising hourly pay is not enough to provide a "reliable route" out of poverty.
"There is more that can be done through the labour market to make work a more effective route out of poverty," the report says.
"Part of the solution is that people need to be able to work sufficient hours - and have enough certainty over their hours - to earn enough to cover their essential costs.
"And people need to have the opportunity to progress into better quality jobs."
The attainment gap
The figures above show that on this measure, the attainment gap has started to narrow - and it is an area where the Scottish government has diverted significant funding.
But if you come from a lower income household, you are still much more likely to leave school with fewer qualifications - and all the disadvantage that this can entail.
How has the Scottish government responded?
The Scottish government has welcomed the report's "acknowledgement" that Scotland is a country where people are more likely to be able to "progress out of poverty".
Communities Secretary Aileen Campbell said: "The Scottish government invested more than £1.4bn in support targeted on low-income households in 2018-19, including £100m to mitigate the worst impacts of UK government welfare cuts, and we expect a similar amount to have been spent last year."
She also pointed to the Scottish government's Tackling Child Poverty Delivery Plan, which will offer £10 a week per child to low-income families, and the investment of £3.3bn to deliver 50,000 affordable homes.