Liam Whoriskey, of Glenabbey Gardens, made his first appearance at Derry Magistrates’ Court on a single charge of murdering toddler Kayden McLaughlin McGuinness.
Three-year-old Kayden was found dead at his mother’s flat at Colmcille Court in the Bogside on September 17 last year.
Police officers filed into the courtroom for the hearing to prevent any trouble.
A detective from the PSNI’s Major Investigation Team based at Maydown in Derry told the court he believed he could connect the accused to the offence.
Whoriskey only spoke to confirm his name during the brief hearing.
The defendant is expected to apply for bail at the High Court in the coming weeks.
Whoriskey was remanded in custody to Maghaberry prison to appear in court again via videolink on Thursday July 5.
There were shouts and jeers from the public gallery as Whoriskey was led handcuffed to the cells in the courthourse.
A 24-year=old woman who was arrested on Monday has been released by police pending a report to the PPS.