# Phaser cannot find my images

**URL:** <https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191>\
**Category:** Phaser 3\
**Created:** [March 5, 2025, 3:15pm UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191 "2025-03-05T15:15:48Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![GrimmFurret](https://avatars.discourse-cdn.com/v4/letter/g/9fc348/32.png) [@GrimmFurret](https://phaser.discourse.group/u/GrimmFurret)\
**Post date:** [March 5, 2025, 3:15pm UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191/1 "2025-03-05T15:15:48Z")

</div>

I’ve been following this tutorial on making a multiplayer card game for Phaser 3  
Link Here: [https://youtube.com/playlist?list=PLCbP9KGntfcEDAiseVwYVbrmJdoYajNtw&si=2GXSV1LalQ7x7KKM](https://youtube.com/playlist?list=PLCbP9KGntfcEDAiseVwYVbrmJdoYajNtw&si=2GXSV1LalQ7x7KKM)

But upon attempting to preload my images (shown at the ~6:30 mark on the “Building UI” Video), the console informs me that none of the assets can be found (404 Error).

 ![image](https://global.discourse-cdn.com/free1/uploads/phaser1/original/2X/6/60cef0bf358314f70e57c5bd76326c94aaeb5b92.png)

 ![image](https://global.discourse-cdn.com/free1/uploads/phaser1/original/2X/0/077aed9695c29952dfb8dc3c7be71b33d949be1a.png)

Are there any ideas on potential fixes for this issue?

---

<div class="post-metadata">

**Author:** ![samme](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/samme/32/5275_2.png) [@samme](https://phaser.discourse.group/u/samme)\
**Post date:** [March 5, 2025, 3:25pm UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191/2 "2025-03-05T15:25:32Z")

</div>

Try importing image URLs: [https://v4.webpack.js.org/loaders/file-loader/](https://v4.webpack.js.org/loaders/file-loader/).

---

<div class="post-metadata">

**Author:** ![GrimmFurret](https://avatars.discourse-cdn.com/v4/letter/g/9fc348/32.png) [@GrimmFurret](https://phaser.discourse.group/u/GrimmFurret)\
**Post date:** [March 5, 2025, 3:58pm UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191/3 "2025-03-05T15:58:39Z")

</div>

Hi there,

I’m not quite sure how to use the “file loader”?  
I’m very new to using this software, and don’t quite understand all it’s telling me to do

---

<div class="post-metadata">

**Author:** ![GrimmFurret](https://avatars.discourse-cdn.com/v4/letter/g/9fc348/32.png) [@GrimmFurret](https://phaser.discourse.group/u/GrimmFurret)\
**Post date:** [March 5, 2025, 4:24pm UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191/4 "2025-03-05T16:24:15Z")

</div>

Additionally, looking at the “sources” tab in “Inspect Element” shows that “assets” folder is completely absent from the “src” folder, with all the other folders showing up completely fine

---

<div class="post-metadata">

**Author:** ![samme](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/samme/32/5275_2.png) [@samme](https://phaser.discourse.group/u/samme)\
**Post date:** [March 5, 2025, 4:26pm UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191/5 "2025-03-05T16:26:09Z")

</div>

Are the `pokeback1.png` etc. images inside the `src/assets` folder in your project? Are you working from [phaser-2d-multiplayer-2021-update](https://github.com/sominator/phaser-2d-multiplayer-2021-update)?

---

<div class="post-metadata">

**Author:** ![GrimmFurret](https://avatars.discourse-cdn.com/v4/letter/g/9fc348/32.png) [@GrimmFurret](https://phaser.discourse.group/u/GrimmFurret)\
**Post date:** [March 5, 2025, 4:30pm UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191/6 "2025-03-05T16:30:06Z")

</div>

Yes, I’m working from the linked project.

Yes, they are in `client\src\assets`

---

<div class="post-metadata">

**Author:** ![samme](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/samme/32/5275_2.png) [@samme](https://phaser.discourse.group/u/samme)\
**Post date:** [March 5, 2025, 4:39pm UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191/7 "2025-03-05T16:39:52Z")

</div>

Try

```js
import pokeback1Url from 'assets/pokeback1.png';

// etc.

this.load.image('playerCardBack', pokeback1Url);

```

---

<div class="post-metadata">

**Author:** ![GrimmFurret](https://avatars.discourse-cdn.com/v4/letter/g/9fc348/32.png) [@GrimmFurret](https://phaser.discourse.group/u/GrimmFurret)\
**Post date:** [March 5, 2025, 4:47pm UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191/8 "2025-03-05T16:47:15Z")

</div>

![Screenshot 2025-03-05 164433](https://global.discourse-cdn.com/free1/uploads/phaser1/original/2X/0/0291205e5eb9594cd935049af1a056709abebf0d.png)  
I now get this when starting reloading the page?

---

<div class="post-metadata">

**Author:** ![samme](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/samme/32/5275_2.png) [@samme](https://phaser.discourse.group/u/samme)\
**Post date:** [March 5, 2025, 4:49pm UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191/9 "2025-03-05T16:49:03Z")

</div>

From `scenes/game.js` change the path to `'../assets/pokeback1.png'`.

---

<div class="post-metadata">

**Author:** ![GrimmFurret](https://avatars.discourse-cdn.com/v4/letter/g/9fc348/32.png) [@GrimmFurret](https://phaser.discourse.group/u/GrimmFurret)\
**Post date:** [March 5, 2025, 4:52pm UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191/10 "2025-03-05T16:52:48Z")

</div>

looks like that works now, many thanks!

just got to repeat this whenever I need to add any cards, correct?

---

<div class="post-metadata">

**Author:** ![adover134](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/adover134/32/8791_2.png) [@adover134](https://phaser.discourse.group/u/adover134)\
**Post date:** [March 12, 2025, 3:05am UTC](https://phaser.discourse.group/t/phaser-cannot-find-my-images/15191/11 "2025-03-12T03:05:19Z")

</div>

What you needed to do was only add a slash in front of src url as this;

```javascript
// from this
'src/assets/~.png'
// to this
'/src/assets/~.png'

```

If not resolved, then try to use vite instead of snowpack.  
Snowpack was not working with me, but vite was.
