India
In its October 1965 issue, the TIME magazine quoted a Western official assessing the consequences of the war[78] —

Now it’s apparent to everybody that India is going to emerge as an Asian power in its own right.

India continued to increase its defense spending after the war. The Indian Armed Forces, which was already undergoing rapid expansions, made improvements in command and control to address some shortcomings. Partly as a result of the inefficient information gathering preceding the war, India established the Research and Analysis Wing for external espionage and intelligence.

India viewed the American policy during the war as biased, since Pakistan had started the war but the US did little to restrain Pakistan.[79] After the war, India slowly started aligning with the Soviet Union, both politically and militarily. This would be cemented formally years later before the Indo-Pakistani War of 1971.

In light of the failures of the previous war against the Chinese, the performance in this war was viewed as a “politico-strategic” victory in India. The Indian premier, Lal Bahadur Shastri, was hailed as a national hero in India.[80] The Sunday Times of London, however, criticized Indian military leaders for failing to effectively use its superior armed forces to achieve a decisive victory over Pakistan.[81]

Pakistan
At the conclusion of the war, many Pakistanis considered the performance of their military to be positive. September 6 is celebrated as ‘Defence Day’ in Pakistan, in commemoration of the successful defence of Lahore against the Indian army. The performance of the Pakistani Air Force, in particular, was praised.

However, the Pakistani government was accused by foreign analysts of spreading disinformation among its citizens regarding the actual consequences of the war.[82] In his book “Mainsprings of Indian and Pakistani foreign policies”, S.M. Burke writes[83] —

After the Indo-Pakistani war of 1965 the balance of military power had decisively shifted in favor of India. Pakistan had found it difficult to replace the heavy equipment lost during that conflict while her adversary, despite her economic and political problems, had been determinedly building up her strength.

Most observers agree that the myth of a mobile, hard hitting Pakistan Army was badly dented in the war, as critical breakthroughs were not made.[84] Several Pakistani writers criticized the military’s ill-founded belief that their “martial race” of soldiers could defeat “Hindu India” in the war.[85][86] Moreover, Pakistan had lost more ground than it had gained during the war and, more importantly, failed to achieve its goal of occupying Kashmir; this result has been viewed by many impartial observers as a defeat for Pakistan.[87][88][89] Rasul Bux Rais, a Pakistani political analyst wrote[90] -

The 1965 war with India proved that Pakistan could neither break the formidable Indian defenses in a blitzkrieg fashion nor could she sustain an all-out conflict for long.

source:
WIKIPEDIA

but not clear who was the real winner…