I started shooting .22 at 300-400 yards a few years back. Lessons learned:
You'll need at least a 30 MOA rail or else you'll run out of elevation adjustment in your scope. I run 40 MOA rails on a home built 10/22 and Savage MKII. These allow me to zero at 50 yards and dial elevation out to 300-500 depending on the scope installed.
This 10/22 started out with a 12x Athlon NEOS scope, but I've switched it over to a 16x ARKEN. Between the Arken and the 40MOA rail, I can actually dial this up to 500 yards with Minimags.
The MKII still has a NEOS installed. I shoot CCI SV out of this one, and the elevation maxes out just short of 400 even with the 40MOA rail.
I shoot at gongs for fun. At 300 yards the 6" and 8" are pretty easy on a non-windy day. On calm days, I stretch the 10/22 out to 400. (That's about a 22 foot drop.) On really calm days I'll try for that 8" square plate at 500. (There's an almost 40 foot drop at this range!)
I put 200+ rounds through the 10/22 every time I'm at the long range, so expensive Lapua or SK Long Range is out of the question. Minimags and SV get me through a day for less than $20, including a coffee! For accuracy at these distances I shoot centerfire with handloads, but I do have just as much fun with the .22s.
Wind is actually the biggest challenge when shooting .22 at distance. Even at 300, the wind drift is about 3.5 inches per mph. At 400 drift is about 6.5 inches per mph. Yes, a 5mph breeze can send that bullet almost a yard to the left or right! In order to shift aim accurately, you really need a scope with markings that allow you to make adjustments on the fly.
Rifle capable of ragged hole groups at 50yds. CZ 457, Bergara B14r, Tikka T1x, Vudoo, Zermatt RimX, take your pick.
consistent match grade ammo that your rifle likes. Lapua, SK, Eley, etc. Chrono it.
20-40moa scope base depending on scope selection. 300 yards you're looking at around 13mils you want to be able to dial on your elevation turret. 400yds is around 21mils.
Scope with uncapped turrets capable of holding zero. MRAD recommended but not absolutely necessary. Understand the basics of dialing elevation and highly recommend getting a scope with a zero stop.
There have been a few times I couldn't figure out why my rounds were impacting so erratically while shooting at plates close to the sides of the range. Then I realized I was hitting the branches of trees between me and the target!
Tikka T1X , MDT ORYX chassis, 30 MOA scope base , Athlon 4.5-30x56 MILLS . Have reached out to 300 yds so far, a REAL challenge for consistency as a crosswind REALLY throws rimfire bullets around. Listen carefully to MC56 as he offers expert advice.
At 200y and beyond it is ALL about knowing your elevation dope and reading the wind. 22RF at 200y has the same wind and elevation challenges as a .308 at 800+ yards. So, don't get too hung up on the gun. Your wind and elevation errors will be much greater than the 1.5MOA a decent. 22 can shoot. It's awesome, cheap fun and excellent long range training.
Make sure you get a scope mount with a 20 MOA cant.
And make sure the scope can adjust parallax down to 25 yards.
Test out various ammo brands/types/lot numbers to see what your rifle likes. Then buy a bunch of that lot number. Some websites that sell match 22lr will let you select the lot number on the order.