A Catholic in Massachusetts from a Catholic political family was never going to enter politics in the late 1940s as anything other than a Democrat.
However, a poor navy vet and lawyer from Southern California could have been recruited into either party, it is just the Republicans happened to recruit him, and with a few tweaks to his political views you can make Nixon a Truman Democrat. So Nixon gets recruited by the Democrats, gets elected to Congress as Democrat (say in 1948, a good Democratic year, instead of 1946), and there is no particular reason why he can't get elected to the Senate as a Democrat from California, since during the Cold War the state did often elect Democrats to the Senate. He can even defeat Graham Douglas in the primary.
Kennedy still gets nominated in 1960, and selects Nixon instead of Johnson as his running mate. He can still get elected, everything else being the same, losing Texas and winning California, and the optics of the ticket are better anyway. This leaves open who the Republican nominee would be, but it would probably be Eisenhower's VP, probably a politician a lot like Nixon, maybe Knowland.