24 hours would be sufficient time for a tour of Colombo city + souvenir shopping; alternately, you could spend that time in Negombo, exploring the beaches (although these are mediocre compared to those in the South/South-East/East of the country) and lagoon.
If you're energetic, you could try and pull off a trip to Sigiriya and back (~4 hours each way); a closer attraction is the Pinnawala Elephant Orphanage (~2 hours of travel, one-way). My feel though, is that either of those trips would be exhausting if pulled off during a 24h stopover.