Boost off of the edge to get height, and get into the dash ring.
On the rail with the first red ring, hold neutral and double jump after collecting the red ring to magdash straight through without having to go on the bar.
Make sure to keep the magdash going until you hit the box and the spring inside.
Spam jump to land on the rail without accidentally going into the dash ring that makes you go uppies.
You wanna jump right at the end of the rail that kinda curves up a bit to get the magdash off the bar.
Hold the jump off the rail for a little while so you don't get flung into the cannon thingy or the dash ring, but it's fine if you do get into the dash ring specifically.
Jump after you've grabbed the red ring to land on the rail.
You can just boost until the rail with the red ring ends and then boost left to land back on the rail faster.
Jump off of the rail, stomp down and homing attack the spring.
Then stomp off of the spring to go from 2D to 3D, and let Sonic dip down for a little while before magdashing to the end.
Then you wanna homing attack the last bar for safety, because trying to get to the last dash ring sucks and it's better to be safe than sorry.
Explanations and video in this page by RayNheartZ.