Muslims invaded India centuries ago which has had the effect of many in the Indian subcontinent becoming Muslims. There is a lot of historical animosity between them and the Hindus. Pakistan as a country exists because it was a project for the two-nation theory which sought to form a country for Indian Muslims from the British Raj. This is why, before Bangladesh was its own country, it was called East Pakistan and fought a war for its independence. There was also a lot of bloodshed between the Pakistanis and Indians when their countries were being made in the aftermath of the collapse of the British Empire.
As
@Fuck Bankers stated, in many ways they are ethnically and linguistically similar but it should be noted that isn't in the case in the more western parts of Pakistan as its home to a lot of Balochs and Pashtuns who are part of the Iranian ethnic group and aren't genetically Indian.