# Steam Leaderboard Not Working

**URL:** <https://forums.unrealengine.com/t/steam-leaderboard-not-working/481410>\
**Category:** Platform & Builds\
**Tags:** Steam, leaderboard, unreal-engine, question\
**Created:** [April 5, 2021, 12:02pm UTC](https://forums.unrealengine.com/t/steam-leaderboard-not-working/481410 "2021-04-05T12:02:36Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Anoberia](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/anoberia/32/590142_2.png) [@Anoberia](https://forums.unrealengine.com/u/Anoberia)\
**Post date:** [April 5, 2021, 12:02pm UTC](https://forums.unrealengine.com/t/steam-leaderboard-not-working/481410/1 "2021-04-05T12:02:36Z")

</div>

Hello, I have an issue for Steam Leaderboard system. I can’t write leaderboard integer neither with Blueprints nor with C++. I’m looking forums-answers for this issue and my mind will blow. Someone says “You need to put ‘\_’ between names” but it doesn’t work for me.  
Here’s my code for write integer value;

```
FOnlineLeaderboardWrite write;
write.DisplayFormat = ELeaderboardFormat::Number;
write.SortMethod = ELeaderboardSort::Descending;
write.UpdateMethod = ELeaderboardUpdateMethod::KeepBest;
TArray<FName> LeaderboardName;
LeaderboardName.Add(TEXT("PHScore"));
write.LeaderboardNames = LeaderboardName;
write.RatedStat = TEXT("PHBestScore");
write.SetIntStat(TEXT("PHBestScore"), 10);
iol->WriteLeaderboards("GameSession", *pid, write);

```

And I get this error message;

```
[2021.04.05-12.01.12:105][677]LogOnlineLeaderboard: Warning: STEAM: Failure to write key value pair when uploading to Steam PHScore_PHBestScore=10
[2021.04.05-12.01.12:106][677]LogOnline: Warning: OSS: Async task 'FOnlineAsyncTaskSteamUpdateStats bWasSuccessful: 0 User: Anoberia [0x21132F2FFD0]' failed in 0.756331 seconds
[2021.04.05-12.01.12:109][678]LogOnline: Warning: OSS: Async task 'FOnlineAsyncTaskSteamUpdateLeaderboard bWasSuccessful: 0 Leaderboard: PHScore Score: 0' failed in 0.758298 seconds

```

I run game via .bat. I can see Steam Overlay so it connected steam subsystem. But how can I write integer properly? There’s a reading part which I don’t want to think of. 🙂 Anyone help me?

Also, if I run this code, it creates a section named I mentioned in c++ but it doesn’t upload any entry.

---

<div class="post-metadata">

**Author:** ![Bojann](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bojann/32/906560_2.png) [@Bojann](https://forums.unrealengine.com/u/Bojann)\
**Post date:** [May 27, 2023, 2:01pm UTC](https://forums.unrealengine.com/t/steam-leaderboard-not-working/481410/2 "2023-05-27T14:01:43Z")

</div>

Did you manage to resolve this? I’m having the same issue.

---

<div class="post-metadata">

**Author:** ![D.Kermel](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@D.Kermel](https://forums.unrealengine.com/u/D.Kermel)\
**Post date:** [October 13, 2023, 3:29pm UTC](https://forums.unrealengine.com/t/steam-leaderboard-not-working/481410/3 "2023-10-13T15:29:37Z")

</div>

Same issue with a 5.1 project.  
The achievements are working but the leaderboards functions always return a failure

Failure to read key value pair during retrieval from Steam Score\_Score  
Failure to write key value pair when uploading to Steam Score\_Score=10

Any Idea why ?

---

<div class="post-metadata">

**Author:** ![Bojann](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bojann/32/906560_2.png) [@Bojann](https://forums.unrealengine.com/u/Bojann)\
**Post date:** [October 22, 2023, 2:42pm UTC](https://forums.unrealengine.com/t/steam-leaderboard-not-working/481410/4 "2023-10-22T14:42:32Z")

</div>

Hey D.Kermel, and in case anyone else needs help with this.

It’s not enough to just create Leaderboard in the Steam. You need to create stat.

So if you created Leaderboard names `Leaderboard1`, you need to go to stats, and create stat `Leaderboard1_Leaderboard1`. Set by is set to `Client`.

Then it started working for me.
