If you have a wobbly toilet because there is something uneven on the floor the ideal solution is to find a way to level the floor. If it is wood, you could shave it down to flat. If the problem is tiles, you could remove the tiles under the toilet. But often in real life, we don't want to do either of those. As long as the floor is not rotten, you can use this technique.
Start by marking the outline of the toilet flange on the floor with a pencil, then remove the toilet. Clean the floor surface thoroughly so that glue will stick.
Now wax the bottom of the toilet, even a bit up the inside and outside of the part that will be in contact with the floor. I use paraffin wax but any heavy wax will work. The objective is to be sure that glue will NOT stick to the toilet. You may want to wax the floor outside the pencil line so that excess adhesive will not stick there either. In the photo above I am working with half a toilet -- not a very good idea in a real home -- half toilets don't flush too well and they are hard to sit on.
Then apply a thick bead of Polyurethane construction adhesive to the place on the floor where the toilet will make contact. Basically you will work just inside the outline pencil line. Why Polyurethane construction adhesive? We need an adhesive that will not shrink, that will set rock hard and provide a solid foundation to the toilet. Any softer adhesive or caulking would eventually begin to wobble again.
Now set the toilet into the bead of adhesive -- gently. You need to come down in the right position because if you move too much back and fourth, you will scrape away the adhesive from where you need it. You may want to work with someone who can watch the floor and guide you. Just set it in. It will settle down a bit more by its own weight. Leave it be for 48 hours -- I want the adhesive completely set through and through. If you are in an extremely dry home or dry climate, spray a bit of water over the adhesive just before placing the toilet. Polyurethane adhesive is activated by moisture and this will help it to start curing.
When the adhesive is hard you can trim off the excess around the toilet, or even lift off the toilet to clean off what has flowed outward. The wax prevents the toilet from being stuck, and if you had waxed the overflow area, you can cut the adhesive just inside the pencil line and the excess will pop off.
This will give you a permanent levelling without making any changes to the toilet, so the toilet will still work if you decide to renovate and change the floor.
Reverse procedure works too
If you don't want the adhesive on the tiles, maybe because you may change the toilet and the new one might not have the same foot print, then you can simply reverse this procedure. Wax the floor and apply the adhesive to the bottom of the toilet. Some prefer this sequence because the adhesive tends to stick better to the rough bottom of the toilet than the glossy surface of the tiles. The only drawback is that the indentitions for the grout lines will force you to put the toilet back in the exact same position if you ever lift it for a repair.
Follow this link for details on a basic toilet install.