Scotland's charity regulator has published a report to help charities, including schools and student unions, to retain their charitable status.
Protecting Charitable Status summarises the reviews by the Office of the Scottish Charity Regulator over the past six years, including those carried out in two student unions and 13 schools, five of which initially failed the charity test.
Four independent schools were deemed not to provide sufficient public benefit while Jordanhill School in Glasgow - which is direct grant-aided - fell foul of the rule that charities must be independent of government.
All have now met the test. The independents had to increase bursaries to pupils who could not afford fees, and activity for public benefit, such as opening facilities up to state schools. Jordanhill amended its constitution.
The report also details OSCR's reviews of the University of St Andrews Students' Association and Edinburgh's Telford College Students' Union.
The unions met the charity test even though they carried out commercial activity, such as running bars. But their governance required attention, said OSCR, as the unions' constitutions allowed the university and the college a range of powers in relation to their operation.