On September 18, 2014, President Barack Obama nominated Hanks to serve as a United States district judge of the United States District Court for the Southern District of Texas, to the seat vacated by Judge Nancy Atlas, who assumed senior status on June 20, 2014. His nomination was part of a bipartisan package of nominees which included Rolando Olvera and Alfred H. Bennett[6] His nomination was praised by both Senators John Cornyn and Ted Cruz.[7] On December 16, 2014 his nomination was returned to the President due to the sine die adjournment of the 113th Congress. On January 7, 2015, President Obama renominated him to the same position.[8] He received a hearing before the Judiciary Committee on January 21, 2015.[9] On February 26, 2015 his nomination was reported out of committee by voice vote.[10] On April 20, 2015 the United States Senate confirmed him by a 91–0 vote.[11] He received his judicial commission on April 22, 2015,[5] and was assigned to the Galveston Division of the Southern District of Texas.[12] He is the first African-American federal judge to preside over the Galveston court. Hanks has been mentioned as a possible nominee to the U.S. Court of Appeals for the Fifth Circuit.[13]