OPT allows foreign nationals who enter the United States on a student visa to work in the US for 12, or in some cases 24, months. It also allows students to transition to an H-1B visa sponsored by employers.