The USA international will move for an undisclosed fee after making it clear that he wanted to leave the Glasgow club, who have been relegated to the fourth tier of Scottish football due to their financial troubles.
Rangers manager Ally McCoist had previously claimed that Ipswich had made a bid for the player, although this was denied by the Championship club.
Stoke had also signed Geoff Cameron from the Houston Dynamo earlier in the week, making Edu their second USA international signing of the summer and their second Rangers player after signing young Scottish midfielder Jamie Ness earlier in the transfer window.
Edu was signed by former Rangers boss Walter Smith from Toronto FC in August 2008. He won three Scottish Premier League winners medals during his time at the Ibrox club.