Rendering API
Rendering API Reference
The imgix Rendering API can optimize your images, improve your page speed, and make it easy to create responsive designs.
By adding these parameters to your image URLs, you can enhance, resize and crop images, compress them and change format for better performance, create complex compositions, and extract useful metadata. These operations can be applied programmatically in real time across entire image libraries, removing the need to batch process or maintain multiple copies of an image to match device breakpoints.
This section of the documentation describes all of the parameters available in the Rendering API and includes live examples that you can experiment with. For more detailed information about how to implement for specific use cases, please see the Tutorials section. To learn more about the basics of serving images once you’ve set up the service, read the Serving Images guide.
Base64 Variants
All imgix parameter values (with the exception of auto
and ch
) can be encoded using a URL-safe Base64 scheme. To use this approach, pre-encode the value, and append 64
to the end of the parameter name. For example, txt
becomes txt64
.
Please keep in mind that this uses the URL-safe alphabet as defined in RFC 4648, and that any padding characters (=) must be omitted from the final encoded value.
Here's an example:
?txt=Hello%2C%20World!
becomes the following when URL-safe Base64 encoded:
?txt64=SGVsbG8sIFdvcmxkIQ
Generating Base64-encoded parameters is easy in many languages. Here’s an example of how to do it in Ruby:
require "base64"
Base64.urlsafe_encode64("Hello, World!").delete('=')
#=> "SGVsbG8sIFdvcmxkIQ"
Many of the imgix client libraries automatically encode strings passed to Base64 variant parameters. Check whichever library you're using for specific details of its implementation.
Colors
Some parameters, such as bg
and border
, accept colors as values. Colors can be expressed as either:
- A color keyword, such as "orange" or "lightsteelblue". See the full list of accepted color keywords.
- 3- (RGB), 4- (ARGB) 6- (RRGGBB) or 8-digit (AARRGGBB) hexadecimal values. The "A" in a 4- or 8-digit hex value represents the color's alpha transparency. When outputting image formats that do not support transparency (such as JPEG), set this value to a non-transparent color.
Metadata
By default, imgix will strip most metadata (EXIF data, geolocation, etc.) from any image processed by imgix. The only exception is for images that are served via passthrough.
If you need to have Copyright or IPTC metadata preserved on your images, please contact us.
Limits
- Canvas size: The maximum supported canvas size is 8192px by 8192px. If your image is larger than the limit, it will be resized to fit within the limit before any other imgix operations occur. If you require a larger canvas size, please contact us.
- Input file size: The maximum accepted input file size is 500MB. If your image is larger than the limit, you may receive a
413 Entity Too Large
error. If you require a larger input file size, please contact us.
All Parameters (by Category)
Adjustment
-
bri
Brightness
-
con
Contrast
-
exp
Exposure
-
gam
Gamma
-
high
Highlight
-
hue
Hue Shift
-
invert
Invert
-
sat
Saturation
-
shad
Shadow
-
sharp
Sharpen
-
usm
Unsharp Mask
-
usmrad
Unsharp Mask Radius
-
vib
Vibrance
Animation
-
fps
Frames Per Second
-
frame
Frame Selection
-
gif-q
Animated Gif Quality
-
interval
Frame Interval
-
loop
Animation Loop Count
-
reverse
Reverse
-
skip
Frame Skip
Automatic
Background Removal
Blending
-
blend-align
Blend Align
-
blend-alpha
Blend Alpha
-
blend-color
Blend Color
-
blend-crop
Blend Crop
-
blend-fit
Blend Fit
-
blend-h
Blend Height
-
blend-mode
Blend Mode
-
blend-pad
Blend Padding
-
blend-size
Blend Size
-
blend-w
Blend Width
-
blend-x
Blend X Position
-
blend-y
Blend Y Position
-
blend
Blend
Border & Padding
-
border-bottom
Border Bottom
-
border-left
Border Left
-
border-radius-inner
Inner Border Radius
-
border-radius
Outer Border Radius
-
border-right
Border Right
-
border-top
Border Top
-
border
Border Size Color
-
pad-bottom
Padding Bottom
-
pad-left
Padding Left
-
pad-right
Padding Right
-
pad-top
Padding Top
-
pad
Padding
Color Palette
Expiration
Face Detection
Fill
-
bg
Background Color
-
fill-color
Fill Color
-
fill
Fill Mode
-
grid-colors
Grid Colors
-
grid-size
Grid Size
-
transparency
Transparency
Focal Point Crop
-
fp-debug
Focal Point Debug
-
fp-x
Focal Point X Position
-
fp-y
Focal Point Y Position
-
fp-z
Focal Point Zoom
Format
-
ch
Client Hints
-
chromasub
Chroma Subsampling
-
colorquant
Color Quantization
-
cs
Color Space
-
dl
Download
-
dpi
Dots Per Inch
-
fm
Output Format
-
iptc
Iptc Passthrough
-
lossless
Lossless Compression
-
q
Output Quality
Mask Image
Noise Reduction
Pixel Density
Rotation
Size
-
ar
Aspect Ratio
-
crop
Crop Mode
-
fit
Resize Fit Mode
-
h
Image Height
-
max-h
Maximum Height
-
max-w
Maximum Width
-
min-h
Minimum Height
-
min-w
Minimum Width
-
rect
Source Rectangle Region
-
w
Image Width
Stylize
-
blur
Gaussian Blur
-
duotone-alpha
Duotone Alpha
-
duotone
Duotone
-
htn
Halftone
-
monochrome
Monochrome
-
px
Pixellate
-
sepia
Sepia Tone
Super Resolution
Text
-
txt-align
Text Align
-
txt-clip
Text Clipping Mode
-
txt-color
Text Color
-
txt-fit
Text Fit Mode
-
txt-font
Text Font
-
txt-lig
Text Ligatures
-
txt-line-color
Text Outline Color
-
txt-line
Text Outline
-
txt-pad
Text Padding
-
txt-shad
Text Shadow
-
txt-size
Text Font Size
-
txt-width
Text Width
-
txt-x
Text X Position
-
txt-y
Text Y Position
-
txt
Text String
Trim
-
trim-color
Trim Color
-
trim-md
Trim Mean Difference
-
trim-pad
Trim Padding
-
trim-sd
Trim Standard Deviation
-
trim-tol
Trim Tolerance
-
trim
Trim Image
Typesetting Endpoint
Watermark
-
mark-align
Watermark Alignment Mode
-
mark-alpha
Watermark Alpha
-
mark-base
Watermark Base URL
-
mark-fit
Watermark Fit Mode
-
mark-h
Watermark Height
-
mark-pad
Watermark Padding
-
mark-rot
Watermark Rotation
-
mark-scale
Watermark Scale
-
mark-tile
Watermark Tile
-
mark-w
Watermark Width
-
mark-x
Watermark X Position
-
mark-y
Watermark Y Position
-
mark
Watermark Image URL