3x increase in endurance in 3 months? I am currently using a hybrid bike, which weighs about 10kg (quite light for the category I've heard), and my longest ride has been 65km at an average of 18km/h in a mostly flat terrain. 
In this ride for many kms I had a big muscle pain in my legs; by the end of the ride, stopping at traffic lights was extremely painful. Also, it took hours at home to go from huge pain to just normal muscle pain. I do not think I could have gone even one kilometer further.

I was pedaling at a good cadence, aiming for 90rpm. At no moment I felt like instant burning in my muscles; I would choose easy gears to keep me in high cadence and light strokes; it felt relaxed. But still, after 35km I felt 'loaded'; after that the pain started to increase more and more.

I will participate in a race of 180km with a time limit of 9 hours (so I need 20km/h and I am fine with finishing in 8h59m, I just want to finish), 3 months from now.

So I roughly need to go a little bit faster and improve my endurance 3-fold in 3 months.

My current plans for improvement are (my bike is 500$ Giant Escape; nothing fancy):


Buy clip-on aerobars. This should make me reach the speed I need, the terrain in mostly flat.
Buy clipless pedals. To help me use different muscles. I do not know how much would this help with endurance. I hope 10% or so.
Buy energy gels, I did not feel like I was lacking energy but I guess they will help. And on the race day I'll need them for sure.


What other gear, training techniques, and race day tactics can be used to improve endurance quickly?
If you did 65km (40 miles), then after recovery (maybe 1 week) you can probably do that distance again with much less discomfort.  You should then be able to increase your mileage about 10-20% a week, if you get in one max-length ride and one about 1/3rd shorter each week.
Conveniently, I've found that you can usually, if you push yourself, ride about 50% farther than your "accustomed" ride (though you will be dragging at the end).
You do need to eat and drink on a long ride.  I'm a big advocate of this stuff called "food" for that (hopefully provided for you on your ride), though it doesn't hurt to have some sugary snacks.  And did I say DRINK?
90 RPM is probably a hair too fast.  But you do need to keep your cadence up, especially as you begin to tire.  20k/h (12.5mph) is not a terribly fast pace (even allowing for rest stops), so it's important to not burn yourself out trying to maintain a fast pace.


Ultimately, for 180km (112 miles) you will be running on empty near the end -- that distance is challenging.  But by slowly working your endurance up you can probably make it.  DON'T expect to do it with "tricks", though -- the most important thing to do is to just steadily increase your distances.