<p>According to the <a href="https://github.com/craftcms/cms/blob/cf85fae8b84c7329e70ea96753ebb53d897f26fc/src/elements/User.php#L951-L970" rel="nofollow noreferrer">Craft 3 source code</a>, <code>User::getPhotoUrl() has been deprecated. Use getPhoto() to access the photo asset (if there is one), and call its getUrl() method to access the photo URL.</code> <em>(Also mentioned in the <a href="https://github.com/craftcms/cms/blob/2e05ca4fa899e4e922562286767061b4ec9fe12b/CHANGELOG-v3.md#deprecated-12" rel="nofollow noreferrer">changelog</a>.)</em></p>

<p>So assuming you've set <code>user</code> to something already in your template, the correct way to get the photo in Craft 3 is:</p>

<pre><code>{{ user.photo.url() }}
</code></pre>

CC BY-SA 3.0
2018-03-08T19:49:45.637Z
To be absolutely clear about the no transformation (not even a default one): `{{ user.photo.url(null) }}` or `{{ user.photo.url(false) }}`
Marion Newlevant
CC BY-SA 3.0
2018-03-08T14:41:54.777Z
2018-03-08T14:41:54.777Z
Jalen Davenport
<p><strong>Craft 3</strong>: I'm trying to get User Photo URL WITHOUT any transforms, but none of those options seems to work:
(some of it prints the url with some transform)</p>

<pre><code>user.photo
user.getPhoto()
user.getPhoto('original')
user.getPhotoUrl()
user.getPhotoUrl('original')
user.photoUrl()
user.photoUrl('original')
</code></pre>

<p>There is no DOCs for this yet on the craft 3 site.
Anyone know?
Thanks</p>

<users><craft3><image-transforms>
How to get user's photo url without transform?
# How to get user's photo url without transform?

(Asked by: username_0 on 2018-03-08)

Craft 3: I'm trying to get User Photo URL WITHOUT any transforms, but none of those options seems to work:
(some of it prints the url with some transform)
user.photo
user.getPhoto()
user.getPhoto('original')
user.getPhotoUrl()
user.getPhotoUrl('original')
user.photoUrl()
user.photoUrl('original')

There is no DOCs for this yet on the craft 3 site.
Anyone know?
Thanks

**Tags:** users, craft3, image-transforms

---

## 1 answers

### Answer by username_1 on 2018-03-08. Score: 3

According to the Craft 3 source code, User::getPhotoUrl() has been deprecated. Use getPhoto() to access the photo asset (if there is one), and call its getUrl() method to access the photo URL. (Also mentioned in the changelog.)
So assuming you've set user to something already in your template, the correct way to get the photo in Craft 3 is:
{{ user.photo.url() }}

> **Comments:**
> **username_2**: To be absolutely clear about the no transformation (not even a default one): `{{ user.photo.url(null) }}` or `{{ user.photo.url(false) }}`  

---

