The terrorists were trying to board a train for Lahore from Chaklala Railway Station when they were arrested on a tip-off.
A security official said that two suicide jackets and explosives were recovered from the three militants.
The security forces shifted them to an undisclosed location for interrogation. The identity of the arrested terrorists was not disclosed.
Security has been tightened in the twin cities of Islamabad and Rawalpindi ahead of a protest rally by Imran Khan's Pakistan Tehreek-e-Insaf party and Tahirul Qadri's Pakistan Awami Tehreek on Thursday.