Suffolk County police say the accident happened Saturday on Sunrise Highway in Shirley.
They say 30-year-old Steven Kinalis rear-ended a pickup truck driven by 36-year-old Kevin Gaffney. The truck veered off the road and hit a tree.
Gaffney's 5-year-old son was critically injured and was airlifted to Stony Brook University Medical Center.
The boy died Sunday.
Gaffney, his wife and two other children were treated for less serious injuries.
Kinalis was awaiting arraignment on a charge of driving while impaired by drugs. No information on an attorney was immediately available.