Brian Ibe, whose address was given as 35 Moore Park, Newbridge, and no fixed abode, is alleged to have entered that address as a trespasser and committed an arrestable offence and assault causing harm on April 28.
There was a significant garda presence in the court building for the hearing, over a dozen officers were present, including Supt Martin Walker.
Six gardai wearing public order unit uniform markings flanked the defendant for the duration of the hearing.
Det Sgt Ciaran Bruce gave evidence of arresting the defendant and charging him at Newbridge garda station on April 30.
He added the defendant made no reply after being cautioned and he was provided with a copy of both charges.
He said it would be alleged that the defendant smashed a window to enter the house, went directly upstairs and attacked the injured party.
Also present in the house at the time was the defendant’s mother and his niece, aged 6.
Sgt Bruce said it was not clear if the defendant used a knife or sharpened glass in the alleged incident and it was not known if the defendant had a knife when he allegedly entered the dwelling.
The defendant didn’t speak other than to decline an offer of water from Judge Desmond Zaidan.
The court heard that the injured party suffered multiple fractures to his head, a broken jaw and lacerations..
He was treated at the intensive care unit of Naas Hospital and is now being treated at the ICU in Beaumont Hospital.
The gardai opposed bail because of the seriousness of the alleged incident and because they believe the defendant to be a flight risk.
Inspector Paul Reilly said the Director of Public Prosecutions will “be asked to consider more serious charges.”
Defending solicitor Tim Kennelly pointed out that the case against the defendant, who turned 19 less than two weeks ago, is an allegation and he made no submissions.
Applying for bail, Mr Kennelly said a statement allegedly made by the defendant's mother has not been substantiated.
He said the defendant had no previous convictions and never previously been before a court. “Apart from these allegations, he is of good character,” said Mr Kennelly.
Judge Zaidan said he was satisfied that the objections to bail were sustainable. He remanded the defendant in custody until May 7 when he will appear by video link.
Judge Zaidan ordered a psychiatric and psychological assessment for the defendant.
He also granted him free legal aid.