The north-east club have agreed to pay the La Liga side around €4 million (£2.8m; $4.4m dollars) for the 29-year-old, who has 17 caps for Uruguay.
“Christian Stuani will leave Espanyol in the coming days, since there is an agreement in principle for his departure,” read an Espanyol club statement.
“The Uruguayan international this week had to train with Espanyol but the player has permission by the club to finalise his transfer to his new team in the coming days.
“RCD Espanyol thanks Christian Stuani for his professionalism and esteem within our organisation and wishes him every success at his new football club,” concluded the statement.
Stuani still needs to pass a medical with Middlesbrough, who are coached by former Real Madrid and Athletic Bilbao player Aitor Karanka.
Stuani, who featured twice as a substitute in the Copa America as Uruguay were eliminated by hosts Chile in the quarter-finals, joined Espanyol on loan for the 2012/13 campaign before making a permanent move to the Barcelona-based side the following summer.
He scored 29 goals and played over 100 games for the Catalans.