Teenager Naseem Shah struck twice as Pakistan fought back well on a bad-light curtailed first day of Test cricket on home soil for a decade after Sri Lanka made a promising start in Rawalpindi.
Sri Lanka were 202-5 when stumps were drawn with 22.5 overs still due to be bowled, 16-year-old pace prodigy Shah taking 2-51.
The tourists lost their way after an opening stand of 96 between Dimuth Karunaratne (59) and Oshada Fernando (40) in the first match in the longest format to be played in Pakistan since a terror attack on their team bus in 2009.
Sri Lanka lost four wickets for 31 runs in the afternoon session, but Dhananjaya de Silva will start day two unbeaten on 38 with rain forecast over the next few days.
Pakistan have an injury concern over Shaheen Afridi after he was injured fielding as they attempt to make up for lost time in a long-awaited home Test series - and their former coach Mickey Arthur's first in charge of Sri Lanka.
Karunaratne's decision to bat first looked wise when he and Oshada set about laying solid foundations, although the captain had a big stroke of luck when debutant Usman Shinwari struck his off stump early on but the bails stayed on.
Oshada took 20 balls to get off the mark, with Karunaratne playing more fluently in a wicketless opening session that yielded 89 runs, with 57 coming off the skipper's bat.
Pakistan were more disciplined after lunch and got their rewards, Afridi trapping Karunaratne lbw and Oshada edging Afridi to Haris Sohail at first slip.
Kusal Mendis became paceman Shinwari's first Test victim and recalled former captain Dinesh Chandimal was cleaned up by a peach of a delivery from Mohammad Abbas for only two, with Pakistan on a roll.
Angelo Mathews and Dhananjaya showed resistance with a fifth-wicket stand of 62 before the former nicked Shah to Asad Shafiq at second slip attempting an extravagant drive.
Dhananjaya played responsibility and put away loose deliveries with Afridi off the field after doing damage attempting to stop a boundary and Niroshan Dickwella was 11 not out when play was called off for the day.