Bottas-who secured second in Q2 at the very end-carried his momentum in Q3 as he quickly set the quickest time.
After three hard practice sessions, qualifying also proved tough - with Turns 2, 6 and 8 causing most problems.
Hamilton went wide at Turn 16 as he failed to top it, but the session was quickly brought to a halt when Daniel Ricciardo hit a wall exiting Turn 6.
"It's disappointing obviously", Bottas said.
Raikkonen was 1.1 seconds off the pace in third, top Ferrari driver, and not happy to be as far back.
"I think it's one of the tracks where you need to have the auto in the window and tyres in the window, and then, if you feel confident, you extract a lot of lap time as well".
"I saw Valtteri (Bottas) ahead and knew he was doing a good lap but I remember coming down from the last corner and thinking, 'Please be enough, ' and I'm ecstatic".
Brexit deal will not `shut down´ immigration, vows Chancellor
Philip Hammond told a London audience that what is needed first is a comprehensive trade agreement and secondly transitional arrangements.
"Yesterday we were at a bit of a loss and we had to make a lot of changes overnight", said Hamilton, who was 10th in P2.
"We would have loved to have had more laps this morning".
The narrow confines of the Baku City Circuit have caused a number of problems for drivers here with Turn Eight - the strip of tarmac which measures just 7.8 metres in width - the scene of two crashes. I didn't. Second place is not bad.
"I was going for the pole and the lap wasn't quite ideal".
Hamilton continued to blister his way through the field, with Bottas a good three-tenths behind him.
"With the place, with the feeling that we had, I'll happily take it and I'm not surprised with the time difference".
The pack were poised ready to get back out on track, with Verstappen hoping to get two laps in when the clock restarted, and instructed by his team to defend his position if the Mercedes cars tried to get past him.
The Force Indias of Sergio Pérez and Esteban Ocon were sixth and seventh respectively, whilst rookie Lance Stroll outqualified his Williams team-mate Felipe Massa to bag eighth spot.
He will serve a mammoth 40-place grid drop, while his McLaren team-mate Stoffel Vandoorne has been penalised by 30 places following a raft of new parts on his engine, too.
Fernando Alonso, already hit with a 40-point grid penalty, failed to advance past Q1 for the first time this season, while Jolyon Palmer did not take part in qualifying after a fire in his vehicle during Saturday morning's practice.