Penn, 65, won the Oscar for best supporting actor for his role in the political thriller One Battle After Another, but skipped Sunday's ceremony to travel to meet Ukraine's President Volodymyr Zelenskiy in the war-battered capital.
Ukraine's state railway operator posted a short video clip of Penn getting out of the train in the morning, saying it had kept his trip a secret until the very last moment.
"Now we can say it officially: Sean Penn chose Ukraine over the Oscars!" it said in its Facebook page.
Local media outlet UkraineWorld also posted a photo of the star at the train station surrounded by supporters.
Zelenskiy posted a picture of him meeting the actor in the presidential office in Kyiv's barricaded government quarters.
The photo showed the black-clad president talking to Penn who was wearing a t-shirt and jeans. There were no immediate details on their conversation.
"Sean, thanks to you, we know what a true friend of Ukraine is," Zelenskiy wrote on X.
"You have stood with Ukraine since the first day of the full-scale war. This is still true today," Zelenskiy said.
Penn, a long-time advocate for Ukraine, has visited the country several times during the four-year war with Russia.
He filmed a documentary about Russia's invasion, that premiered in February 2023. Penn also lent Zelenskiy, a former comedian and actor, one of his other Oscars in 2022.