If you are over 18 and have just left prison, your Probation Officer will be able to give you advice about what housing is available to you.
Hampshire and Isle of Wight Community Rehabilitation Company also runs three hostels in Fareham, Portsmouth and Southampton, mostly taking people on bail or those who have just left prison. Places get snapped up quickly so ask to apply for a place as soon as you can. The Probation Officers are based in teams all around Hampshire; if you have lost the number of yours, ring the Probation Headquarters on 01442 295 010 and ask for your local office.
If you are under 18 and have just left a young offenders institute, the local Youth Offending Service will be able to support you with your accommodation. As well as offering a support service, each youth offending team has a designated Accommodation Officer.
If you become homeless whilst on a Probation Order or a Licence you must tell the Probation Service or YOT immediately or else your probation terms could be breached. Plus, the sooner you let them know you have housing problems, the quicker someone will be able to help you.