I have seem three types of bases for this - one pokes down from the top and has a nut on the bottom - this is the type the other comment referred to. BTW - if the threads are stripped, pull it up out of the hole, put a wrap of electrical or duct tape on it, then push back down in and then the nut should hold it tightly enough. Usually a two-person job to tighten the nut on it you have not done it before - on underneath to tighten, one holding the ring at the top.
Second type of base is a pop-in, with "fingers" or tabs that lock under the rim of the hole through the sink - mush like the push tabs that many small battery access covers on small devices use. if the tabs break off, you might or might not be able to get a new base at your local plumbing shop or Home Depot/Lowes. Obviously helps if you know the brand of your nozzle, if it is labelled. If you turn off the shutoff valve for the sprayer (so the hose does not spray all over the next time you turn on the faucet), you can then unscrew the threaded fitting on the bottom of the spray nozzle, and remove the nozzle from the hose. This will let you pull the base fitting up over the hose. Do NOT forget that the hose is pressurized whenever the faucet is on, so you have to either shut off the shutoff valve on the spray nozzle (if it has one) or make sure the hose is held firmly down into the sink or you will have water all over the place then next time the faucet is turned on. A temporary fix that might or might not work for you is to wrap the base with electrical or duct tape so it is a bit of a tight fit, then shove it down into the hole - sometimes will work, sometimes not so well, depending on design of the base and how many spring tabs are broken off.
Third type - is purely a press fit, designed to go into holes cut in countertops rather than sinks - usually has a rubber bushing all around the hose. If that cracks or gets old, gets loose - duct tape will usually work well on this - just one to three wraps as needed to get a good tight compression fit in the hole.
If all that fails, pretty easy to replace the hose and nozzle and ring usually with a totally new spray nozzle kit - but you have to be sure to get the right type of base for your situation.
If you don't want to attack this yourself, then Search the List for a plumber, who will almost certainly replace the whole unit as it is too expensive to search around for a new base to fit - so about $25 give or take for the spray nozzle and hose kit, and $75-175 minimum labor charge (up to $300 in very high priced large cities like Chicago, NYC, Boston) - generally around $100-150 in most areas.