Format Parameter
Choose output type with ?format= and understand how format interacts with size and variants.
Format
Use format to choose the output file type for a logo.
Quick take: pass a format like svg, png, or jpg to control the image type.
query
formatstring
Output image type. Common values: svg, png, jpg, webp, avif.
jpg does not support transparency.
curl "https://api.brandql.com/logo/stripe.com?format=svg"
curl "https://api.brandql.com/logo/stripe.com?format=png&size=128"
curl "https://api.brandql.com/logo/stripe.com?variant=dark&format=png"
Supported formats
| Format | Transparency | Notes |
|---|---|---|
svg | Yes | Vector, scales infinitely |
png | Yes | Default raster format |
jpg | No | Smaller files, no transparency |
webp | Yes | Modern raster format (where available) |
avif | Yes | Modern raster format (where available) |
If a format is not available for a given logo, we fall back to the default image unless you set fallback=false. See Fallback Parameter.
Format and size
- Raster formats (
png,jpg,webp,avif) respectsize. svgignoressizebecause it is resolution independent.
Format and transparency
png,webp, andavifcan carry transparency.jpgcannot carry transparency.svgis transparent by default.
If you explicitly want a transparent background, use Variant Parameter with variant=transparent.
Format and variants
Format works with variant. If the requested variant is missing, we fall back to the default logo unless you set fallback=false. See Variant Parameter.
Common picks
svg- Best for UI and scalingpng- Safe default for most casesjpg- Smallest files when transparency is not neededwebp- Great compression for modern browsersavif- Smallest files, newest support
Notes
- Some domains do not have SVG logos. If you need SVG only, set
fallback=falseto get a 404 when unavailable. - If you want to keep backgrounds intact, do not set
variant=transparent.
Related
Was this page helpful?