With the Potters having already qualified for the last 32, boss Tony Pulis left all 11 players who started against Tottenham last weekend at home but then saw his side take an unlikely 29th-minute lead through Ricardo Fuller.
Asmir Begovic had been superb in keeping Besiktas at bay but in the 59th minute Manuel Fernandes equalised from the penalty spot after Matthew Upson was sent off for felling Hugo Almeida, and goals from substitutes Mustafa Pektemek and Edu secured the points.
Pulis left winger Jermaine Pennant on the bench amid reports of a rift between the pair, with the former Arsenal man named as one of only four substitutes while Besiktas were without dangermen Ricardo Quaresma and Simao through injury.
This always looked Stoke’s toughest test in the group irrespective of team selection, and those fears were quickly realised as the hosts raced out of the blocks.
The Inonu Stadium is officially the loudest in the world and it was rocking as the Besiktas fans celebrated the release from jail this week of popular manager and former player Tayfur Havutcu after five months.
He is expected to face trial in February on match-fixing charges and interim boss Carlos Carvalhal remained in charge tonight, but the news added fuel to an already highly-charged occasion.
In the early stages, the only thing standing between Besiktas and the lead they craved was Begovic, who saved well from Fabian Ernst, Veli Kavlak and Almeida.
Cameron Jerome missed a glorious chance for Stoke from virtually their first attack in the 16th minute, but 13 minutes later Fuller did give the visitors an unlikely advantage, picking up the ball 25 yards out and sending a shot in off defender Egemen Korkmaz.
The Jamaican, who had already earned the wrath of the crowd and been booked for persistent fouling, then appeared to complain he had been hit by something thrown from the stands before a hectic period of play concluded with him hitting the bar in bizarre circumstances.
Keeper Rustu Recber hesitated over a clearance and slammed the ball straight against Fuller, making his first start since rupturing an Achilles in April.
It sailed way into the air before bouncing against the woodwork, with the striker just failing to turn in the rebound.
He collided with the post in the process but was able to continue after treatment, while at the other end Begovic pulled off another fine save from a low Fernandes shot before being booked for time-wasting.
Besiktas brought on top scorer Pektemek for the second half and he was straight into the action with an ambitious strike from 25 yards that flew just over the bar.
The game was then held up as Pennant, a first-half substitute for Andy Wilkinson, refused to take a corner while he was seemingly pelted with objects thrown by the crowd.
Several Besiktas players appealed for calm and referee Marcin Borski went to speak to the home bench before restarting play.
In the 59th minute the game turned decisively in the home side’s favour. Upson complained he got the ball in his challenge on Almeida but replays suggested the decision was probably correct and Fernandes easily dispatched the spot-kick, sending Begovic the wrong way.
It was harsh on the keeper, but he produced his best save of the night five minutes later when he somehow kept out a Fernandes volley from 12 yards.
Stoke were desperately trying to hold on to their point but in the 74th minute Besiktas took the lead they had been threatening all game when Fernandes’ corner was headed in acrobatically by Pektemek.
The Turks then made sure of the points and victory in the group when substitute Edu rifled a shot into the far corner from the edge of the box in the 82nd minute.
Having won seven and drawn two of their previous nine games in the competition, it was a disappointing way for Stoke to finish, but they will still go into the last 32 with plenty of confidence.