Thornleigh, in the parish of South Colah in the municipality of Hornsby, was first known as South Colo or Pennant Hills. The origin of the name is tied in with the naming of Hornsby. In 1830, police constables Samuel Horne and John Thorn were instrumental in the capture of a dangerous gang of bushrangers. For this act of heroism, they were given grants of land. Constable Thorn was granted 640 acres (259 hectares), though later, when properly surveyed, it was found to be 723 acres (293 hectares)  and the name given to the surrounding area was Thornleigh. 'Leigh' is the old English name for a meadow or cleared forest land. Horne called his grant Hornsby Place.
The first white men to explore the area of Thornleigh were a party lead by Captain Arthur Phillip in 1788. White settlers moved into the area in the 1830s and among them were James Milson, Patrick Duffy, John Thorn and Samuel Horne.
In the early years of settlement orchard and dairy farms were the main industries. In the 1860s the Thorn and Horne grants were subdivided and new settlers began to arrive in the district. In 1884 a zig-zag railway was built to haul rocks from a local quarry. They were used in the construction of the north-bound railway line from Strathfield to Hornsby. The quarry lay 30 metres below track level and about a kilometre from the line. It was in operation for many years, providing white metal from crushed sandstone. 
The main north railway station at Thornleigh opened in September 1886. From here, local produce (mainly citrus fruit), was loaded and transported to the city markets. Fruit grown at Thornleigh was also being exported as far as Vancouver and San Francisco. 
By the 1930s, there were Chinese market gardens along Duffy Avenue and a variety of vegetables were grown. The vegetables were carried to the station in wicker baskets. The siding at Thornleigh was one of the busiest on the northern line during this time. 
In 1901, the National Brickworks started operations at Thornleigh. In 1913, the largest malt works in the southern hemisphere was established by WG Chilvers. The brick works is no longer operating, but in 2008 there is still an industrial area in Thornleigh bordered by Pioneer and Duffy avenues.
The population for Thornleigh in 1895 was 400, double the number 50 years earlier. By 2001, the census showed a total of 7701 people living in the suburb.