Hear from Slack, the ACLU, TED, & more at our customer summit in San Francisco Register
LOG IN SIGN UP
Documentation

Cropping images

  Last updated April 17, 2017

Region crop

Crop the image to 150px by 100px.

http://www.fastly.io/image.jpg?crop=150,100

alt text

Aspect ratio crop

Crop the image to an aspect ratio of 16:9.

http://www.fastly.io/image.jpg?crop=16:9

alt text

Region crop and sub region

Crop the image to 150px by 100px and also select 50px as the starting sub region x coordinate and 50px as the sub region y coordinate.

http://www.fastly.io/image.jpg?crop=150,100,x50,y50

alt text

Aspect ratio crop and offset

Crop the image square and offset the x-axis 25% and the y-axis 50%.

http://www.fastly.io/image.jpg?crop=1:1,offset-x0.25,offset-y0.50

alt text

Aspect ratio crop (with width)

Crop the image square and resize the width to 200px.

http://www.fastly.io/image.jpg?crop=1:1&width=200

alt text

This article describes a product that may use third-party cloud infrastructure to process or store content or requests for content. For more information, see our cloud infrastructure security and compliance program.

Back to Top