TL;DR
The GBIF (Global Biodiversity Information Facility) API provides access to the world's largest open database of species occurrence records — 2 billion+ observations from museums, citizen science platforms (iNaturalist, eBird), research expeditions, and environmental monitoring programs. Search species by scientific name, retrieve occurrence records with GPS coordinates, filter by country, dataset, or time period, and access taxon names in multiple languages. Essential for ecological research, conservation planning, and biodiversity education.
Quick start: https://api.gbif.org/v1/species/match?name=Ursus%20arctos
No API key needed — just make a request!
https://api.gbif.org/v1/species/match?name=Ursus%20arctos
How to Use This API
1. Species Name Lookup
https://api.gbif.org/v1/species/match?name=Panthera%20leo
2. Occurrence Records (with coordinates)
https://api.gbif.org/v1/occurrence/search?q=Apus%20apus&limit=10&hasCoordinate=true
3. Get Occurrence by ID
https://api.gbif.org/v1/occurrence/123456789
4. Species by Country
https://api.gbif.org/v1/species/search?q=Canada&datasetKey=50c9509d-22c7-4a22-a47d-8c48425ef4a7
5. JavaScript — Species Occurrence Map Data
async function getOccurrences(speciesName) {
// First get the species key
const match = await fetch(
`https://api.gbif.org/v1/species/match?name=${speciesName}`
);
const species = await match.json();
const speciesKey = species.usageKey;
// Then get recent occurrences
const occ = await fetch(
`https://api.gbif.org/v1/occurrence/search?` +
`speciesKey=${speciesKey}&limit=50&hasCoordinate=true`
);
const data = await occ.json();
console.log(`${data.count} occurrences found for "${speciesName}":`);
data.results.forEach(r => {
if (r.decimalLatitude && r.decimalLongitude) {
console.log(` [${r.decimalLatitude}, ${r.decimalLongitude}] ` +
`- ${r.eventDate?.slice(0, 10) || 'unknown date'}`);
}
});
}
getOccurrences('Apus apus'); // Common Swift
6. Python — Recent Bird Sightings
import requests
def recent_sightings(species_name, country='US', limit=5):
match = requests.get(
'https://api.gbif.org/v1/species/match',
params={'name': species_name}
).json()
key = match['usageKey']
occ = requests.get(
'https://api.gbif.org/v1/occurrence/search',
params={
'speciesKey': key,
'country': country,
'limit': limit,
'hasCoordinate': True
}
).json()
print(f'Recent {species_name} sightings in {country}:')
for r in occ['results']:
lat = r.get('decimalLatitude', '?')
lng = r.get('decimalLongitude', '?')
date = r.get('eventDate', '')[:10] if r.get('eventDate') else '?'
print(f' {date} — [{lat}, {lng}]')
recent_sightings('Haliaeetus leucocephalus') # Bald eagle
Frequently Asked Questions
- What is GBIF?
- The Global Biodiversity Information Facility is an international network funded by governments that provides open access to biodiversity data from hundreds of institutions worldwide.
- Do I need an API key?
- No. GBIF data is open access. Some higher-volume endpoints may benefit from registration for increased limits.
- How much data is available?
- Over 2 billion species occurrence records from 60,000+ datasets contributed by 1,800+ institutions globally. It's the world's largest biodiversity database.
- What's a species occurrence?
- An occurrence is a record of a species at a specific location and time — from museum specimens, field observations, camera traps, or citizen science submissions.
- Can I filter by date range?
- Yes, use
eventDateparameters likeeventDate=2020-2025oryear=2023for precise temporal filtering. - What coordinate systems are used?
- Coordinates are in WGS84 decimal degrees. The
hasCoordinate=truefilter ensures you only get records with GPS coordinates for mapping.
API Details
- API URL
https://api.gbif.org/v1/- Documentation
- gbif.org/developer
- Category
- Science
- Authentication
- Not Required
- Geographic Coverage
- Global
What You Can Build
- Species sighting map with real-time occurrence data points
- Citizen science dashboard tracking local biodiversity
- Environmental impact assessment tool using species distribution data
- Educational app that shows what animals live near a user's location
- Conservation planning tool identifying high-biodiversity areas