Practice and practice and then there's also practice.
Then when you are done with it then you should practice more.
And then comes the stage of the practice in which you stop for a few minutes every time you practice.
After that you look at the sky and practice some more; then you think about your life and practice again.
Once you are done with a few months of that (possibly like half a year if you were as bad as me) start pedal-kicking, just drop your front wheel a little bit and kick. You DON'T need flawless perfect balance to do pedal-kicks, and as a matter of fact pedal-kicks was what helped me stay on the rear comfortably until I get tired.
YES you will fall on your ass.
YES you will hurt yourself.
YES people will think you are a dumbass.
YES it's frustrating when everyone else is sidehoping buildings next to you and you can barely hop on the rear wheel.
YES there will be blood.
YES you will consider quitting.
If you go through ALL that, then congratulations, that's the easiest technique in trials, have fun and enjoy your bike.