---
title: "Set your profile photo"
description: "Uploads the profile photo of the person, replacing any there was. The body is the image itself, not JSON, with its type in `Content-Type`: `image/png`, `image/jpeg`, `image/webp` or `image/gif`, up to 5 MB."
url: "https://openemail.uk/docs/api/account/photo-set"
area: "API"
category: "Your account"
---

# Set your profile photo

Uploads the profile photo of the person, replacing any there was. The body is the image itself, not JSON, with its type in `Content-Type`: `image/png`, `image/jpeg`, `image/webp` or `image/gif`, up to 5 MB.

`PUT /account/photo`

## PUT /account/photo

Uploads the profile photo of the person, replacing any there was. The body is the image itself, not JSON, with its type in `Content-Type`: `image/png`, `image/jpeg`, `image/webp` or `image/gif`, up to 5 MB.

## Example

Needs `account:write`. The image is fitted into a 512 pixel square and stored as WebP, and an animated image keeps its first frame. Answers with its new `url`.

**curl**

```
curl -X PUT "$OE/account/photo" -H "$AUTH" -H "Content-Type: image/jpeg" --data-binary @me.jpg
```

**Response**

```
{
  "object": "account_photo",
  "url": "https://cdn-prod.openemail.uk/users/avatars/8c1d4e7a-2f90-4b3c-a6d5-1e7f0b9c2d48.webp"
}
```

> A body that is not an image of an accepted type, is too large or cannot be read is a 422 `invalid_image`. A busy image service is a 503 `image_busy`, so try again.

> Every upload gets a new URL, so a cached old photo never shows under the new one.

## Reference

- [`PUT /account/photo`](https://openemail.uk/docs/api/reference/your-account#put-account-photo): full reference
