To get the value of src attribute in jQuery is quite easy. Let’s first see how we can add jQuery − You can try to run the following code to learn how to get the value of src attribute in jQuery − Example. Translate. create a 1x1 transparent gif or png. In case the code was in a separate file, the URL of that file should be set as the value to the src attribute of a