# Are static variables automatically replicated?

**URL:** <https://forums.unrealengine.com/t/are-static-variables-automatically-replicated/357892>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine\
**Created:** [May 19, 2016, 6:23am UTC](https://forums.unrealengine.com/t/are-static-variables-automatically-replicated/357892 "2016-05-19T06:23:46Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ryan\_Darcey](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Ryan\_Darcey](https://forums.unrealengine.com/u/Ryan_Darcey)\
**Post date:** [May 19, 2016, 6:23am UTC](https://forums.unrealengine.com/t/are-static-variables-automatically-replicated/357892/1 "2016-05-19T06:23:46Z")

</div>

This seems to be the behavior I’m seeing. Basically, I’m setting a static bool variable on a client, but then the server also updates the variable O\_o Not doing anything else besides setting value on the client.

---

<div class="post-metadata">

**Author:** ![Ryan\_Darcey](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Ryan\_Darcey](https://forums.unrealengine.com/u/Ryan_Darcey)\
**Post date:** [May 19, 2016, 6:36am UTC](https://forums.unrealengine.com/t/are-static-variables-automatically-replicated/357892/2 "2016-05-19T06:36:15Z")

</div>

Random thought…could it be that I’m launching 2 clients (one is the server) from the editor? Could they share static variable settings on the same machine like this?

---

<div class="post-metadata">

**Author:** ![Filtiarn00](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Filtiarn00](https://forums.unrealengine.com/u/Filtiarn00)\
**Post date:** [December 13, 2020, 6:32am UTC](https://forums.unrealengine.com/t/are-static-variables-automatically-replicated/357892/3 "2020-12-13T06:32:16Z")

</div>

This is happening to me. Any update?

---

<div class="post-metadata">

**Author:** ![Zssork](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/zssork/32/629783_2.png) [@Zssork](https://forums.unrealengine.com/u/Zssork)\
**Post date:** [December 13, 2020, 12:53pm UTC](https://forums.unrealengine.com/t/are-static-variables-automatically-replicated/357892/4 "2020-12-13T12:53:12Z")

</div>

im just guessing but maybe its because you have “Run Under One Process” enabled in the multiplayer options. So you have the same UE4 instance and therefore the same static.

Play \> Advanced Settings \> Multiplayer Options \> Run Under One Process

But do you really need a static? Maybe you can use PlayerState or something like that instead
