Bottas took the lead with a storming start from third and held off a late charge from Ferrari's Sebastian Vettel in a tense finale to claim his maiden F1 victory on his 81st race start in Sochi.
The British driver, who has won two times in Sochi, was having trouble with the soaring temperatures on his Mercedes auto.
They are both chasing Sebastian Vettel, the championship leader, who has already amassed 86 points, a lead of 37 points from fellow Ferrari driver Kimi Raikkonen, who is in fourth.
Team boss Toto Wolff said Mercedes had not been able to give Hamilton the vehicle he needed.
"They (Ferrari) came out of the winter with a good vehicle and it seems to suit Sebastian a lot".More news: Flames, fatality at Venezuela demo over leader's crisis maneuver
"We need to keep pushing, keep finishing with both cars one and two". I couldn't put the vehicle where I was comfortable, and then in the race I had overheating so I just had to settle for fourth.
"For me, once I got around the first couple of laps I was basically stuck where I was".
There can be no doubt now that the sport's oldest and most successful team are back with a vengeance.
Bottas moves into third place in the championship, 23 points behind Vettel and 10 behind Hamilton.
Behind the Mercedes and Ferraris it was Max Verstappen in the Red Bull who was best of the rest, followed by the Force Indias of Perez and Ocon in sixth and seventh, Hulkenberg's Renault in eighth, Massa's Williams in ninth and Carlos Sainz grabbing the last point for Toro Rosso.More news: Coulter's Berkeley speech canceled, police prep for violence
Toto Wolff was overjoyed to see Valtteri Bottas take his first Grand Prix victory as the Finn took the chequered flag first at the Sochi Autodrom on Sunday.
"There's lots of rumors around".
"I always knew I could get good results if everything goes right and I always trust in my ability", said Bottas. "But the sooner, the more exciting it will be for us". Lewis was one of the first ones to congratulate Valtteri on his first race victory and I think that shows the respect that they have towards each other.
Mercedes' non-executive chairman Lauda added: "They have not been hot so far, and they have been nice because the Finn is not talking much". I think we're working well as a team.
Red Bull is working on a radical overhaul of its RB13 to help bring much needed downforce, having initially focused on producing a low-drag auto only to trail the top two teams in the opening races.More news: Trump agrees to renegotiate NAFTA with Mexico, Canada