When dealing with files in JavaScript, you may want to check whether or not a file is an image. This tutorial will show how to JavaScript check if file is image with pure JavaScript function and JQuery.


  • Check if file is image regardless of its type
  • Or If you want to target specific image types


  • Using JQuery to check if the file is an image