# How to do shaders compilation on game launch

**URL:** <https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine, Blueprint, CPP, question\
**Created:** [April 22, 2025, 11:47am UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634 "2025-04-22T11:47:42Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![Prabhdeep132](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Prabhdeep132](https://forums.unrealengine.com/u/Prabhdeep132)\
**Post date:** [April 22, 2025, 11:47am UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/1 "2025-04-22T11:47:42Z")

</div>

There many AAA games when launching for first time have loading phase to load/compile shaders which make sure your game runs smoothly.

In unreal engine, I am not able to find such features, system or way of implementing although many AAA games developed in unreal engine like days gone have it. Does someone know how can I do the same for my game so players don’t get any shuttering or lags?

---

<div class="post-metadata">

**Author:** ![ClockworkOcean](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/clockworkocean/32/1169999_2.png) [@ClockworkOcean](https://forums.unrealengine.com/u/ClockworkOcean)\
**Post date:** [April 22, 2025, 11:53am UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/2 "2025-04-22T11:53:22Z")

</div>

Have you seen this?

> **[Game Engines & Shader Stuttering: UE's Solution | Tutorial](https://dev.epicgames.com/community/learning/tutorials/xjzE/unreal-engine-epic-for-indies-game-engines-shader-stuttering-ue-s-solution)**
>
> Recently, there have been a number of conversations taking place in the Epic community around shader stuttering and its impact on game developer project...

---

<div class="post-metadata">

**Author:** ![DavidTveraas](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/davidtveraas/32/1058281_2.png) [@DavidTveraas](https://forums.unrealengine.com/u/DavidTveraas)\
**Post date:** [April 22, 2025, 6:59pm UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/3 "2025-04-22T18:59:00Z")

</div>

I was wondering the same thing. I recently played Avowed and Oblivion Remastered, and they both used Shader Compilation precompute tools upon launch. Are they using PSO caches?

 ![image_720](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/3/6/236715ef2e80f26b82704946ac2f6cd73defe8df.png)  
 ![image_720](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/7/e/37e8022f2980b7c0f11cb861d9187539ffaec6c9.png)

---

<div class="post-metadata">

**Author:** ![Prabhdeep132](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Prabhdeep132](https://forums.unrealengine.com/u/Prabhdeep132)\
**Post date:** [April 23, 2025, 5:08pm UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/4 "2025-04-23T17:08:02Z")

</div>

I’ve seen this and looking for the same solution “compiling PSOs or Shaders on start of game”

---

<div class="post-metadata">

**Author:** ![Prabhdeep132](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Prabhdeep132](https://forums.unrealengine.com/u/Prabhdeep132)\
**Post date:** [April 23, 2025, 5:08pm UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/5 "2025-04-23T17:08:42Z")

</div>

Yes, they are using PSO but there is no tutorial how to compile those shaders in that such a similar way

---

<div class="post-metadata">

**Author:** ![DavidTveraas](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/davidtveraas/32/1058281_2.png) [@DavidTveraas](https://forums.unrealengine.com/u/DavidTveraas)\
**Post date:** [April 23, 2025, 5:19pm UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/6 "2025-04-23T17:19:46Z")

</div>

I believe you are correct that there may not be a tutorial on the topic.

I would love to make a tutorial, as soon as I figure out the process.

I’ve reached out to some of the companies currently implementing these features.

Hopefully, they can give me some pointers.

---

<div class="post-metadata">

**Author:** ![ClockworkOcean](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/clockworkocean/32/1169999_2.png) [@ClockworkOcean](https://forums.unrealengine.com/u/ClockworkOcean)\
**Post date:** [April 23, 2025, 5:28pm UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/7 "2025-04-23T17:28:57Z")

</div>

I’d be interested in that. All I have at the moment is ‘show the camera all possible materials’… 🤣

---

<div class="post-metadata">

**Author:** ![Prabhdeep132](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Prabhdeep132](https://forums.unrealengine.com/u/Prabhdeep132)\
**Post date:** [April 23, 2025, 5:31pm UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/8 "2025-04-23T17:31:34Z")

</div>

That’s the hardest thing but I wanna know how AAA games implement Shaders compiling in UE

---

<div class="post-metadata">

**Author:** ![ClockworkOcean](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/clockworkocean/32/1169999_2.png) [@ClockworkOcean](https://forums.unrealengine.com/u/ClockworkOcean)\
**Post date:** [April 23, 2025, 5:34pm UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/9 "2025-04-23T17:34:51Z")

</div>

I’d really like to know if there’s a magic console command, but I really wonder if they’re just doing this behind a widget 🤔

---

<div class="post-metadata">

**Author:** ![Prabhdeep132](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Prabhdeep132](https://forums.unrealengine.com/u/Prabhdeep132)\
**Post date:** [April 23, 2025, 5:50pm UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/10 "2025-04-23T17:50:29Z")

</div>

Then what do you think they are doing behind? Ig they do record mostly all of the area in one set and precache them and compiles those again according to hardware. They do this while testing, QA and debugging ig the big studios.

---

<div class="post-metadata">

**Author:** ![ClockworkOcean](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/clockworkocean/32/1169999_2.png) [@ClockworkOcean](https://forums.unrealengine.com/u/ClockworkOcean)\
**Post date:** [April 23, 2025, 6:35pm UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/11 "2025-04-23T18:35:46Z")

</div>

Basically doing a quick game run-though.

---

<div class="post-metadata">

**Author:** ![Prabhdeep132](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Prabhdeep132](https://forums.unrealengine.com/u/Prabhdeep132)\
**Post date:** [April 24, 2025, 11:10am UTC](https://forums.unrealengine.com/t/how-to-do-shaders-compilation-on-game-launch/2469634/12 "2025-04-24T11:10:56Z")

</div>

> **[PSO Precaching for Unreal Engine | Unreal Engine 5.5 Documentation | Epic...](https://dev.epicgames.com/documentation/en-us/unreal-engine/pso-precaching-for-unreal-engine)**
>
> Use PSO precaching to automatically collect and compile PSOs.

They say setup a loading screen to compile PSOs but don’t have any tutorial to setup for “game startup” because we cannot show any ui before the game is started?
