The first handheld video game is generally credited to Auto Race, released by Mattel in 1976. It paved the way for the portable gaming devices we know today.
If you'd like to dig deeper into the history of handheld consoles, Wikipedia is a great resource. Just search for "Handheld game console" at the top of the page and press enter to pull up the full overview.