Estrada, wearing dark glasses and a brown jacket, stepped out of a black Mercedes Benz sedan and waved to his supporters and San Juan residents before entering the hospital at 2:50 p.m.
Earlier, he was flown by helicopter to the town from his Tanay resthouse.
Welcoming Estrada at the hospital were students in uniform and his supporters wearing orange shirts and carrying "Hindi Ka Nag-Iisa sa Laban Mo" and "Ikaw ang Tunay na Pangulo ng Masang Pilipino" streamers.
Accompanying Estrada on his hospital visit was his wife Sen. Luisa Ejercito, who rode with him in the car.
The former president was escorted by members of the elite Special Action Force of the Philippine National Police and was secured at the hospital by elements of the Sandiganbayan Sheriffs Office as well as by the San Juan police.
Waiting for Estrada at the hospital was Dr. Eduardo Sarabia, head of the ophthalmology department.
At a press briefing held at the hospital, Sarabia said Estrada has preseptal cellulitis, a common bacterial infection of the eyelid.
He explained that it was most likely that the former presidents right eyelid was bitten by an insect, possibly a cockroach, causing the infection.
Sarabia said Estrada was immediately given steroids and antibiotics to control the swelling and prevent further infection.
He said the former president needs to stay at the hospital for at least three days for the treatment to take effect.
"It would be best if he stays here. The infection can spread to the back of the eye and even transfer to the brain. There is the possibility na mabulag siya," Sarabia said.
He added that the infection could be "life threatening" if it reaches the brain.
For his part, Dr. Lorenzo Hocson, a cousin of the former president and director of the San Juan Medical Center, said he would ask the Sandiganbayan to consider their request to allow Estrada to stay at the hospital for at least three days.
"We will request for an extension. It is quite risky to send him back home (Tanay resthouse) during the antibiotic treatment," he said.
Hocson, who is also Estradas personal physician, said that once the eye infection is treated, they could proceed with a surgical procedure to remove the excess skin on the eyelids.
This condition, known medically as dermatochalasis, causes Estradas eyelids to droop.
However, Hocson said Estrada has to agree first to the procedure to be done at the San Juan Medical Center before doctors can proceed.
"We will still talk to the patient and find out if he is amenable to it," the doctor said.
Hocson said that it would be best for Estrada to remain at the San Juan Medical Center instead of the Veterans Memorial Medical Center during his treatment.
"I dont see the point of moving him to another hospital since he is already here. Besides, I think he will be more comfortable here," he said.
The Sandiganbayan Special Division, which is trying Estrada for plunder and perjury, earlier granted the request of defense lawyers for the former president to seek medical treatment at the San Juan Medical Center for his eye infection.
In a resolution, the court originally gave Estrada permission to leave his Tanay resthouse from noon to 6 p.m. yesterday.
However, Sandiganbayan Sheriff Eduardo Urieta said Estrada was allowed to stay at the hospital overnight on the advise of his doctors.