Manager Terry Francona and a team trainer visited the mound and after Perez threw a wild practice pitch, he was removed from the game.
"I felt a little something in the shoulder today out there," Perez said. "Obviously not the best timing there, so it's something I have to deal with."
Joe Smith replaced the ailing right-hander, and on his first pitch, he gave up a game-winning two-run double to Ellsbury in a 6-5 loss to the Red Sox.
"On the 1-1 pitch, he felt like a pinch, so we went out to check him and he wanted to keep pitching, so we said, 'Let's throw one or two,' and when he did he felt it again, so we got him out of there and brought in Smitty," Francona said. "That's a difficult situation at best and you saw the results."
Francona said he wasn't sure if his closer will be sent to the disabled list, but more information will be available Monday when the club travels to Cincinnati to open a two-game series against the Reds.
"I've been dealing with a little thing for the last couple weeks," Perez said, "but we stayed on top of it and it had been getting better, but today it just took a couple steps back."
Cleveland had a 5-2 lead when Perez entered the game in the ninth, but it didn't take long for him to get into trouble.
The closer issued a leadoff walk to Dustin Pedroia, then gave up a double to David Ortiz. Both Pedroia and Ortiz later scored on groundouts to cut the Tribe lead to one. Perez then walked Jonny Gomes, allowed a single to Stephen Drew and issued a walk to Jose Iglesias to load the bases with two outs.
That's when Ellsbury came to the plate and Perez's shoulder issues forced him out.
"I don't want to leave that mound at all, especially with the game on the line like that and the team trying to cling to a win, but you can't pick when you're going to get hurt, and unfortunately, it's a little sore," Perez said.
Perez, who has a 4.32 ERA, has been dealing with shoulder issues since spring.
A shoulder strain limited the two-time All Star during Spring Training and, on May 12 in Detroit, he felt discomfort in his right shoulder and was held out.
Michael Periatt is an associate reporter for MLB.com. Follow him on twitter @MichaelPeriatt.