Tony Kanaan, another Brazilian, was second fastest at 231.006mph in a Dallara/Honda with his American team mate Robby Gordon third best at 230.205mph.
Scott Dixon of New Zealand stands fourth in his G-Force/Toyota, followed by British rookie Dan Wheldon in a Dallara/Honda.
Castroneves, who drives for Team Penske, benefited from some last-minute adjustments before qualifying around two hours later than Kanaan, who had taken provisional pole.
IndyCar ready to welcome back spectators
19/06/2020 AT 15:09
"I tell you, Tony was really strong and basically I knew he'd be very hard to beat," said the Castroneves. "That's why I said 'well let's take a chance and see how the car's going to be' all of a sudden."
Stormy weather had washed out scheduled qualifying on Saturday and Sunday dawned with winds gusting up to 38 miles an hour.
Castroneves, at first, was not comfortable in his car.
"When we did the practice this morning, the car was difficult," he said. "My first lap was like 140, I couldn't get going."
But Castroneves and Penske Racing president Tim Cindric then decided a little more practice was in order and the car was reset to original adjustments for better balance.
"We put it back again, retry again, and things started getting very nice," said the Brazilian.
"When we went out, of all a sudden the car was super fast. This place is magic you know.
"This is one of the best days of my life. It's fantastic. It's a dream come true."
Penske, whose drivers have claimed 11 poles and 12 wins at the Indy 500, was delighted his team made the most of their opportunity to claim pole.
"As Rick Mears (a Penske driver with six poles and four wins here) said many times: 'There's two races here, the first race is for the pole and the second one for the race itself'," he said.
"We were not contenders for the pole in the last couple of years, and we knew that. We wanted the pole and we knew that, if we waited, we'd have a better chance (than going out earlier).
"That's the fact of life here -- and we took that chance."
Final qualifying to fill the 33-car grid will take place on May 18.
The 87th Indianapolis 500 takes place on May 25.
Will Power first Australian to win Indy 500
27/05/2018 AT 23:24
Andretti: ‘What will propel Indycar into future’
07/04/2018 AT 19:02