A subway train carrying about 300 people collided with an out-of-service train near West 96th Street in Manhattan on Thursday, causing the trains to derail, Metropolitan Transportation Authority officials said.

Twenty-four people were injured when a northbound No. 1 train, traveling at slow speed, collided with the second train, which contained four transit workers, around 3 p.m., according to M.T.A. officials. None of the injuries were considered serious.

M.T.A. officials said at a news conference on Thursday that the crash did not appear to be related to an equipment malfunction.