The most commonly recommended cleaner for coffee grinders (including burr grinders) is to run a batch of minute rice through the grinder. The rice will help to pull the leftover oils and other trash out of the system. I usually disassemble my coffee grinder and brush it out before the rice is used but if you clean with rice often enough that may not be necessary.
Minute rice is softer than regular rice so many people (myself included) feel that it is less likely to dull the burrs of a grinder. A small amount of residual rice dust in the grinder after cleaning should not add any noticeable flavor to the coffee.
Commercial Coffee Cleaners
One manufacturer of a commercial grinder cleaner claims that rice can cause issues in a grinder so another option is to use a product specifically designed for cleaning coffee grinders. These include products like Caffiza tabs and powders, which are designed to break down easily in blades and burr grinders so that no damage occurs.
If using a cleaning product and not something natural, you’ll want to run some coffee beans through the grinder to remove the cleaning product and toss the grounds to remove any residual cleaning product. This can seem wasteful, but can ensure longevity of your coffee grinder.