There's a false assumption here that the US not "going for the Moon" means we somehow "lose" the Space Race which is wrong on many levels.
Without the efforts you put into Apollo program - yes, you have all chances to do that. It is not guaranteed, of course - there are still a probability that Nixon would be able to pull a miracle - but chances of US losing Moon Race would be more than the other way.
Actually not as great a chance as OTL and look how close THAT 'race' was
At the time when Gagarin flew it had already been planned to follow Mercury with the three-man Apollo spacecraft lofted on the Saturn 1. (Mercury was unable to be expanded and didn't have the utility the Vostok did so the USSR continued to use it till it ran out of capability) The limitations of the Mercury were well known and understood before it flew and were glaringly obvious once it had flown so the "Mercury MkII" was suggested. Unfortunately it wasn't that simple and so Gemini came along and it turned out to be quite capable in and of itself. But like the Soviets the US planned at a minimum a three person orbital spacecraft to carry through the late 60s and into the 70s to support Earth orbital and then later Lunar operations. That was Apollo for the US and Soyuz for the USSR. At this point no one was in any hurry to get to the Moon anytime soon.
Then Kennedy, already smarting from the Bay of Pigs failure got side-swiped by Gagarin's flight and needed a clear "win" in technology for the US to counter that. No matter how hard he looked everything kept coming back to space even though there were dozens of 'tech' projects that the US could do that the USSR could not. Space was currently the place to show off and so Kennedy reluctantly choose the Lunar Landing goal as the most obvious, most near term, and the one the US was most likely to win. (With both parties starting out in essentially the same place)
He spent the rest of his time in office trying to come up with a way to scale it back or reduce it in some way because he realized that it would cost so much and end up being so limited. Considering how much domestic push-back he was getting over the costs and resources less than a year later this is really no surprise.
Had he lived those costs and expenditures would likely have been an large election issue in 1964 and not in a good way. If re-elected he likely would have scaled things back and tried harder to interest the Soviets in a cooperative mission instead.
Nixon has none of that baggage. He likely goes all in on Cuba and will have that 'win' (or at least very close to) under his belt and will feel no need to 'respond' aggressively to Gagarin's flight. He'll have learned from Eisenhower's mistake that NO response is a bad thing but giving into Johnson, (who'd have gone back to Congress) a little bit with his idea of 'Reconstruction 2.0" through NASA will probably help smooth the way for Civil Rights reform, (something they both wanted) and give NASA enough money to accelerate Gemini and Apollo and get more orbital work done.
Since he and Khrushchev have more depth a LOT of the underestimations and midreadings of Kennedy-v-Khrushchev won't be there so it's a lot more likely that cooperative talks start at a higher level and get further than OTL. Again, no one is in any rush to get to the Moon.
If Gemini still happens, (up in the air as the OTL Lunar Goal drove a lot of that effort) then it likely goes into orbit of the Moon sometime in the late 60s and there will likely be some work on a cooperative effort to land on the Moon by the mid-70s in the works.
And what would it means if by early 1970s Soviets would land on Moon?
[/QUOTE]
Why would they? They didn't take the US Lunar goal seriously until the mid-60s by which point it was clear that we were actually serious and they still took forever and didn't support their own program very deeply until it was far to late. Here they have even less incentive to try.
Keep in mind that the early Soviet space program was specifically a 'side-note' to military missile and space development. While a lot of people in the program would talk about the Moon and Mars and such they did not do so around those actually paying the bills. They were in the same boat as the people in the US who had discussed such things all through the early 50s when they were (officially) told to shut up or lose their careers! (Amusingly that memo literally came out the day before Sputnik went up and was promptly ignored

)
The Soviets were arguably more surprised than anyone that they actually managed as many 'firsts' as they did and they were also aware they were running into the limit of their equipment and capability which is why they were working on Soyuz.
If the US doesn't push neither will the USSR. Both will focus more on Earth orbital work through a lot of the 60s and only gradually build up to Lunar capability. Assuming something similar to OTL for Gemini then that capability comes around the late 60s to at least get into orbit. If the Soviets push it they can stay in the game but they nor the American's can land at this point. And by the late 60s in any case both Apollo and Soyuz are at least flying in Earth orbit so the actual 'technical' differences are less allowing the possibility the Soviets might actually feel comfortable with the idea of cooperation with the US. (Anytime prior to that point the Soviet's limitations are too noticeable to allow them to let the American's see their stuff

)
Randy