also loonie, looney, luny, "crazy; silly and eccentric," 1853, American English, short for lunatic, but also influenced by loon (n.2) and perhaps loon (n.1), the bird being noted for its wild cry and method of escaping from danger. As a noun by 1884, from the adjective.
Slang loony bin "insane asylum" is from 1919. Looney left in reference to holders of political views felt to be left-wing in the extreme is from 1977. Looney Tunes, Warner Bros. studios' animated cartoon series, dates from 1930.