Is there a way to get the current number of concurrent users (or, alternative, average monthly users) IN-GAME? I want to limit the ability to connect when I am close to exceeding the free tier.
I looked through the RelayService documentation and did not find anything like that. I can view this in Unity Cloud but this is not available directly through Relay API?
Are there any alternative solutions?
No.
You, and only you. Your players will think of this differently. If you were to block them, you’ll get spammed with negative reviews for sure.
Be GLAD if this happens! It’ll be highly unlikely to ever occur for 99% of all published games by any solo dev.
Instead, focus on monetizing the game to be sure that you’re not spending more than you earn if this were to ever occur to you.
Also, you can check daily in the dashboard and you can also set usage notifications across three configurable usage tiers so that this won’t hit you by surprise but rather in the middle of the month you’ll get an email like “exceeded 75% of the quota” and then it’s up to you what actions to take.
It is a shame Relay does not have that basic piece of functionality. Knowing how many people are in your game currently is useful no matter what your goals are. Lots of games just display number of currently playing players in the menu. I’ll see if I can somehow get current CCU by parsing unity.cloud in real time in this case.
I did not ask for any advice about how this is actually good that I can get overpriced. I do not want to think about any monetization tactics - some games are meant to be free to develop and free to play, with zero income and zero revenue. If people are spamming negative reviews on a free product, well, it’s on them.
In that regard, I am happy with the restrictions UGS provides on a free tier. I just want those restrictions to be enforced instead of it relying on me checking the quota and disabling the services altogether when I am close to the limit.
Hmmm I think we’ve been discussing this not too long ago. 
No need.
All you need is every host sending you a +1 on ever client connection (including the host) and a -1 for every client disconnect. You could send this to Cloud Code, Cloud Save, or since you want to go all free, perhaps just a tiny PHP script on your webserver that updates the counter and writes it to disk periodically.
Another webrequest is to get the current counter.
And then reset that counter every day or so to get rid of any deviations caused by hosts crashing. Or better: record the daily CCU for each hour and then take the average of the last 3 hours or so. Any number will do. Nobody expects “currently playing …” stats to be realtime or to be precisely accurate (and nobody can prove that it’s neither).
Question is: it may be discouraging for players to see “curently playing: 13 players” or similarly low numbers every day. Players may not even bother starting a session seeing that almost literally nobody is playing. Could cause a vicious cycle.