He was appointed Minister Resident to Colombia in 1869, where he served three years. In 1872, Hurlbut was elected to the U.S. House of Representatives as a Republican Congressman from Illinois. While re-elected for a second term in 1874, he was defeated in 1876. Hurlbut was made ambassador to Peru in 1881, and in that capacity had a row with General Hugh Judson Kilpatrick, U.S. minister to Chile during the War of the Pacific, as each had become a partisan of the country to which he was assigned as the U.S. diplomatic representatives. Hurlbut served as U.S. ambassador to Peru until his death in Lima in 1882.