Barca to begin title defence at Malaga
Barca's arch-rivals Real Madrid, whose last title came in 2008, host Athletic Bilbao, and Valencia, who finished third last season, play at Osasuna, the RFEF said after the draw was made at their headquarters outside Madrid.
The season-opening Spanish Super Cup between La Liga champions and holders Barca and King's Cup winners Real will be played over two legs on August 14 and August 17.
The first leg will kick off at Real's Bernabeu stadium at 10pm local time and the return leg at the Nou Camp will start at 11pm.
The pair are due to meet in the league for the "Clasicos" on December 10/11 in Madrid and April 21/22 in Barcelona, although the match at the Bernabeu may have to be rescheduled because of Barca's participation in the FIFA Club World Cup.
Opening weekend (August 20/21) Osasuna v Valencia Real Sociedad v Atletico Madrid Villarreal v Sporting Gijon Malaga v Barcelona Real Betis v Sevilla Espanyol v Granada Real Vallecano v Real Mallorca Real Madrid v Athletic Bilbao Levante v Real Zaragoza Racing Santander v Getafe
Matchday 2 (August 27/28) Valencia v Racing Santander Atletico Madrid v Osasuna Sporting Gijon v Real Sociedad Barcelona v Villarreal Sevilla v Malaga Granada v Real Betis Real Mallorca v Espanyol Athletic Bilbao v Real Vallecano Real Zaragoza v Real Madrid Getafe v Levante
Matchday 3 (September 11/12) Valencia v Atletico Madrid Osasuna v Sporting Gijon Real Sociedad v Barcelona Villarreal v Sevilla Malaga v Granada Real Betis v Real Mallorca Espanyol v Athletic Bilbao Real Vallecano v Real Zaragoza Real Madrid v Getafe Racing Santander v Levante
Full fixtures here