Unless you're playing in an exceptionally small or dying gaming community, most video games and online board games have good matchmaking services, which provides a quick-and-easy matchup to people of similar skill levels as you.
A lot of the discussions in this thread are about Overwatch (one of the most popular video games right now), or Chess (one of the most popular board games). You should have no issues finding opponents close to your skill in either of these games.
If there's an ELO matchmaking system in place, then the whole discussion—"How to play with people who are better than you"—is moot. So, for the purposes of discussion here, you should probably assume that there isn't such a system in place for the game in question. (The people who are bringing up examples from games with ELO presumably haven't read the article.)
But when your level of skill gap with another player is too large, such that you won't learn anything by playing them and the entire match will be under their control 100% of the time, then there really isn't any point in playing them, and you'd be far better off—both for your enjoyment, and for your growth—to play against a weaker player.
It might be fun to have a sprinting match against your local state champion. It might even be fun to have a sprinting match against Usain Bolt. But there's no point to having a hypothetical sprinting match against The Flash. You wouldn't even leave the starting line before he crosses the finish line. There's no gradation of success available to you. You're simply crushed.
Likewise, there's no point, if you're a five-year-old, to trying to (seriously) arm-wrestle an adult. Your undeveloped strength will be overwhelmed without accomplishing the slightest movement of the opponent's arm, right at the beginning of the match, every time. You won't even get to practice the skill or build the muscles involved in arm-wrestling.