Car Brands & Parts API
A comprehensive REST API for automotive data. Access thousands of car brands, models, generations, and compatible parts.
API Endpoints
Two powerful endpoints to fuel your automotive applications
Car Brands
Complete database of car brands with models and generations. Includes production years, generation codes (C1, C2, etc.), and model variants. Note: A yearTo: null value indicates the generation is currently in production (2025+).
{
"brand": "Audi",
"models": [
{
"name": "A1",
"generations": [
{ "name": "8X", "yearFrom": 2010, "yearTo": 2018 },
{ "name": "GB", "yearFrom": 2018, "yearTo": null }
]
},
]
}
Car Parts
Extensive catalog of automotive parts with slugs and names. Perfect for building parts search, inventory management, or e-commerce applications.
{
"slug": "absorber-bampera",
"name": "Абсорбер (наполнитель бампера)"
}
API Statistics
Live data loaded from the API
0 Brands
0 Models
0 Parts
0 ms Response
Use Cases
Real applications powered by this API
Car Dealership Inventory
Sync brands, models, and generations to manage stock.
Auto Parts E-Commerce
Map car generations to compatible parts.
Vehicle Comparison Tools
Use years & generations for detailed car comparisons.
Maintenance Trackers
Show compatible parts and model-specific data.
Quick Start
Get up and running in seconds
// Fetch all car brands
fetch('https://lifeofcapo.github.io/car-api/car-brands.json')
.then(response => response.json())
.then(data => {
console.log('Total brands:', data.length);
// Find a specific brand
const audi = data.find(brand => brand.brand === 'Audi');
console.log('Audi models:', audi.models);
})
.catch(error => console.error('Error:', error));
import requests
# Fetch car parts
response = requests.get('https://lifeofcapo.github.io/car-api/car-parts.json')
parts = response.json()
# Search for specific parts
absorbers = [p for p in parts if 'absorber' in p['slug']]
print(f'Found {len(absorbers)} absorber parts')
Advanced Examples
Real-world use cases and patterns
async function findCarsByYear(year) {
const response = await fetch('https://lifeofcapo.github.io/car-api/car-brands.json');
const brands = await response.json();
const results = [];
brands.forEach(brand => {
brand.models.forEach(model => {
model.generations.forEach(gen => {
const endYear = gen.yearTo || new Date().getFullYear();
if (year >= gen.yearFrom && year <= endYear) {
results.push({
brand: brand.brand,
model: model.name,
generation: gen.name,
years: `${gen.yearFrom}-${gen.yearTo || 'present'}`
});
}
});
});
});
return results;
}
// Usage
findCarsByYear(2020).then(cars => {
console.log('Cars from 2020:', cars);
});
import { useState, useEffect } from 'react';
function CarBrandSelector() {
const [brands, setBrands] = useState([]);
const [selectedBrand, setSelectedBrand] = useState(null);
const [loading, setLoading] = useState(true);
useEffect(() => {
fetch('https://lifeofcapo.github.io/car-api/car-brands.json')
.then(res => res.json())
.then(data => {
setBrands(data);
setLoading(false);
});
}, []);
if (loading) return <div>Loading...</div>;
return (
<div>
<select onChange={e => setSelectedBrand(e.target.value)}>
<option>Select a brand</option>
{brands.map(brand => (
<option key={brand.brand} value={brand.brand}>
{brand.brand}
</option>
))}
</select>
{selectedBrand && (
<div>
<h3>Models for {selectedBrand}</h3>
{brands
.find(b => b.brand === selectedBrand)
?.models.map(model => (
<div key={model.name}>{model.name}</div>
))}
</div>
)}
</div>
);
}
Features
Everything you need in a modern API
Lightning Fast
Hosted on GitHub Pages CDN for instant global access with minimal latency
CORS Enabled
Call from any domain without restrictions. Perfect for frontend applications
100% Free
No API keys, no rate limits, no hidden costs. Just pure data access
JSON Format
Clean, structured data that works with any programming language
Always Available
99.9% uptime guaranteed by GitHub's infrastructure
Rich Data
Comprehensive information including years, generations, and compatibility
Try It Now
{}