Following a collision between both Ferrari drivers, Hamilton was called in for his third pit stop of the day, which dropped him from second to fourth with two laps left to race.
Mercedes' technical director James Allison called the decision "plain dumb" as Hamilton was forced to challenge three cars in order to take the race win.
"Having not had the shiniest of races up to that point, we then just did something plain dumb, which was we thought we were exchanging a place for fresh rubber with enough laps left to get that place back properly and then have a go for the lead," said Allison.
"That was just factually incorrect because we were exchanging two places - we hadn't factored Gasly - and secondly with the amount of debris on the track, there was just a lot more laps taken up by the safety car than we'd anticipated.
"And that was just your rookie error of a not quite quick enough car on the day and trying to stretch too far for a victory. It wasn't on, we just made a mistake."
Hamilton made his way past Gasly rapidly, however when overtaking Alexander Albon, he made contact with the Red Bull driver.
The six-time world champion received a five-second time penalty for the clash which dropped him down to seventh place, promoting Pierre Gasly and Carlos Sainz to second and third respectively.
Allison affirmed that the mistake was purely down to the decisions made on the Mercedes pit wall, and Hamilton had no part to play in the outcome.
"This was entirely our fault because we saw what we thought was a fleeting opportunity," Allison said. "It was not at all clear to us that it was the right thing to do, but there was a possibility.
"We thought, 'well, let's let's give Lewis a chance to give his view', which we shouldn't have done because honestly, we didn't give him the right information.
"We said one place and it was two and secondly, we should have just made the call ourselves. So he 'ummed and ahhed' for a second or two before diving in the pits, because he likes racing. But that was our mistake.
"From the moment that we made the call, it was like a heart sink moment after he emerged from the box behind Gasly and then we just were thinking 'why did we do that?' So, it wasn't good."
Bahrain International Circuit - Winter testing