Search through hundreds of thousands of royalty free images to match any topic you want. The images are returned in a list with the URL, width, and height of the image. Additionally, you can find the license type and link of the image.
| Name | Example | Description |
|---|---|---|
query | dogs | The search query. |
number | 3 | The number of images to return in range [1,100] |
api-key | abcd1234 | Your API key. |
{
"images": [
{
"url": "https://images.unsplash.com/photo-1529472119196-cb724127a98e?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=M3w5NTgyNnwwfDF8c2VhcmNofDF8fGRvZ3N8ZW58MHx8fHwxNzA4MjkyMjA0fDA&ixlib=rb-4.0.3&q=80&w=1080",
"thumbnail": "https://images.unsplash.com/photo-1529472119196-cb724127a98e?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=M3w5NTgyNnwwfDF8c2VhcmNofDF8fGRvZ3N8ZW58MHx8fHwxNzA4MjkyMjA0fDA&ixlib=rb-4.0.3&q=80&w=200",
"width": 2303,
"height": 3594,
"license": {
"name": "FREE",
"link": "https://unsplash.com/license"
},
"id": "U6nlG0Y5sfs"
},
{
"url": "https://images.unsplash.com/photo-1598133894008-61f7fdb8cc3a?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=M3w5NTgyNnwwfDF8c2VhcmNofDJ8fGRvZ3N8ZW58MHx8fHwxNzA4MjkyMjA0fDA&ixlib=rb-4.0.3&q=80&w=1080",
"thumbnail": "https://images.unsplash.com/photo-1598133894008-61f7fdb8cc3a?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=M3w5NTgyNnwwfDF8c2VhcmNofDJ8fGRvZ3N8ZW58MHx8fHwxNzA4MjkyMjA0fDA&ixlib=rb-4.0.3&q=80&w=200",
"width": 2694,
"height": 4033,
"license": {
"name": "FREE",
"link": "https://unsplash.com/license"
},
"id": "BJaqPaH6AGQ"
},
{
"url": "https://images.unsplash.com/photo-1568572933382-74d440642117?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=M3w5NTgyNnwwfDF8c2VhcmNofDN8fGRvZ3N8ZW58MHx8fHwxNzA4MjkyMjA0fDA&ixlib=rb-4.0.3&q=80&w=1080",
"thumbnail": "https://images.unsplash.com/photo-1568572933382-74d440642117?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=M3w5NTgyNnwwfDF8c2VhcmNofDN8fGRvZ3N8ZW58MHx8fHwxNzA4MjkyMjA0fDA&ixlib=rb-4.0.3&q=80&w=200",
"width": 3024,
"height": 4032,
"license": {
"name": "FREE",
"link": "https://unsplash.com/license"
},
"id": "v0_MCllHY9M"
}
]
} Copy Code
curl -X GET 'https://api.apileague.com/search-images?query=dogs&number=3' \ -H 'x-api-key: myapikey'
Response Headers:
Content-Type: application/jsonX-API-Quota-Request: The number of tokens used by the requestX-API-Quota-Used: The number of tokens used in total todayX-API-Quota-Left: The number of tokens left today (depends on your plan)Yes, the API searches through sources that provide royalty-free images, but it's always good practice to check the specific license link returned with each image.
The images are aggregated from popular stock photo sites like Unsplash, Pexels, and Pixabay.
Currently, the search is keyword-based. However, the returned image dimensions allow you to filter for landscape or portrait images in your application logic.
The Search Images API finds high-quality stock photos for general use, whereas the Search Icons API is designed to find vector-based or small raster icons for UI design.