The main aim of this paper is to present a new possibility for detection and recognition of different categories of electric and conventional (equipped with combustion engine) vehicles. These possibilities are provided by use of thermal and visual video cameras and two methods of machine learning. The used methods are Haar cascade classifier and convolutional neural network (CNN). The thermal images, obtained through an infrared thermography camera, were used for the training database. The thermal cameras can complement or substitute visible spectrum of video cameras and other conventional sensors and provide detailed recognition and classification data needed for vehicle type recognition. The first listed method was used as an object detector and serves for the localization of the vehicle on the road without any further classification. The second method was trained for vehicle recognition on the thermal image database and classifies a localized object according to one of the defined categories. The results confirmed that it is possible to use infrared thermography for vehicle drive categorization according to the thermal features of vehicle exteriors together with methods of machine learning for vehicle type recognition.