Gardner was born in
Oakland, California. He was raised by his mother and his extended family in the
Maxwell Park neighborhood, and began playing basketball at the age of four. As a sophomore in 2008–09, he averaged 19.8 points, 6.0 assists, 2.1 rebounds and 2.2 steals per game as he helped the Buffaloes finish with a 24–4 record. As a junior in 2009–10, he averaged 24 points, 3.8 assists, 3.9 rebounds and 3.5 steals as he helped the Buffaloes finish a 23–6 record. In 2010, Gardner transferred to
Westwind Preparatory Academy in
Phoenix, Arizona. He did not meet the eligibility requirements of the Arizona Interscholastic Association because of transferring in his senior year, so he did not play on WPA's State Championship High School team that year. Instead, he played on WPA's prep team. Gardner was chosen to participate in the NCAA's High School Slam Dunk contest during the Final Four Tournament, where the crowd watched the same showmanship that has led to hundreds of thousands of hits on his
YouTube highlight videos. He averaged 23.7 points, seven assists, four steals and four rebounds per game during the 2010–11 season, leading Westwind to a 30–2 record and a state title. ==College career==