Hernandez, who is of Mexican-American descent, was drafted by the Baltimore Orioles in the 16th round, 483rd overall pick, of the 2005 MLB draft. Hernandez made his MLB debut against the Detroit Tigers on May 28, 2009. He went 5 innings. He gave up five hits, allowed four walks, and one earned run while striking out three. He'd remain in the Baltimore rotation for the remainder of the season, starting 19 games and finishing with a record of 4-10 with a 5.42 ERA. In innings, he struck out 68. The following season he split time between the rotation and the bullpen for the O's, finishing 8-8 in 41 games, 8 of them starts. In innings, he struck out 72.
Arizona Diamondbacks
On December 6, 2010, he was traded to the Arizona Diamondbacks for Mark Reynolds and a player to be named later. In his first season in Arizona, Hernandez served as a closer for a time in the season, recording 11 saves. In a career high 74 games, he had 77 strikeouts in innings. He excelled the following season, posting an ERA of 2.50 with 98 strikeouts in innings. In 2013, he had a high ERA despite posting 66 strikeouts in innings. Hernandez missed the 2014 season after undergoing Tommy John surgery. He came back in 2015, posting an ERA of 4.28 in 40 games.
Philadelphia Phillies
On December 9, 2015, Hernandez signed with the Philadelphia Phillies. In his season with Philadelphia, he appeared in 70 games and posted a 3.84 ERA in innings.
On April 24, 2017, the Braves traded Hernandez to the Los Angeles Angels in exchange for a player to be named later or cash considerations. He appeared in 38 games for the Angels and pitched 36.1 innings, had 37 strikeouts, and finished with a 2.23 ERA before being traded to the Diamondbacks on July 31.
Return to Arizona
On July 31, 2017, Hernandez was traded to the Diamondbacks for Luis Madero. He was 2-1 with a 4.82 ERA.
Cincinnati Reds
On January 30, 2018, Hernandez signed a two-year contract with the Cincinnati Reds. In his first season in Cincinnati, Hernandez appeared in 57 games, registering an ERA of 2.53 in 64 innings. The following season did not go so well for Hernandez as he struggled throughout the season before being designated for assignment on August 10, 2019. He was 2-5 with an ERA of 8.02 in 47 games. On August 10, 2019, the Reds released Hernandez.
Hernandez throws a 95 mph fastball, a 78 mph slider, and an 84 mph changeup. He is known for his high strikeout rate, which improved at every level in the minors, from 9.54 K/9 in A to 12.46 K/9 in AAA. In the minor leagues he was a flyball pitcher – 45% of balls in play were flyballs, with only 38% of them staying on the ground.