My question is this: can an atheist go to heaven? Thank you for your time.
If someone does not come to believe in God because of stubbornness or refusal to give up selfish desires then such a person would be culpable for their lack of belief.
If, however, because of circumstances a sincere person is prevented from coming to belief in God then their lack of faith is called invincible and such a person would not be considered culpable.
As Pope Pius XI noted in Quanto conficiamur moerore:
It is known to us and to you that those who are in invincible ignorance of our most holy religion, but who observe carefully the natural law, and the precepts graven by God upon the hearts of all men, and who being disposed to obey God lead an honest and upright life, may, aided by the light of divine grace, attain to eternal life; for God who sees clearly, searches and knows the heart, the disposition, the thoughts and intentions of each, in His supreme mercy and goodness by no means permits that anyone suffer eternal punishment, who has not of his own free will fallen into sin.