Minutes after radio monitors in Delhi and Bombay heard the plane's captain signal that the flight was being hijacked, direct contacts were established between senior officials in India and Pakistan. In recent months relations between the two countries had deteriorated sharply. But last night the Indian Cabinet, meeting in an all-night session, commended Pakistan for its cooperation on the hijacking. Plane Is Surrounded

Munir Sheik, a spokesman for the Pakistani Embassy here, said his Government had willingly acceded to India's request that it act to insure the safety of the passengers and protect the plane. He said the plane had been ordered to a corner of the large airfield, where it was encircled by Pakistani security forces.

There has been no word as to what firearms or explosives, if any, the hijackers had. An Indian aviation official said the hijackers had forced the captain to fly to Lahore by threatening the crew with kirpans, the daggers that all believing Sikh men carry as a religious obligation.

Indian Airlines officials identified the leader as Gajender Singh, an officer of the Dal Khalsa, or Society of the Pure, an organization of students and other young Sikhs who want an independent Sikh state. Seven weeks ago, in an interview, Mr. Singh said that his group was seeking to pattern itself after the Palestine Liberation Organization and that it was prepared to use terrorism, which he called ''the political language of the 20th century.'' Militant Sikh Arrested

Mr. Singh said in the interview that he wanted the release of what he said were a number of activists in the movement who had been detained on charges of insulting India's Constitution. Then last week Jarnail Singh, the leader of the militant Sikh Bhinderwale sect, was arrested in connection with the slaying of a Hindu journalist who had criticized Sikh separatism. Gajender Singh had close ties with Jarnail Singh.