The Hyde Park Barracks were built to allow greater control and surveillance of a growing number of assigned male convicts in the early days of settlement of New South Wales under the Governorship of Lachlan Macquarie between 1810 and 1821. In those early days convicts were assigned to various government services or to private landholders or traders as cheap labour to establish the new colony. The convicts were responsible for their own accommodation while their employer provided rations and a small wage.
At the end of a working day many of the male and female convicts congregated in hotels with other members of the community including soldiers and merchants and trouble frequently followed.
Robberies, assoults and misdemeanours led to public unrest and Macquarie decided a facility was required where these unruly could retire at night and the police could exert some control over them. This increased control was also intended to promote a responsible work ethic, provide a foundation for their reform and reduce crime levels.

Between 1814 and 1820, 11,765 convicts arrived presenting authorities with increasing problems regarding control and social stability. The population of the colony during the majority of Macquarie's term nearly trebled from around 10,000 in 1810 to 30,000 in 1820. Convicts and ex convicts comprised 73 percent of the total population, and 94.4 percent of the male workforce. This large supply of convict labour however, also allowed Macquarie to implement many of the infrastructure needs of the colony.

The Hyde Park Barracks is Australia's first government-built convict barracks, and the only remaining barracks building and complex from the Macquarie era of convict administration. It is also significant because of its association with Francis Greenway, the first official government architect and designer of the Barracks complex. The Barracks is regarded as one of his best works, and he received an absolute pardon at its opening in recognition of his contribution to the colony.

It was designed to provide basic housing for a labour force of 600 male convicts. The central barracks building was used as a dormitory where men slept in canvas hammocks strung from wooden rails in all 12 rooms. Inmates received increased rations of food but lost some of the opportunities for private earnings, and were required to work longer hours for the government than previously. There was also some emphasis on self-sufficiency for the occupants within the overall framework of regulations and routines. This self-sufficiency was demonstrated by the presence on site of bakeries, kitchens, pantries, store rooms and garden plots all maintained by the residents.

After 1830, the Barracks became a place of secondary punishment and a depot for reassignment and trial. The Office of the Principal Superintendent of Convicts was established on the site, overseeing the changes in convict treatment and work recommended by the Bigge Commission. A Court of General Sessions was established to administer punishments for barracks men and other government employed convicts.
Penalties included days in solitary confinement, working in gangs in irons, walking on the treadmill, or up to 150 lashes. The court could also extend convicts' sentences by up to three years with hard labour and transfer men to other penal settlements in the colony or Norfolk Island and Port Arthur. The Barracks was finally closed as convict accommodation in 1848, by which time 8000 convicts had passed through it.

After its closure as a barracks it was used as a female asylum until 1887. Many single or orphaned young women emigrated from Britain and famine racked Ireland for the opportunities for employment in the growing colony. There was a female domestic labour shortage and a lack of suitable women of marriageable age the new colony and women were actively encouraged to emigrate.
When 200 orphan girls arrived on 6 October 1848 on the 'Earl Grey', the building began use used as a reception and labour exchange for 'unprotected female' assisted immigrants. These young women resided in the lime washed brick dormitories. In 1848 the Barrack was especially adapted to accommodate them.

From 1887 to 1975 the Barracks was used as accommodation by various NSW government departments. It is now a museum administered by the Historic Houses Trust of NSW and was included in the National Heritage List on 1 August 2007.
Visitors can explore the museum and join a guided tour.