Layún began his career in 2006 with Veracruz, and in 2009 signed for Italian club Atalanta, becoming the first Mexican player to play in the Serie A, where he only made two substitute appearances. He returned to Mexico in 2010 with América, winning two league titles before joining Watford in January 2015.
Born in Córdoba, Veracruz, Layún began his professional career with Tiburones Rojos de Veracruz, in his home state, in 2006. He debuted in the Primera División (first division) during the Clausura 2007 tournament on 28 April against Necaxa. The match ended in a 1–1 draw.
He went on to stay with the club until 2009, with Veracruz ultimately being relegated to the second division. Layún managed to score his only goal with Veracruz in a 5–1 victory against Tampico Madero on 25 February 2009, scoring the fifth and final goal.
He made his league debut on 27 September 2009 in a 1–1 draw against Chievo at the Stadio Marc'Antonio Bentegodi in Verona, coming on as a substitute in the 82nd minute of the match for Jaime Valdés, thus becoming the first Mexican to play an official match in Serie A. He made a second league appearance with the team against Cagliari on 1 November, again coming on as a substitute, replacing Nicola Madonna in the 66th minute of the match, which ended in a 3–0 defeat. Layún only managed two league appearances during the season.
On 26 May 2013, Layún scored the final penalty in the shoot-out against Cruz Azul in the Clausura 2013 Final, winning the first league championship in his career. He came on as a substitute, replacing Diego Reyes in the first half of the match.
Prior to the Apertura 2014, Layún was named one of four players that would captain the club throughout the tournament. He captained the team for the first time on 2 August in a league match against Puebla, with América winning the match 4–0. On 26 September, Layún scored four goals in the 4–1 victory over Santos Laguna.
On 14 December 2014, Layún captained América to the league title following a 3–1 aggregate victory over Tigres UANL in the finals.
On 30 December 2014, it was announced that Layún had transferred to La Liga club Granada on a five-year deal; however, he was expected to go on loan for the remainder of the season to English Championship club Watford. On 9 January 2015, it was announced that Layún had signed a permanent four-and-a-half year deal with Watford, being handed the number 7 shirt. He made his Championship debut the following day in the 1–3 defeat to Huddersfield Town, playing all ninety minutes.
In his first season with the club, Layún played in 17 games, with Watford gaining promotion to the Premier League. On 8 August, Layún scored on his Premier League debut in a 2–2 draw against Everton at Goodison Park.
On 31 August 2015, it was announced that Layún would join Porto on a year-long loan deal with an option to buy for €6 million. On 12 September 2015, Layún made his official debut in a 3–1 win against FC Arouca, playing all 90 minutes. On 4 November, he scored his first goal for Porto in the team's 3–1 win over Maccabi Tel Aviv in the Champions League. Four days later, Layún scored his first league goal in Porto's 2–0 win over Vitória Setúbal.
On 28 May 2016, it was announced that Porto had signed Layún on a permanent deal, with the reported €6 million fee to be paid in two installments.
In 2013, Layún received his first national team call up by coach José Manuel de la Torre after his performances with Club América during the Clausura tournament. He was selected for the 2013 CONCACAF Gold Cup held in the United States, with the entire squad being made up of players from the Mexican league. He made his debut on 11 July in the group stage match against Canada at CenturyLink Field in Seattle. He played the entire ninety minutes in Mexico's 2–0 victory. Mexico was eventually eliminated from the competition by Panama in the semi-finals.
Layún was called up again by interim coach Víctor Manuel Vucetich to participate in Mexico's last two World Cup qualifying matches against Panama and Costa Rica. Layún would play in both matches. Mexico nearly missed out on qualifying to the World Cup after Mexico's 1–2 loss to Costa Rica, however Mexico made it to the Intercontinental playoff against New Zealand. Layún again was called up by Mexico's new coach Miguel Herrera – his coach at Club América at the time – to play in the first leg, providing two assists for Oribe Peralta in the 5–1 victory at the Estadio Azteca. Mexico would qualify to the 2014 World Cup by defeating New Zealand by an aggregate score of 9–3.
On 8 May, Layún was included in Mexico's 23-man squad for the 2014 World Cup. He made his World Cup debut on 13 June against Cameroon, playing as a left back. Mexico won the match 1–0. Layún started in all three group matches as Mexico advanced to the round-of-16, where Mexico was subsequently eliminated by The Netherlands.
Miguel Layún is of Lebanese descent, due to his paternal grandfather Yousseff Layún who immigrated to Veracruz, and of Spanish descent, due to his maternal grandfather Guillermo Prado being born in Spain, and as a result holds a Spanish passport. After making his debut for the national team in 2013, he became the second Lebanese-Mexican player after Miguel Sabah to play for the Mexico national team.
Layún and fellow footballer José Abella are second cousins; as their grandmothers are sisters, they have a great-grandparent in common. Layún's sister Mariana participated in the 2010 International Ballet Competition in which she won a bronze medal.