I must stress two things: First, the lure does not really matter. There are about a dozen things which are more important when it comes to successful raccoon trapping. Secondly, mere trapping and removal isn't usually a complete solution to whatever raccoon problem you're having. Please note your raccoon problem, particularly if the animal(s) are in the attic, will not probably be solved by mere removal and trapping. And unlicensed trapping is prohibited in most states.
So, what's the best lure to catch raccoons? They'll eat anything. . .pets. Or possibly a neighbor's pet . I suggest shying away from beef (which also lures in more possums) and sticking to candy. Sweet corn is great, and so is white bread. However, my favorite, and the best sort of lure to catch raccoons is marshmallows.
But please see one of the below posts when it comes to your particular raccoon issue, because as stated, there is more to solving a raccoon problem than merely plunking a trap on the floor and grabbing the animal.
What type of bait to use for raccoons - If your trap is set correctly, or at the very best manner, you may not even want bait. The best way to remove a raccoon in your attic is to attach a cage trap to the den with some wire mesh. When you then enter the attic from the interior of the house, the raccoon will panic and bolt out the opening, hitting on the pressure plate and shutting the trap. Any infants can then be discovered and eliminated. This is the same method used for trapping racoons from the chimney. If this sort of trapping is not possible, you can bolt the trap into the roof of your house alongside the opening or at the point where the raccoon makes her climb down the siding. In case you must set this up in the lawn, you can use bread or marshmallows for bait. This way you don't attract other meat-loving creatures such as cats and skunks.