In his first job since being sacked by United in April 2014, Moyes led La Real to a 12th-place finish in La Liga last season, but was dismissed after a run of six defeats in nine games and replaced by Eusebio Sacristan.
"I am disappointed to have left Real Sociedad," Moyes said in a statement released by the League Managers' Association (LMA), which represents football managers in England.
"I made a firm promise to Real Sociedad to honour my contract and it is disappointing not to be able to fulfil this commitment, especially when I have turned down a number of job opportunities in recent months.
"I would like to thank the club and the president for giving me the opportunity to manage in Spain, at a club with such a rich history of employing British managers.
"I would also like to thank the players, staff and my assistant, Billy McKinlay, for their support and the wonderful people of San Sebastian."